Real-Time Measurement and Control

cancel
Showing results for 
Search instead for 
Did you mean: 
Reply

Why does the double buffered waveform generation pause after the first buffer before continuing?

I am using an AT-AO-10 board to generate a multiple channel waveform in double buffered mode. The board's DAC's are updated by an external clock signal. While the waveform generation performs well, I notice that after the first buffer has been generated there is a time delay before the next buffer is output. However the second buffer and thereafter perform well without any time delays. If anyone can provide me an explanation on why this happens I would appreciate it. I am using NI-DAQ API functions to generate the waveforms and my settings for the WFM_DB_Config function are 1 for oldDataStop to disallow regeneration of data and 0 for partialTransferStop
to not stop when a half buffer is partially transferred.
0 Kudos
Message 1 of 2
(2,309 Views)
Vadi,

The first thing is to make sure that you have the latest version of NI-DAQ installed, NI-DAQ 6.9.1. If you need to install it, make sure you completely uninstall any prior versions. Then, you will have examples installed in either the NI-DAQ or the CVI directory. In the AO directory, you should find the WFMdoubleBuf example.

Start with that to make sure the output appears as you expect. Then, you can modify it to apply your external update clock, following the idea presented in the WFMsingleBufExtUpdate example. You might even want to double-check that your external clock acts as you expect using an oscilloscope.

Finally, modify the example such that you can update on multiple channels, remembering that you interleave each channels buffer into one buf
fer for WFM_DB_Transfer. Whatever data is in the buffer will be updated on the output channels.

Regards,
Geneva L.
Applications Engineer
National Instruments
0 Kudos
Message 2 of 2
(2,309 Views)