Quote:
Originally Posted by Tom Line
Austin, can you suggest a test that would determine if there are jitter problems?
I'd guess you're talking about high-speed velocity control, but give me specifics on what caused you trouble in the past.
|
Hi Tom,
Write a loop which sleeps for X msec, or runs code in a notifier at a specified frequency, and then reads the system clock and looks for how long it actually slept. Do this a large number of times and plot it. I would expect to see Gaussian noise of small magnitude if things are working right.
Yes, we had a problem with a high accuracy velocity loop. On the cRIO, I was seeing a 100 hz loop returning anywhere from 5 to 15 ms (I think it was worse, but I'll guess low). You could hear it in the loop. The state space observer made the assumption that the timestep was constant at 10 ms to simplify the math. The loop would throw the motor into full reverse occasionally on our flywheel to deal with the large apparent change in velocity. Our programmer dealt with this by registering a timer interrupt on vxworks so our code would get run every 10 system ticks, but that was a lot more work than it should have been. You would expect that "sleep" on a realtime system would sleep for the correct amount of time if the priority is right. 254 never got it working correctly with Java, and I had to detune the observer to deal with it.
Austin