10-05-2005 04:08 PM
I thought this should be implemented by
DAQmxCfgImplicitTiming(TaskHandle, DAQmx_Val_OnDemand,1);
but i got the following message in this call:
--------------
ERROR: Requested value is not a supported value for this property.
Property: DAQmx_SampTimingType
You Have Requested: DAQmx_Val_Implicit
You Can Select: DAQmx_Val_SampClk, DAQmx_Val_OnDemand
Status Code: -200077
--------------
If I use another timing:
DAQmxCfgSampClkTiming(TaskHandle,'',100.0,DAQmx_Val_Rising,DAQmx_Val_ContSamps,100);
everything is fine, but sometimes I got the error:
--------------
ERROR: Attempted to read samples that are no longer available. The requested sample was previously available, but has since been overwritten.
Increasing the buffer size, reading the data more frequently, or specifying a fixed number of samples to read instead of reading all available samples might correct the problem.
Property: DAQmx_Read_RelativeTo
Corresponding Value: DAQmx_Val_CurrReadPos
Property: DAQmx_Read_Offset
Corresponding Value:
Status Code: -200279
---------------
After that task is destroyed.
How can I use Implicit Timing with acquiring readings
by software?
Thanks,
Peter.
10-13-2005 02:51 PM
Peter,
I am a little confused, in the DAQmx C Reference Help that installs in the National Instruments->NI-DAQ folder, it lists the second input of DAQmxCfgImplicitTiming as "Sample Mode" with the options of "DAQmx_Val_FiniteSamps", "DAQmx_Val_ContSamps", and "DAQmx_Val_HWTimedSinglePoint". Make sure you are calling the right function and passing the right type of inputs. The C Reference help is located in the Start Menu->Programs->National Instruments->NI-DAQ folder. Also make sure you are running the latest NI-DAQmx driver (version 7.5) available on the web. Other than that, it sounds like since the software will be handling the sampling, you would want On Demand as your option. Best of luck, let us know what else we can do to help.
Erik F
NI - Applications Engineer