06-17-2009 03:33 PM
I have created an analog task as follows:
(DAQmxCreateTask("",&AItaskHandle));
(DAQmxCreateAIVoltageChan(AItaskHandle,"Dev1/ai0:1, Dev1/ai3:6,Dev1/ai16:19","",DAQmx_Val_Diff,
-5.0,5.0,DAQmx_Val_Volts,NULL));
(DAQmxCreateAIVoltageChan(AItaskHandle,"Dev1/ai2","",DAQmx_Val_NRSE,-5.0,5.0,DAQmx_Val_Volts,NULL));
(DAQmxCreateAIVoltageChan(AItaskHandle,"Dev1/ai10","",DAQmx_Val_NRSE,-5.0,5.0,DAQmx_Val_Volts,NULL));
(DAQmxCreateAIVoltageChan(AItaskHandle,"Dev1/ai7","",DAQmx_Val_NRSE,-5.0,5.0,DAQmx_Val_Volts,NULL));
(DAQmxCreateAIVoltageChan(AItaskHandle,"Dev1/ai20","",DAQmx_Val_NRSE,-5.0,5.0,DAQmx_Val_Volts,NULL));
(DAQmxCreateAIVoltageChan(AItaskHandle,"Dev1/ai28","",DAQmx_Val_NRSE,-5.0,5.0,DAQmx_Val_Volts,NULL));
If the resulting data is grouped by channel (non interleaved) is the order of the data in the buffer by channel number or by the order in which
the task was configured?
In other words does the buffer store all the differential inputs and then append each of NRSE channel data?
Thanks in advance for your help.
06-18-2009 03:55 PM
The order of channels listed determines the scan order when taking your measurement. So, the way you have your program set up, you will store the data by how they are configured not by channel order. The document below discusses this briefly.
Order that Channels are Sampled during Analog Input Measurement
http://digital.ni.com/public.nsf/allkb/E55EAE3553DD09C986256ADF006E7BD4?OpenDocument
If you were to view the 2D-array of the resultant data from your program, row 3 of the array would be data returned from channel 10.