My team is working with path planner for autonomous runs this year and have encountered a problem where the point on the robot which path planner perceives as the front of the robot is actually 90 degrees off of the actual front of the robot. This causes the robot to move sideways rather than forwards.
I don’t think that this is an issue with our gyro as when controlling the robot in teleoperated mode, the robot is still able function correctly. Does anyone have an idea on how to fix this problem?
i think you are misinterpreting the dot of the square on the robot pose.
this is a robot pose:
the brighter red circle in the middle is the center of the robot, while the darker point to the right, along the perimeter, is 0 degrees (as in unit circle).
We had a very similar issue in our off season. We found that our cancoders had been set so their zero was pointing in the wrong direction, and once we recalibrated them to the correct direction, pathplanner went straight when we expected it to