07-23-2009 09:42 AM
Hello!
My setup:
NI USB6008
NiDaqMxBase
Linux OpenSUSE 11.0 on netbook Toshiba NB200
I need to measure 4 AI channels 5 times a second.
I do:
create AI0 ... AI3 = DAQmxBaseCreateAIVoltageChan( taskHandle, chan, "", DAQmx_Val_RSE, min, max, DAQmx_Val_Volts, NULL )
do
start AI0 - read AI0 - stop AI0 = DAQmxBaseStartTask(thAI0) - DAQmxBaseReadAnalogF64(thAI0... - DAQmxBaseStopTask(thAI0);
...
start AI3 - read AI3 - stop AI3
while true
One do-while loop takes ~ 1 second
The question: Is there a way to speed up the procedure?
Vadim.
Solved! Go to Solution.
07-24-2009 05:00 PM
Hello Vadim,
To speed up your program I recommend setting your acquisition to do a continiuos read, as suppose to starting the task, reading one sample and ending the task, where most of your delay is likeely occurring. Look in the following folder \\...National Instruments\NI-DAQmx Base\Examples\aicontAcquireNChan.c,for such an example.
Regards,
Glenn
Applications Engineer
National Instruments
07-27-2009 07:22 AM
Thank you! I got the idea.
Regards, Vadim.