LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

extracting data from for loops

Hi all
I am using a microscope stage to manipulate a sample which I collect data from.  I need to display this data as voltage intensity by the position.  Right now I am getting this but the vi is bulky and looks to be not as simple as it could.  As is stands I have labview acquire a position from the stage and then move on and I use the stage position to tell which space in the array to put the intensity data.  If any one could think of a easier or simplified way to do this other than what I have attach it would be appreciated as when I increase the window scanned there is a bunch of tedious work that I would like to avoid if possible. 
 
Also as it is put I cannot receive intensity data continuously throughout my scan.  In order to get any data I have to actually stop the loop that collects the voltage data and then I only get the one data point entered in every array slot. I want to take a intensity reading after each move I was thinking about puting a event structure around the voltage input but I still do not know if this will help. 
 
Thanks in advance.
0 Kudos
Message 1 of 4
(2,761 Views)
Think about defining a local variable that is an array that contains the image data. Then you can acquire in one loop and plot in another loop.

Adding more inputs to the "replace array subset" is definitely not pretty.
0 Kudos
Message 2 of 4
(2,750 Views)
You could try to put the DAQ Assistant in the same while loop as the replace array and intensity graph VIs.  If that slows things down too much then we may need to try using producer/consumer loops.  Also when you asked about the event structure, were you referring to an event structure around the DAQ assistant?  If so then what event would trigger the data acquisition? 
Message 3 of 4
(2,719 Views)
thanks Jeff that did the trick!
0 Kudos
Message 4 of 4
(2,714 Views)