Multifunction DAQ

cancel
Showing results for 
Search instead for 
Did you mean: 

Error -200474 (I'm using Hardware Timed Single Point mode)

Why I'm getting (random time after measure start) error -200474 (Specified operation did not complete, because the specified timeout expired. Device: Dev1 Task Name: aiTask)?
This is configuration of Task:
myTask.AIChannels.CreateVoltageChannel("Dev1/ai1,Dev1/ai2","aiChannel1,aiChannel2",AITerminalConfiguration.Rse,-2,2,AIVoltageUnits.Volts);
myTask.Timing.ConfigureSampleClock("",40,SampleClockActiveEdge.Rising,SampleQuantityMode.HardwareTimedSinglePoint);
analogInReader.BeginReadSingleSample(analogCallback,null);

This is analogCallback function:
data = analogInReader.EndReadSingleSample(ar);
//plot my data[0] and data[1]
analogInReader.BeginReadSingleSample(analogCallback,null);

It work, but sometimes I get error message -200474. Why?
0 Kudos
Message 1 of 4
(4,272 Views)
Milosh,
I'd like to help you out. Could you please post some more information about your system.
What is your OS?
What hardware are you using?
What version of NI-DAQ do you have?
Is that a C#.net program?
Are you running this program continuously?
If so, is there a reason you are using single point acquisition as opposed to continuous?
Any other pertinent information would be helpful also.
-Alan A.
0 Kudos
Message 2 of 4
(4,258 Views)
Thank you for your interest,
OS: Win 2000 sp4
HW: PCMCIA DAQ card 6024E, PC notebook Celeron 2.4 Ghz, 256 RAM, SiS chipset...
NI-DAQmx 7.2
Yes it is C#.net program
I am running this program continuously, rate is 40Hz
I am using single point acquisition because I want to measure voltage in real time.
I have to plot value immediately for visual feedback.
Thank you for answer & sorry for my english 🙂
Milosh
0 Kudos
Message 3 of 4
(4,240 Views)

@Milosh wrote:
I have to plot value immediately for visual feedback.
Thank you for answer & sorry for my english 🙂
Milosh




I'm doing the same thing. I use regular scanning, and DAQmxReadAnalogF64() with a timeout of 0.0. Then check sampsPerChanRead to see if any samples were actually read. I also check the error return for errors DAQmxErrorTimeoutExceeded and DAQmxErrorSamplesNotYetAvailable so that I can check for errors but ignore these.

Be aware that if you specify DAQmx_Val_GroupByChannel, the data will be arranged like this:

c1_1, c1_2, 0, 0, ..., c2_1, c2_2,...

where I have used c1_2 to indicate channel 1, second sample. That is, if you specify N samples per channel, the first sample for the second channel is at point N in your array.
John Weeks

WaveMetrics, Inc.
Phone (503) 620-3001
Fax (503) 620-6754
www.wavemetrics.com
0 Kudos
Message 4 of 4
(4,218 Views)