Multifunction DAQ

cancel
Showing results for 
Search instead for 
Did you mean: 

Acquire multiple samples with each external digital trigger event?

Solved!
Go to solution

Hi, I am using recent versions of NI-DAQmx (e.g. v19). We have been using a multitude of NI data acquisition boards over the years, but after reading all available documentation I have not been able to find an answer to a new requirement at my company: How can I acquire multiple voltage samples for each received external trigger event?

In my concrete application I want to acquire AI values. An external digital trigger is to be set up using a PFI terminal. With each trigger event at this PFI terminal we would like to acquire, say, 20 AI voltage samples (of a single AI channel), using an internal timer sample trigger. The external trigger events are expected to arrive with a rate of ca. 10.000 / s. Is it possible, using NI DAQmx features, to produce (on a NI DAQ board) a time-equidistant internal sample trigger pulse train of finite length for each received external trigger? Which DAQ boards, if any, do support this feature?

0 Kudos
Message 1 of 3
(1,826 Views)
Solution
Accepted by CKO42

X-series boards (63xx) will support finite retriggerable acquisition directly.  So would some other devices based on the newer STC3 timing chip as well, but I don't know the list.

 

Many older multifunction boards supported it indirectly by setting up a counter task as a finite retriggerable pulse train that an AI task used as its sample clock.  Here's a good example.

 

There's one other sneaky trick that is probably supported by just about any multiplexing AI device.  A multiplexing device uses 2 clocks for sampling, the sample clock and the convert clock.   For each sample clock pulse, there are typically multiple convert clock pulses -- one for each channel in the task as the convert clock drives the multiplexing switch.

    Another fairly little-known tidbit is that you can create an AI task whose channel list is just the same channel repeated many times.  Now let's bring these two things together.

    Create a task with a channel list that repeats ai0 20 times in a row.  Configure the task to use the external signal as the *sample* clock.  DAQmx will be able to figure out an appropriate rate for the convert clock if you *accurately* identify the frequency of the external clock.  It's also possible to explicitly configure the convert clock using a DAQmx Timing property node.

 

 

-Kevin P

CAUTION! New LabVIEW adopters -- it's too late for me, but you *can* save yourself. The new subscription policy for LabVIEW puts NI's hand in your wallet for the rest of your working life. Are you sure you're *that* dedicated to LabVIEW? (Summary of my reasons in this post, part of a voluminous thread of mostly complaints starting here).
Message 2 of 3
(1,792 Views)

Whoa, cool, thanks a lot for the pointers!

0 Kudos
Message 3 of 3
(1,789 Views)