12-12-2019 02:07 PM
Hello helpers!
For some reason the sampling rate defined in the following two examples( VIs attached as screenshots A and B) is not respected at all. Instead it outputs at a much faster rate. I've also attached the oscilloscope readout in this post which was the same for both the VIs.
The DAQ card I use is NI USB-6001. Is this a limitation to the device model?
Thanks in advance for the help 🙂
Cheers,
Vivek
12-12-2019 02:21 PM
Set aside external clocking...
We can only REQUEST a sample rate. The actual sample rate is limited by the clock chip and the clock divider logic. DAQmx will choose a sample rate as close as possible to the requested rate. If you need to know what rate was selected there property node that will tell you that.
Ben
12-12-2019 02:46 PM
Use the DAQmx Timing VI to set your timing. Your first example won't work because you're not setting up your timing. The second one might work but setting just a few properties might mean you get something wrong.
DAQ output doesn't use the waveform timing for its timing source, you have to use the aforementioned Timing vi to set that.
12-13-2019 01:27 PM
LabVIEW ships with Examples! Look up the Analog Output examples and simplify it to suit your situation (you don't need the Tab Control for Trigger settings, for example). Note, in particular, the use of the DAQmx Timing VI, the fact that the data are written to DAQmx Write before the DAQ device is started (so there's something to output!), and other differences.
Bob Schor