How do I implement odometry

Zakhar from 70220A here.

We are a first year team and getting ready to code auton. We heard of odometry, but I have absolutely no idea what to do to implement it. Any tutorials or tips?

It can be done with an odometry pod, and a inertial sensor. The pod has a freewheel that allows you to know which way the robot is moving, and you do a little trig with the inertial sensor. I can provide the math if needed.

If you want to do it without an odometry pod, that’s a bit harder. I’m actually working on that problem right now, and I’ll let you know if I solve it. My current thesis is that it’s less accurate, but can still work with the proper adjustments.

What do you need odometry for? In a few cases you can just use gps sensors instead if your school has them. It’s also become a standard at states and worlds to have the gps strips on the field.

1 Like

Odometry | Purdue SIGBots Wiki
This page has some pretty good information, I would definitely recommend checking it out.

3 Likes

There’s a lot to unpack with odom and since you are a first year team I would say it may be better to start off simpler (such as using the built in move commands with vexcode) but perhaps you guys have programming experience or just want to start with odom.

The first thing you can do is use the search bar on the forum and search for “odometry” or”odometry help” as there are lots of threads with a similar question. If you’re planning on implementing odom like Joeger_Bahar said you’ll need tracking wheels which track the position of the robot. (search for “tracking wheel” for threads about those.) As for the programming side, I would highly reccomend reading the Pilons document (http://thepilons.ca/wp-content/uploads/2018/10/Tracking.pdf) on odom so you can understand how it works. Once you’ve looked that over and decided whether odometry is worth it for you, consider looking at libraries like EZTemplate (EZ-Template | EZ-Template ) which make the process a lot easier. Again, make sure you actually understand what’s going on behind the scenes (especially for when you are interviewed at events) and document everything in the engineering notebook.

3 Likes

Doing it without an odometry pod is not harder, if anything it’s easier. It is quite significantly less accurate though. All you need to do is use the integrated motor encoders to get your local delta X and assume your local delta Y to be 0. This is less accurate and won’t work well if pushed but it may be accurate enough for a 15 second auton if you have traction wheels.

2 Likes

I didn’t necessarily mean harder, it just takes more effort (from the programmer of course), and has more error.

1 Like

If you want to do it without an odometry pod, that’s a bit harder. I’m actually working on that problem right now, and I’ll let you know if I solve it. My current thesis is that it’s less accurate, but can still work with the proper adjustments.

It is quite significantly less accurate though.

I didn’t necessarily mean harder, it just takes more effort (from the programmer of course), and has more error.

Motor Encoder Odom can be pretty accurate with Kalman Filters. It takes a bit more effort to do, but after implementing the algorithm you can get 0 trackers and still be pretty accurate. However, if you have all omni wheel, you’ll probably need a perpendicular wheel.

1 Like

Honestly arc-based odometry with the VEX IMU and rotation sensors at a rate of 100Hz (a step time of 10ms), you’re set to have a really really good system even without a kalman filter.

Look up on google: 5225A arc based odometry and also don’t hesitate to ask questions!

1 Like