LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Would like to use Lock-in detection with a linear diode array detector

Solved!
Go to solution

Howdy folks,

 

I'm working with NI virtual lock-in amplifier to build a detection system that uses a linear diode array detector to measure the effect an electric field has on the absorption spectrum of a molecule. Traditionally, this technique was performed using a single photodiode detector connected to an external lockin amplifier, and the absorption spectrum was scanned using a spectrometer. The lockin would demodulate the signal of interest as a function of wavelength. In my configuration, I am acquiring the entire spectrum (all wavelengths) simultaneously to speed up the experiment and improve S:N. To do this, I am using an OOptics USB2000+ spectrometer and NI virtual LIA. Each element of the photodiode array then acts like a single photodector calibrated for a specific wavelength. I want to demodulate the signal of interest from each element of the photodiode array.

 

After reviewing many of the posts on this discussion board, I am starting to worry if my setup will actually work. So far, I have seen that everyone uses a single channel detector connected to a digitizer card of some sort, which also acquires a reference signal. Phase delays would come primarily from electronics and cable lengths. In my configuration, the detector is digitized by the 2MHz ADC in the OOptics spectrometer and my NI digitizer is only measuring the reference signal from the experiment. Because two ADC from separate instruments are being used, does this preclude the use of vLIA? My intuition tells me know, but I am relatively new to using photodiode array detectors for this purpose.

 

Any help would be greatly appreciated.

 

Timchem

0 Kudos
Message 1 of 13
(4,738 Views)

Timchem,

 

It probably will not be easy, but whether it can be done at all may depend on some things you did not mention.

 

What are the sampling rates for both devices?  What is the modulation (reference) frequency?  What is the expected signal to noise ratio, especially at wavelengths where meaningful signals are likely to be present?  How many samples are available at each read?  Is there any way to synchronize the sampling clocks of the two devices?

 

Now for the tougher questions: How much phase error can you tolerate?  How do you handle wavelength bins where there is no detectable signal?  How do you define "no detectable signal?"

 

Lynn 

0 Kudos
Message 2 of 13
(4,725 Views)

Lynn,

 

Thanks for responding. I will do my best to answer your questions but my background is in physical chemistry, so I might need some coaching along the way. Here goes...

  1. Sampling rates: (OOptics USB2000+) is
  2. Modulation frequency of high voltage power supply: 400 Hz
  3. S/N: 140 dB of input noise.
  4. Samples available at each read: 1D array of 2048 pixel intensities.
  5. I'm looking into how I can synchronize the two sample clocks right now.
  6. I'm not sure how phase error applies. If both the spectrometer and the digitizer are sync'd to the same time base, phase error should be minimized, right?
  7. Where this is no signal, the voltage amplitude from the photodiode will simply be the dark noise on the detector.

I've done my best to answer your questions, but like I said there is engineering parlance here that I am still learning, so please feel free to coach me along. I would appreciate the skill upgrade.

 

Best,

Tim

0 Kudos
Message 3 of 13
(4,716 Views)

Tim,

 

OK.  I work with chemists all the time, so I'll see what I can do to help.

 

Rule #1.  Keep chemicals away from your electronics.  The electronics last much longer that way.

 

Q1. You did not specify an sampling rate for the spectrometer.  Does this mean you do not know or just got distracted while typing?

Q2. Is the 400 Hz your reference frequency for the lock-in?

Q3.  Coaching time: Do you mean that the maximum signal from any pixel is 140 dB greater than the dark current? That means that if the dark current is 1 nA, then the maximum signal is 140 dB above 1 nA = 10 mA.  Your digitizers probably cannot handle a dynamic range that large without range switching, or they will be very slow.  If your signal to noise ratio is really 140 dB you do not need a lock-in amplifier.  Lock-ins are most useful when S/N < 0 dB. 

Q4.  How fast do you read?  Or how long between capturing one set of 2048 intensities and the next set?

 

Q6. If the sample clocks are synchronized and a the same frequency, then phase errors will likely be minimized.  Do you know it the 2048 pixel intensities are measured simultaneously or sequentially?  If sequentially, how long does it take the spectrometer to capture all 2048 measurements?

 

Lynn

0 Kudos
Message 4 of 13
(4,708 Views)

Hi Lynn,

 

