Front of Robot is 90 Degrees off in Path Planner

Hello.

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?

Thanks

i think you are misinterpreting the dot of the square on the robot pose.

this is a robot pose:
image

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).

this corresponds to your robot gyro, which in the case of a ctre pigeon, follows the diagram printed on the case:

0 degrees will be on positive x, 90 degrees on positive y, 180 degrees on negative x, 270 or -90 degrees will be negative y

hope this helps!

There was Just a thread on this topic a day or three ago… I’ll take a look. Search generally works pretty well.

Edit:
Not the one I was thinking about, but still hopefully worth a look:

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