09-15-2008 01:15 PM
HI
I wrote the following code to control a linear motor (voice coil). Can anyone help with the following issue.
The analog output of this vi laggs the analog input by 8ms (about the best i can get so far).
Is there any way to reduce the lag time? Also what is the best response i can expect without transitioning to a real time system.
hardware: usb 6211
operating system: mac osx
software: Labview 8.6
driver: NI DAQmx base 3.2
Strainmeter
09-16-2008
06:22 PM
- last edited on
04-22-2026
10:50 AM
by
Content Cleaner
Hi Strainmeter,
Thanks for posting on the NI Discussion Forums! Unfortunately, your lag time is caused by the time it takes your computer to do the processing within the while loop. You can test this by removing all components within the loop (charts, math, etc.). I also noticed that you are using a Wait Until Next Multiple. This may be slowing the execution of your loop. I always use the standard Wait function, unless I am trying to synchronize parallel loops. Using a real-time operation system would not necessarily guarantee faster execution. Real-time is typically used when determinism is needed. Take a look at the following article for more information about real-time.