I’ve been having a weird issue while using path following with RamseteCommand. Sometimes, instead of following the path, the robot will spin in circles. This isn’t very common though, maybe happening 1 in 10 times, which makes it painful to debug. I’ll run the auto, everything works great, then without redeploying code or changing anything, I’ll drive the robot back to the starting spot, put the cargo back, start the auto again, and when it gets to driving it will spin. Most of the time the path following works great, so it’s not something simple like flipped gyro or encoders. This has happened right after turning on with a new battery, on a battery that hasn’t been changed in half an hour, and everything in between.
Any help would be greatly appreciated. I’m at a loss of what could be causing this issue.
All the code running while seeing these issues is here. I’m only using new/ThreeCargoA and new/ThreeCargoB.