I have a PCI - 6250 under CentOS 6. I am tying to read 9 Analog input channels ( 1 m acquisition time, voltage between 4.5 and 5.1 volts):
float minVolt=4.4; float maxVolt=5.1; float daqTimeInterval = 10.0; DAQmxErrChk (DAQmxCreateAIVoltageChan(taskHandle,"Dev1/ai1:9","tube",DAQmx_Val_RSE,minVolt,maxVolt,DAQmx_Val_Volts,NULL)); DAQmxErrChk (DAQmxCfgSampClkTiming(taskHandle,"", 1000,DAQmx_Val_Rising,DAQmx_Val_ContSamps,100000));
and then read it with:
DAQmxErrChk (DAQmxReadAnalogF64(taskHandle,-1, daqTimeInterval,DAQmx_Val_GroupByChannel,data,1000,&tubeCounts,NULL));
Problems:
it doesn't read for the required time interval (here 10 s)
The min and max voltage values does not really matter.
Question:
How can I parse the "data" and "tubeCounts" in order to obtain the readings per channel and use them every minute?
Is it possble to use the custom virtual channels name (in this example "tube1...")
Thanks.