Here is my code to do the sampling:
rtn = DAQmxStartTask(taskHandle);
rtn = DAQmxGetTimingAttribute (gDAQmxAnalogInTask, DAQmx_SampClk_Rate, (void *)data);
rtn = DAQmxReadAnalogF64(taskHandle, numSamplePerCh, 10.0, DAQmx_Val_GroupByChannel,
inData, numCh*numSamplePerCh, &daqRead, NULL);
The sample clock rate DAQmxGetTimingAttribute () returned to *data is 5000.
In DAQmxReadAnalogF64(), numCh=2, numSamplePerCh=180, the samples
returned in inData showed that there were 40 samples high, 40 samples
low for one cycle.
I changed the sample rate to 100 and did again, and got the same samples in inData.
I used scope to check the signales I sampled. It was always a 500Hz square waveform.
Thanks.
Jason