LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

daqmx retrigger

I am using LabView 2010 with DAQmx and a USB-6216. I am looking for an efficient way to acquire analog input based on a digital trigger, inside a loop. The Example VI "Acq&Graph Voltage-Int Clk-Dig Ref.vi" is a good start, but I want to do that continuously, based on digital triggers that are arriving at a high rep rate. Thanks for any suggestions.

0 Kudos
Message 1 of 9
(3,389 Views)

Hi metro,

 

There is another example Con Acq&Graph Voltage-Ext Clk-DigStart.vi

In that VI you need to change the source for the clock from external to internal, and it will be basically the same example, but acquiring the data continuously. 

 

 

Regards,

steve.bm
AE | NI
0 Kudos
Message 2 of 9
(3,363 Views)

Hi Steve,

 

Thanks for the reply. I think that VI acquires continuously after recieving a digital trigger. What I want is a little different - I want to recieve a digital trigger, and then acquire a finite number of analog input samples. And then repeat this when each subsequent digital trigger arrives, until the user stops the VI. 

0 Kudos
Message 3 of 9
(3,359 Views)

Hi metro,

 

You can actually browse the examples from (Help > Find Examples > Hardware Input and Output > DAQmx > Analog measurements > Voltage) there is also the example called "Acq&Graph Voltage-Int Clk-Dig Start.vi", in its information box you can read :"Description: This example demonstrates how to acquire a finite amount of data (Waveform) using an internal sample clock, started by a digital edge." if you need an external clock in your application you can tweak the example and start your project with it. Just as an extra note, remember to save the examples with other names when modifying them to keep them intact for future use.

 

Eric NI

0 Kudos
Message 4 of 9
(3,346 Views)

Hi Eric. Yes, that VI is what I am starting with. But that VI is for a single digital trigger and a single data acquisition. I need to repeat this at a high rep rate. For example, say I have digital triggers coming at a rate of 100 Hz, and for each trigger, I want to grab a few milliseconds of analog input data. I could put the entire VI inside a While Loop, but it seems like there should be a more efficient way to implement this. I don't think any of the Exmaple VIs show a good way to deal with multiple digital triggers.

0 Kudos
Message 5 of 9
(3,336 Views)

Did you ever find a solution to this? I have the exact same requirement.

It appears that if I try to repeatedly initialize, wait for triggers and acquire all in a while loop, it cannot keep up with the triggers. 

0 Kudos
Message 6 of 9
(3,192 Views)

Hi Jtbr,

 

The thread you replied to is around 5 years old- you may find that your question gets better visibility if you start a new thread for it. You might also have better luck posting in the forums dedicated specifically to working with DAQ, rather than the general LabVIEW forums. 

 

Although you will likely get better and more in-depth answers there, I would recommend you look into retriggerable tasks- they're designed to do what you're describing, and depending on the hardware you're using, may be a built-in function that's available to you.

 

Kathryn K.
Technical Support Engineer
National Instruments
http://ni.com/support
0 Kudos
Message 7 of 9
(3,178 Views)

I'm using a NI USB 6210. I was able to find a solution here: https://forums.ni.com/t5/Multifunction-DAQ/External-Trigger-USB6210/td-p/3190024

0 Kudos
Message 8 of 9
(3,167 Views)

@Jtbr wrote:

Did you ever find a solution to this? I have the exact same requirement.

It appears that if I try to repeatedly initialize, wait for triggers and acquire all in a while loop, it cannot keep up with the triggers. 


Unfortunatly you need an expensive X-serie daq to have retriggerable inputs. As you said you will be limited with the USB-6210.

What I did with an USB-6003 (not sure of the specific model):

ScreenShot004.png

 

Now with an USB-6341 X-Serie DAQ:

ScreenShot005.png

Ben64

0 Kudos
Message 9 of 9
(3,156 Views)