I am relatively new to C++ and want to know how to create odometry for my robot for next year. I know what it is and how the concept works, however, I do not know how to implement it into a vex v5 pro project. Is there a tutorial that covers this specifically, or a step-by-step guide that explains it?
While I’m sure that there are resources showing you exactly how to create this code, it will be a much better learning experience for you to create it on your own. Here is a video that really helps explain the concept: REX 1727B - Robot Position Tracking - Vex Nothing But Net - YouTube
Once you fully understand the concept, try to derive the math equations required to make odometry, then implement it in code. Following a guide that shows you how to make the whole thing will teach you close to nothing.
The pilons guide is the closest to step to step you’re going to get. The dawgma article while for pure pursuit contains a simplified version of odometry (with the formula) in the beginning. Like @Electrobotz said, a complete step by step tutorial will teach you close to nothing.
Articles
This is an extremely underrated video that explains the concept pretty clearly. You can use this along with the other linked resources to start an implementation. Intro to Odometry, Part 1 - YouTube
I’d also suggest doing some searches around GitHub if you’re looking for references. People publicly post their programs there, and they’re very valuable for learning from.
Also: I made this guide a while back, although its an extremely basic implementation that doesn’t take into account sideways motion. This only works on tank drives and might drift over time (especially if you only use omni-wheels):
You can do this, but you should keep in mind that Okapi is both abandoned and doesnt support a lot of modern odometry setups (such as using an IMU). It’s also notoriously a pain to setup properly for a lot of people.
oh wow, i had no idea Okapi wasn’t updated anymore, and in my experience it was easy to set up but if there’s anything better then what would you suggest?
IDK about a vex code library but tbh it’s summer, I recommend just learning about it and creating your own code, for me I created Odom with about 20 lines of code including the initializing of the Odom variables and such. Personally, I think the Pilons document is great however I think they also overcomplicate it. If you’re fine with it I don’t mind teaching you myself how to do Odom
Tutosingenieria has a really easy to follow video on the math that I would recommend for code. In terms of on the bot i would recommend puting the encoders on unpowered wheels to reduce slipping errors.
I looked at that and I didn’t understand. I’m in MS and it was really the math that got me confused and I was wondering if somebody could verbally explain it to me?
If you are in MS I am not sure if you will be able to understand it. Have you taken Geometry yet? If not, try to learn about sine and cosine functions. There is another document which is simpler that is on my laptop, I will send it tomorrow.