LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

How to convert information from sensors to image

I have 16 * 16 sensors, I read the data into memory.
I save the data in memory row after row.
I wanted to know how I can display the data and create an image.

Thank you

0 Kudos
Message 1 of 9
(4,302 Views)

What kind of image?  What kind of data are coming from the sensors?  Are you doing this yourself, to learn how to use LabVIEW, or are you hoping to hire a LabVIEW expert?  [For the latter, see the Forum entry for LabVIEW Developers Seeking Employment].  If you are learning LabVIEW, show us the code you've already developed (by attaching the VI, not a picture of the VI).

 

Bob Schor

0 Kudos
Message 2 of 9
(4,289 Views)

The information is binary.
I keep the information in the aray i have 256 samples.
I need to display the data from the sensors .
I can not understand how I show a graph of X (Line) Y (column) the results of the sensors.
For example, the first call I received from the first sensor( i have 256 sensors, 16*16) of the XY graph 00010010, for example, if i read  0000000 then aray in the graph is will be  white and if 11111111 It is black.

My question is how I build this graph

0 Kudos
Message 3 of 9
(4,274 Views)

Hello Fnachum,

It sounds like you have a 16x16 array of binary data stored in a U8 format, correct? If you would like to convert this data to a 16x16 image, I would suggest looking at the functions available in the Programming->Graphics & Sound->Picture Functions Palette. Specifically,  "Draw Unflattened Pixmap" will take a 2D array of U8 and output a grayscale image. The image can then be displayed in a "2D Picture" Indicator. 

If you wish to save the image, you can just use the "Flatten Pixmap" to convert your image from the 2D array to image data, then the "Write JPEG File" to save the image as a JPEG. Both of these funcations can be found under the Programming->Graphics & Sound->Graphics Formats Palette. There are identical functions for BMP and PNG files here as well.

Charlie J.
National Instruments
0 Kudos
Message 4 of 9
(4,220 Views)

Another option is to plot an Intensity Graph (which you can find on the Front Panel Graph palette).  It works on U8 data, allowing you to choose a different (up to 256) color for each value.  There are both Help and Examples (see LabVIEW Help).

 

Bob Schor

0 Kudos
Message 5 of 9
(4,201 Views)

I made a 2D array of 16 to 16.
I try to present the results on a picture but the picture I get very little.
How do I increase the image  to size that I want?
I attach the file I made.

0 Kudos
Message 6 of 9
(4,157 Views)

Why do you have Waits in the inner For loops?  And why do the Wait times grow by factors of 10?

 

Of course you will get a tiny 16x16 pixel picture if you try to plot a 16x16 array as pixels.

 

Go to LabVIEW Help, get help on Graphs (all kinds), Pictures (all kinds), do some Web searching to learn how to use these functions.

 

Bob Schor

0 Kudos
Message 7 of 9
(4,143 Views)

Are you looking for something like this (a 16x16 plot of random numbers from 0 to 100)?

Intensity Graph.png

Bob Schor

0 Kudos
Message 8 of 9
(4,136 Views)

Yes, it looks ok.
Thanks for the help

0 Kudos
Message 9 of 9
(4,126 Views)