Quote:
Originally Posted by tilky
we want to measure the absolute angle of the robot itself. so a potentiometer would be good?
|
The angle of the robot relative to what? The field? I don't know of a way to do this, except maybe to use a potentiometer or the rotary magnetic encoder on a follower wheel - but that will have issues depending on your drivetrain.
What our team usually does is to assume the robot starts aligned with the field at power-up and integrate all the rate-of-change inputs from the gyro over time to get an absolute rotation. Note that the gyro will tend to drift a bit over time, and you'll probably want a driver station button to reset the baseline gyro output (that is, the voltage reading from the gyro which the software interprets as zero rate of change).