LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Best programming technique: AO single sample vs multiple sample on boards with waveform capability

I am calling for AO on 7 channels of the NI6715. Two of the channels sometimes need to provide a rastering signal (sawtooth ranging from 100 Hz to 10 kHz) and sometimes a DC signal. The other channels are always DC. I have a Boolean to switch from DC to raster. The sawtooth is computed from the frequency, amplitude, etc and the values placed in 2D array along with the DC values for the other channels with the DAQ Write configured for 2D, NChannels,NSamples. Programmatically, it seems to be easier to always send a 2D array, even when not rastering - I can just fill the array with constant values without changing the type of the Write function. However, is this using more resources than necessary? Is it better to reconfigure the timing and write functions when only DC outputs are required, changing the Write function to 1D,NChannels,1Sample?
Thanks, Peg
0 Kudos
Message 1 of 2
(2,536 Views)
From what I understand of you application, I doubt you use significantly (if any) more resources by always sending the 2D array.  If you haven't already, look through the Managing Performance and Memory topic under Fundamentals in the Labview Help.  I pasted a relevant section below.  How you handle the array could make a difference too, which is explained in the VI Memory Usage section of the help topic mentioned above.

From Labview Help -> Fundamentals -> Managing Performance and Memory -> Concepts -> VI Execution Speed:
In addition, overhead for the AI Acquire Waveform VI is roughly the same as the overhead for a single call to the AI Sample Channel VI, even though it is transferring much more data. 


0 Kudos
Message 2 of 2
(2,522 Views)