Quote:
Originally Posted by Michael DiRamio
It will always drift slightly. If you're noticing big changes it's likely that the robot was moving when the gyro initialized and biased. If that happens it will constantly think it is in motion afterwards. Make sure that it's completely still during boot up.
|
I think the last time I got the gyro to work properly it was changing by a degree every 5 seconds... although it wouldn't have made a huge difference, I abandoned the idea of an auto with gyro to stay straight because it made our base oscillate when I programmed it to stay within +-1degree of the original heading. When I get back to the room again, I'm going to test it again with initialization in robotinit() function, but I doubt it will make a lot of difference because the the degree of change was measured in disabled mode.
On that note, how often do other programmers call for inputs from sensors during autonomous and teleop periods? I've always called it at the beginning of every iteration but not sure if calling it every other iteration would made a huge difference.