From Friday, April 19th (11:00 PM CDT) through Saturday, April 20th (2:00 PM CDT), 2024, ni.com will undergo system upgrades that may result in temporary service interruption.

We appreciate your patience as we improve our online experience.

Machine Vision

cancel
Showing results for 
Search instead for 
Did you mean: 

IMAQ triggering to measure pulse light

Hello everyone,

First of all thanks for all the help I got from this forum by reading here 'anonymously'. Unfortunately, this time I have a problem I could not solve by myself so far. In the program I am using a state machine but changed it as can be seen in the snippet to make reading and understanding it easier.

 

I have the camera GL2018R from Sensors Unlimited, the frame grabber NI PCIe-1433 and the NI PCIe-6353 DAQ card. The camera has a 1D single line sensor and can acquire up to 147000 (147 klps) lines per second. The light source generates 1 ns pulses at a rate of 10 kHz (can be adjusted up to 20 kHz). I basically just want to trigger the camera to record one image/spectrum per trigger.  At the moment I am able to trigger, record and read out the spectra but some strange things are happening:

For example, the spectral intensity depends on the trigger (timing, exposure time and width etc), which should not be because the light is only there for 1 ns. It is very unlikely/impossible to integrate more or less of this pulse to change its intensity. The spectrum should either be there when the triggering works or not (when triggered after the light is gone).

 

Recording the signal:

First I recorded and read out the spectra continously but the readout sometimes could not keep up (losing frames) so I am now recording a finite number of spectra where each spectrum is written to a new buffer number (within a ring buffer). Afterwards the buffer is read out and a new acquisition is started when desired, as you can see in the attached snippet.

 

Triggering the acquisition:

A continous output from the DAQ board triggers the light source with 10 kHz, using ctr0. On a second channel a second trigger signal is generated with the same frequency and set to "finite output" using ctr1. The two signals are triggered using ctr3 of the board to make sure they are synchronous. The width and delay can be chosen independently. I checked the output on an oscilloscope and it works just fine and as expected.

 

Problem:

I do not know what the problem is at the moment. Although the triggering works, meaning I get one spectrum for every incoming pulse (and if I do not provide the trigger, no acquisition takes place leading to a timeout error), their intensities depends on the trigger timing. The integration time has a big influence too, which does not follow my expectations. Also, the first acquired spectrum looks normal, the second is just flat with varying intensity and after that there is an alternating intensity. Every other spectrum has a slightly lower intensity.

In the end it looks like it is not triggering correctly somehow.

I read somewhere that one has to be careful not to trigger the camera AND the frame grabber. I do not think I am doing that. I made the settings with MAX and also by sending serial commands while disabling access to the MAX settings - with basically the same result. If the light pulse arrives within the integration time of the camera there should not be a dependence on the exact trigger timing, the integration time and so on...?!

 

If I choose a long integration time and adjust the light pulse so it is in the center of the integration the spectra look all the same, which is good (except for spectra 1 & 2). Still I cannot explain the strange behavior mentioned above and thus do not trust the results

 

Please let me know if you need any additional information.

I would appreciate any help and hints you can give me.

 

Thanks!

Download All
0 Kudos
Message 1 of 1
(2,050 Views)