Ethernet cDAQ Not Sending On-the-Fly Updates for Analog Output

Updated Sep 13, 2018

Reported In

Hardware

  • NI-9918
  • cDAQ-9189

Software

  • LabVIEW

Driver

  • NI-DAQmx

Issue Details

I am using the DAQmx shipping example Analog Output (non-regeneration) Voltage.vi. When I change parameters such as amplitude or frequency, I do not see the changes to the signal. Why is this happening?

Solution

Use either of the following solutions to resolve this:
  1. Set buffer size to 2 buffers using the example How to Decrease the Update Delay with Analog Output in a cDAQ 9188.  DAQmx Write function is only 2 buffer sizes ahead of the actual signal generation rather than as fast as possible. When the frequency or amplitude is changed by the user, these values will be generated within the 2 buffer sizes.
  2.  Include a "Wait (ms)" to the loop that is equal to the amount of time per Analog Output buffer (Number of Samples/Sample Rate)*1000. For example, assuming 2000 Samples/s written in 500 Sample buffer, 250 ms of data is written at a time.

Additional Information

cDAQ 9188 and 9181 communicate via Ethernet, so a buffer is required to handle network events. Output data is written faster than what is output from the chassis. Assuming 2000 Samples/s written in 500 Sample buffer (250 ms of data), a USB cDAQ will wait the 250 ms per loop iteration while an Ethernet cDAQ will fill the buffer as fast as possible.

The network buffer for Ethernet cDAQ causes a delay between the time the user changes the frequency or amplitude of the output signal and the time the device under test receives the updated signal. This problem is also common with new TSN enabled Ethernet cDAQ chassis.

WAS THIS ARTICLE HELPFUL?

Not Helpful