My team’s gyro is not sending right values.
We are using vex code, and we have a function that requests the value of the gyro in degrees. We were trying to do gyro-based turns with PID, sometimes it worked, sometimes it didn’t. Let me describe you the behavior of the gyro:
For teleoperated driving, the gyro sends perfect values for the console, but in some time it will start sending nonsense values, like, it starts decreasing or increasing constantly, forever. I noticed that happens when the robot is driven to fast.
In autonomous for driving straight with PID, it works just fine, the robot autocorrects its path to a specific degree, but again, after a certain time the gyro’s values start sending nonsense data and the robot starts spinning.
For autonomous to turn to a specific degree with PID, it will only work if the target is 0. Whenever I ask to go to a different target, like 90 or 180, it starts sending the wrong values, and the bot just spins.
Has that ever happened to your gyro? I don’t know if I’m using it incorrectly, or if it is an actual malfunction on the component. We don’t have an extra-gyro to check if it is a problem on the compenent. If you know what’s wrong, please let me know.