I'm glad you work with chemists a lot. As a spectroscopist, I keep my instruments and optics well out of the way of any chemical I am using. Learned this lesson the hard way.Smiley Wink I had to look up the sampling rate for the spectrometer, which is why I didn't answer that question.

 

  • By sampling rate, I assume you mean how fast I can acquire spectra. According to the specs for the spectrometer, integration times can be as small as 1 ms but there is a 13 ms data transfer time between acquisitions. If I am interpreting this correctly, my sampling rate is then ~70 Hz.
  • 400 Hz is the ideal reference frequency for the lockin. It is only ideal because this is the frequency I used in grad. school, but really there is no other reason why I am using this frequency. Old habits die hard.
  • Understanding your lecture (I'm chuckling because I'm also a university professor), the electric field causes the amplitude of the absorption spectrum of the molecule to modulate at the frequency of the applied field (i.e., 400 Hz). This field effect results in a microvolt AC ripple in the DC amplitude of the absorption spectrum. The amplitude of the AC ripple is what I am after. When you asked about S/N, I was referring to the AC signal as "noise."
  • According to the literature I obtained directly from OOptics website, the data transfer rate for an entire spectra (2048 elements from the diode array) is 13 ms. Pretty slow if you ask me. Understanding the Nyquist theorem, this would mean the maximum frequency at which I can modulate the electric field in my experiment is ~40 Hz. Now, I am uncertain at this point if it is possible to address individual elements in the array and record the time trace of each individual element, which if possible, could speed up the transfer rate.
  • The pixel intensities are measured simultaneously. Further investigation confirmed the spectrometer is capable of external hardware synchronization. I use a function generator to drive a bipolar amplifier that is the source of the electric field for my experiment. Using the TTL output of the function generator, I can synchronize both the spectrometer operation and the reference waveform digitizer.
  • One further point about the digitizer: it is only digitizing the reference waveform from the function generator. This waveform is amplified by the bipolar amplifier and excites the experiment. I thought the virtual lockin amplifier needs this reference waveform, as it did in grad school when I used the SR850. Hence the reason for acquiring it in conjunction with the spectra from the spectrometer.

OK. I think I responded to everything. Does this seem like a hopeless cause? If so, I need to write a grant to buy a new optical setup....yuck....
0 Kudos
Message 5 of 13
(4,702 Views)
Solution
Accepted by topic author TimChem

Tim,

 

Now we are getting somewhere.

 

Your effective sampling rate is about 70 Hz.  Unfortunately, the timing is probably software controlled, which introduces additional jitter in the times of each data set.  Sampling a signal at the Nyquist rate only gets you minimal information about that signal, and certainly produces very little meaningful phase information.

 

Since the pixel intensities are measured simultaneously, you have no worries about phase shifts between pixels.

 

Question on the synchronization: Does the spectrometer initiate a measurement each time it gets a TTL pulse?  Integrate for 1 ms, then send 2048 data points, then wait for next pulse?  Assuming that this is what it does, then you have a fighting chance to make a verrrrrry slooooow lock-in amplifier.

 

It would work something like this.  Set the synchronizing generator to produce one measurement trigger pulse every T ms, where T > 13+1 ms.  Let's assume T = 20 ms (fsample = 50 Hz) to keep the math simple.  Set the modulating frequency to 1 Hz.  Then you get 50 samples per period of the modulation, or one sample every 7.2 degrees.  

 

Now I need one more number.  You indicate that your AC signal is microvolts.  What is the magnitude of the DC component?  The ratio of these two signals is the signal to noise ratio.  A quick glance at the Ocean Optics web site indicates that the dynamic range for a single acquisition is 1300:1, which seems rather low for a device with a 16 bit A/D converter.  That must be the limit of the photodiodes at a specified integration time.  If the signal is really limited to this range, you may have trouble.  The lock-in amplifier depends on some signal actually being there, just smaller than the noise.  In this case due to the limits of the photodiodes or the spectrometer's digitizing process it is possible that there really is no signal there to extract.

 

If your signal has a magnitude equivalent to 10% of the dark current, you would need to average over about 100 cycles of the modulation frequency (1Hz) to begin to get a signal that you could measure with any precision.  Are your samples stable for 2 minutes or more?  

 

A different instrument might be the best bet.

 

Lynn 

0 Kudos
Message 6 of 13
(4,684 Views)

I just came upon this discussion regarding attempting to use Labview to perform a lock-in measurement of the signal from an array detector.

 

I am still wondering whether in principle such a measurement using labview. In a normal lock-in measurement there is a single input. In this case there would be 2048 inputs (1 per pixel) and each pixel would need to be lock-in amplified to a reference freq.

 

If this is possible, I am wondering exactly how you would do this. What labview VI you would use...how you would be able to input 2048 pixels and get 2048 output pixels (in-phase).

0 Kudos
Message 7 of 13
(4,378 Views)

Typically you would have a numeric array representing the pixel values.  At the next sample time you get a new set of values for each pixel, updating the array.  So the lock-in function would be applied to the array rather than the scalar value in a physical lock-in.

 

Do a search.  I think there have been several implementations of lock-in processing using LV.

 

Lynn

0 Kudos
Message 8 of 13
(4,370 Views)

I did search and found no examples of being able to lock-in on up to 2048 channels.

 

The best I could find is this example, http://zone.ni.com/devzone/cda/epd/p/id/3805

 

In this case, up to 127 channels are processed at the same time, far from 2048.

 

Because digital lock-in processing requires significant computational speed, of course there is a limit, and it seems that as the number of channels increases, the maximum sampling rate must necesarily decrease to allow the processor to keep up, e.g., http://zone.ni.com/devzone/cda/tut/p/id/3411

0 Kudos
Message 9 of 13
(4,367 Views)

That program has a bunch of password protected subVIs so you cannot see how they have implemented the lock-in.  However there is nothing that suggests that the lock-in portion is limited to 127 channels. That appears to be a limitation of the 4472 hardware.

 

Try feeding your data to the lock-in stuff and see how it works!

 

What kind of reference signal do you have?

 

Lynn

0 Kudos
Message 10 of 13
(4,357 Views)