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.

Multifunction DAQ

cancel
Showing results for 
Search instead for 
Did you mean: 

Restarting analogue output when DAQmxWriteAnalogF64 returns an error

Solved!
Go to solution

I am using LabWindows/CVI to output analogue voltages on a PXI 6723.  My software works well until I try to write a value that is outside of the range the scale for that channel can handle.  The call to DAQmxWriteAnalogF64 rightfully returns error -200561 ("Attempted writing analog data that is too large or too small").  However following this, when I try to write in-range values, DAQmxWriteAnalogF64 returns -200293 ("The generation is not yet started, and not enough space is available in the buffer. Configure a larger buffer, or start the generation before writing more data than will fit in the buffer").  What is the cause of this?

 

Thanks

Martin

0 Kudos
Message 1 of 3
(3,035 Views)
Solution
Accepted by topic author greenstuff

When the first error occurs the task stops and will not restart until everything gets better.  If you are calling DAQmx Write with Autostart T you need to stop and start the task expressly after this error to clear the "bad value"


"Should be" isn't "Is" -Jay
0 Kudos
Message 2 of 3
(3,026 Views)

Thanks Jeff, much appreciated.

Message 3 of 3
(3,014 Views)