Multifunction DAQ

cancel
Showing results for 
Search instead for 
Did you mean: 

ReadMultiSamples from MultiChannels - old values arrive

Hi!

I have a problem with the program which is included in the post:
I am using  DAQMx with my PCI-MIO-16E-1 card.
 
I just want to read in some voltages from all AI in a single task.
In my constructor I have declared the things. (look at the program code).
 
The only problem is, if I run the method "getAI" in a loop, I get old values, so If I measure with the multimeter and increase the voltage, on my pc it only shows realtime values 1-5sec later! 
 
why that?
I have 200Hz clock rate, and want to read with ReadMultiSample 10 Samples.
I used: Stream.ReadOverwriteMode = ReadOverwriteMode.OverwriteUnreadSamples; in the constructor, to be sure, that if my loop is too frequently, not the old 200 values which are stored in one second are used.
Is this right?
 
How can I get real Time values?
Please reply!

Thanks a lot!
Yours, Klaus
0 Kudos
Message 1 of 4
(3,080 Views)
 
0 Kudos
Message 2 of 4
(3,072 Views)
Are you sure, that you are using a differential input configuration? 
Try

AITerminalConfiguration.Rse

instead.

0 Kudos
Message 3 of 4
(3,070 Views)
yes sure, differential..

my loop takes sometimes with other pheripheral 65ms, and so I think I read old values from the buffer...
0 Kudos
Message 4 of 4
(3,061 Views)