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.
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.
11-11-2020 08:46 AM
Dear all,
using a NI USB-6351 I would like to output a single sample from a previously uploaded buffer on the device memory when a rising edge of an external clock is detected on a second digital input, and to maintain this value until new rising edge is received or the task is stopped.
The clock could have non constant frequency hence the simple "trigger" to write all the buffer is not suited.
I have tried to use the option "Hardware Timed Single Loop" for the DAQmx Timing vi but it's an option not supported by the USB version of my board.
It looks like a very simple application but I wasn't able to find any example or suggestion.
Any help will be very appreciated.
Best,
Marco.
Solved! Go to Solution.
11-11-2020 09:24 AM
I'm really sorry but after few minutes I found the solution to my question here: https://forums.ni.com/t5/Multifunction-DAQ/Output-samples-per-trigger-with-all-samples-preloaded/td-...
It's for the analog output but it's easy to do the same for a digital output.
Sorry about that, it was very simple indeed.
11-11-2020 10:17 AM
In my opinion, the linked method is still more complicated than you need.
In DAQmx terms, you should think of the signal as an "external sample clock" rather than as a trigger. That has the natural effect of causing one sample to be generated per pulse. When you configure DAQmx Timing, set the 'source' to be the terminal where this signal is connected. Set some reasonable value for the 'rate' as well, but if anything you should estimate high.
-Kevin P
11-11-2020 10:19 AM
Yes, this is indeed what I'm doing after founding that the clock source can be my external clock.
Thank you!
Marco.