Odometry(libraries, docs, etc.) for VEX IQ

Sorry if my writing is bad, since this is my first time putting anything on the VEX Forum.

I’ll be blunt about it; I’ve been looking for anything about odometry for VEX IQ for a few weeks, and all I’ve found are libraries, forum posts, etc. for V5. Does anyone know of anything like the JAR-Template or Okapilib for VEX IQ?(yes, I read the Pilons doc). Sorry again if I’m missing some critical thing about IQ motors or encoders or something. Thanks for helping.

1 Like

There was another thread not that long ago where someone was asking about it, so you should be able to search and find it.

Vex IQ doesn’t have much in the way of odometry at this point because of the limited sensors available, and the competition limit on motors.

At present, you can only really track movement with a motor, and 6 motors is the limit, whether they’re powered or not. There are no shaft rotational-type sensors or other encoders available.

Theoretically, you could rely on the motor encoders that are moving the drivetrain motors, but if you can trust them, then the need for odometry complexity is probably largely offset, since you can use other methods to calculate/drive position.

1 Like

Also, if there’s a reason that nobody’s replying please tell me so I can ask my question better next time. Thanks.

I don’t think it’s possible to actually do odometry because VEX IQ has no rotation sensors, I guess you could use a motor, but that’s a waste. Unfortunately you have to stick with simple PID for now :l

Don’t want to sound rude, but what other ways are there to track position/drive to a point?

Note, I am not an odometry expert, I know the basics of it, so requisite grain of salt should be assumed here.

V5/U/AI have more sensors to use, primarily to my knowledge shaft rotary encoders that can tell how much a shaft has rotated, within a certain amount of error in degrees. These are attached to axels that are attached to wheels without a motor, typically in X & Y planes to be able to independently track distance, without the drivetrain causing error (via gear backlash, gear slips, or other causes). Since these move independently, you have a much more true accounting for where you are.

IQ doesn’t (at this point) have that type of sensor, so the closest you’re going to get for IQ will be to use the motor encoders in the drivetrain. Again, unless you want to sacrifice 2 of your 6 motors, put in coast mode, to use as your tracking wheels; maybe it’s doable with pneumatics as a PTO to let your last two motors switch between multiple functions, but seems like it would be a massive disadvantage to me.

The only other way I see you having a relatively more “true” sense of where the robot is on the field would be to use a distance sensor to try to keep track of where you are. I’m sure someone could do the math to make it happen, but I’m not sure if the IQ brain has enough horsepower to do all the math at a fast enough rate to make it work.

4 Likes

What about the values of the brain inertial do those work for odometer on IQ ?

1 Like

There are lines on the field tiles that can be used for position.

1 Like