04-29-2013 03:03 PM
I've been trying to figure this out for quite some time and it si driving me crazy.
I have a camera that spits out a 1D array every second. I can plot this easily, and it changes every second as expected. I use an optical chopper to block the laser every other shot so that one shot has signal while the next is just background (and this repeats over and over again). Can I store two pictures at a time in a double array so I can subtract one from the other?
Currently the program bilds a very long 2D array where it stores all the spectra (limited to less than 10000 by labview memory) and then subsequently performs the subtraction.
Kogru
04-29-2013 03:36 PM
Change your loop so that it collects 2 images, subtracts them & stores the result in an array. This will let you store twice the useful images. Of course, whether this is feasible depends on the timing of the data collection.
04-29-2013 03:41 PM
Ultimately, the camera will run at 1 kHz, and I would like to acquire data for about 20 minutes or so. Currently I can only collect data for ten seconds at most.
04-29-2013 03:46 PM
It sounds like you want to record a video.
If you are hardset on recording individual images, you'll have to save them periodically to clear some memory.
04-29-2013 04:06 PM
These are the VIs that I am currently working on. In the Subsequent_Spectra_Subtraction I sort of duplicate the actions of the camera by generating waves. The DataGrabber is a sub VI that I am currently implementing. It runs a for loop for the total number of pictures that I want to take. There has to be a better way.
04-29-2013 05:27 PM - edited 04-29-2013 05:27 PM
About the spectra subtraction draft:
02-11-2014 05:19 AM
Hi all,
I have a similar problem. I would like to:
- collect a fixed reference spectrum (blank) with a spectrometer, and store it in memory
- acquire a new spectrum every second
- at each acquisition subtract the blank
- monitor in a graph the difference of the two spectra for each acquisition (once per second)
This part of the program should be added to this sub-vi for use it in a bigger project.
Can someone help me?
Thanks,
V.
02-11-2014 06:31 AM
All you have to do is check to see if it is the first acquisition. If it is, then you store the read spectrum in a shift register. If it is after the first acquisition, then you subtract your read spectrum from the spectrum stored in your shift register. The result goes to your waveform graph. Make sure you keep your "blank" spectrum in the shift register.