Log in

View Full Version : Gyro spinning while stationary


Lumit
09-02-2010, 21:00
So... We plugged in last year's Gyro (veteran team), and the indicator on the control panel is just spinning around like crazy while it's just sitting there.

It doesn't seem to be affected by any real movement of the bot... just this random spinning.

Do we have a bad Gyro? Or is there something we were supposed to do to make it work for this year's code?

apalrd
09-02-2010, 21:17
Try calling Gyro:Reset in Begin or sometime you know the robot is not moving. This will re-set the centerpoint.

Lumit
09-02-2010, 21:27
Try calling Gyro:Reset in Begin or sometime you know the robot is not moving. This will re-set the centerpoint.
We have been able to re-set the center point, it doesn't stop it from spinning.

It's like the second hand on a clock (only much faster), you can forcibly move it back to 12 but it will continue spinning at the same rate regardless.

apalrd
09-02-2010, 22:16
Probe the output of the gyro using a multimeter. What does it say? It should be somewhere between 2 and 4 volts. If it is 0 or 5 then that is your problem.

Did you insert a wire backwards? That could cause problems.
Is the gyro powered? That could also cause problems.
Is the analog board powered? see above

Make sure you only reset it when you are not moving, and don't move it when booting up. If you might have been moving it while it was on, reboot it and try again without moving it. I have no idea when it actually sets the centerpoint, as that is protected code that is not accessible to teams (it runs on the FPGA), but I would assume it does this on Reset and startup. When it does get the centerpoint, it will think anything + or - of that centerpoint is movement, so if it was moving when it got the centerpoint it will now think that stationary is movement.