LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Something akin to Hardware Timed Single Point for cDAQ in DAQmx

I have a cDAQ-9188 with a 9375 DIO module (3 of them actually) that I need to output a constant value on but then change that value on the fly. The changes may happen rapidly, on the order of 10 ms during a test. Ideally I would use the Hardware Timed Single Point sampling mode (DAQmx Sample Clock vi) because it would output the same value continuously until changed without a buffer, but unfortunately cDAQ does not support this sample mode. I don't want to just fill up a large buffer because I may need to change the output value's rapidly (and the value of the output may not be known far enough in advance to fill a buffer of the appropriate values).

 

Any suggestions?

 

LV 2016, 32 bit

0 Kudos
Message 1 of 5
(3,023 Views)

Hello,

 

I found an example that I think does something similar to what you are looking for. The example uses 1 Channel 1 Sample for the DAQmx Write Mode, but this could easily be changed to 1 Channel 1 Sample mode to give you the ability to update on the fly and not have to worry about a buffer being written. I have attached the example here.

 

DAQmx Continuous Write: http://www.ni.com/example/25211/en/ 

 

Hope this helps!

 

Regards,

Conrad

Applications Engineer 

National Instruments

0 Kudos
Message 2 of 5
(2,981 Views)

This VI didn't work. Similar issue to what I've seen several times in my attempts in that there is no data in the output buffer to write. 

 

NI Error -200462.jpg

0 Kudos
Message 3 of 5
(2,979 Views)

And, just what is wrong with DAQmx Write (nCh 1Samp).vi?


"Should be" isn't "Is" -Jay
0 Kudos
Message 4 of 5
(2,974 Views)

DAQmx Start Task expects data to be buffered before the start task vi is called if the Sample Clock vi is used to configure the channel. If you take Sample Clock vi out, this works (there is a simple example in the build in help called "Digital - SW-Timed Ouptut.vi". The problem is that without the Sample Clock vi, I'm not able to configure the sample clock, rate, (for synchronization with other tasks). 

0 Kudos
Message 5 of 5
(2,970 Views)