Fixing Pose with AprilTags

Our team is trying to do pathing in teleop, which has been working. But our problem is that our pose and odometry get messed up with wheel slippage and encoder misreadings. So we decided to get a limelight 3 and setup our home field with AprilTags. But I can not figure out how to “fix” our pose with the “megabotpose?” or whatever the limelight pose is called.

Our code is at: GitHub - FireIslandFRC/PathPlannerTest2024: testing PathPlanner with the Mk4i swerve

Any help is appreciated, thank you!!

You will need to use a Pose Estimator, which will fuse the readings from your wheel encoders (odometry) and your vision measurements (limelight). Take a look through that page. Limelight docs also have a section about how to implement the Limelight data. I’m not sure how much experience you have with Limelight, so here is another helpful page about actually getting the data from the Limelight. This is a very basic answer that requires you to do some reading, so please feel free to ask more questions if you get stuck!

1 Like

PhotonVision is also a great option.

You can use our repo as reference for that.

1 Like

This topic was automatically closed 365 days after the last reply. New replies are no longer allowed.