LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

PreTriggered Acquisition and continuous reading

Hello,

 

I am using a NI USB 6251 device to sample a analogue signal with pretriggered sample with a frequency up to 180kHz. This implies the use of a reference trigger and consequently a finite sample acquisition.

 

And I want to read the buffer while the task is running in order to process data in real time in a while loop. Nevertheless the finite sample acquisition might prevent any reading of the buffer until the task is completly done. How should I set up parameters to make an acquisition that acts like a continuous one with pretriggered samples ?

 

I have joined the VI to explain the problem.

 

Note:

There is property node of  "Daqmx Read" called "ReadAllAvailSamp"that allow reading even if the buffer is not fully filled but only if the number of sample to be read is not specified ("-1"). Maybe there is such property that works in case of a specified number ?

 

I am looking forward to hearing from anyone.

 

Thomas D.

0 Kudos
Message 1 of 3
(2,843 Views)
Are you sure that using "ReadAllAvailableSamp" is not allowed with a finite number of samples to read ? I can't see any restriction of that type in LV help...
0 Kudos
Message 2 of 3
(2,823 Views)

Yes you are right, we can read sample while a task is running in finite sample. But I notice that in case of a reference trigger task, we can read the buffer only when the task is done (when all sample specified in "Sample per channel" of the "DAQmx Sample clock" VI has been sampled) whereas in case of a start trigger task we can read the buffer when ever we call the VI "DAQmx Read" to get the amout of sample specified in "Number of sample per channel" of this VI.

 

Is there any way to read the buffer during a reference trigger task ?

 

Thanks

0 Kudos
Message 3 of 3
(2,805 Views)