You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Yeah, that seems interesting; and it could definitely be useful for beginners (it is, after all, intended for that audience). I find it funny how it was inspired by ev3dev projects, then implemented in EV3-G, and now we are going to translate it to ev3dev code again 😆
Now that MoveDifferential and DistanceValue classes are in, work can begin on odometry. @WasabiFan@ddemidov thoughts on what the API for this should look like? I think most changes we make will need to be in the MoveDifferential class as that is the only place we know the wheel dimensions and spacing needed to do the calculations.
It could be as simple as passing a use_gyro_for_accuracy bool to
on_for_distance
turn_right
turn_left
on_arc_right/on_arc_left I need to give this one some thought
Is there anything we want to do for the case where a gyro is not available? MoveDifferential is already providing some basic odometry. I can update it to use the new DistanceValue classes but beyond that I can't think of anything else to add for a non-gyro scenario.
👍 I've developed odometry systems in the past, so I have a pretty good idea of what goes into this. For encoder-only tracking, it's really just doing the kinematics math. If you have an IMU, you'd typically throw that into the mix via a Kalman filter (probably just constant-velocity in our case, I doubt introducing acceleration would matter much). But initially, the tracking is really just some trig for a rigid body. It looks like that source includes all the needed calculations for that.
Activity
WasabiFan commentedon Oct 24, 2016
Yeah, that seems interesting; and it could definitely be useful for beginners (it is, after all, intended for that audience). I find it funny how it was inspired by ev3dev projects, then implemented in EV3-G, and now we are going to translate it to ev3dev code again 😆
dwalton76 commentedon Aug 6, 2018
It has been almost 2 years and I haven't even started on this one. I am going to close it and we can re-open if someone wants to work on it.
dwalton76 commentedon Nov 7, 2018
Now that MoveDifferential and DistanceValue classes are in, work can begin on odometry. @WasabiFan @ddemidov thoughts on what the API for this should look like? I think most changes we make will need to be in the MoveDifferential class as that is the only place we know the wheel dimensions and spacing needed to do the calculations.
It could be as simple as passing a
use_gyro_for_accuracybool toIs there anything we want to do for the case where a gyro is not available?
MoveDifferentialis already providing some basic odometry. I can update it to use the new DistanceValue classes but beyond that I can't think of anything else to add for a non-gyro scenario.dwalton76 commentedon Nov 7, 2018
One big use case for this could be First Lego League.
WasabiFan commentedon Nov 7, 2018
I think that makes sense. The main things you want to do which are odometry-backed are going straight and doing a circular turn.
dwalton76 commentedon Apr 6, 2019
Doing some research on this...the ev3dev project that was the source of inspiration for the EV3-G implementation was https://www.ev3dev.org/projects/2016/08/07/Mapping/
This chunk of code reads the motor positions periodically and sends those (plus the timestamp) to some other program via a UDP socket
https://github.com/bmegli/ev3dev-mapping-modules/blob/master/ev3odometry/main.cpp
Not sure yet what code it is sending that data to though
dwalton76 commentedon Apr 6, 2019
Great source here:
http://seattlerobotics.org/encoder/200610/Article3/IMU%20Odometry,%20by%20David%20Anderson.htm
WasabiFan commentedon Apr 7, 2019
👍 I've developed odometry systems in the past, so I have a pretty good idea of what goes into this. For encoder-only tracking, it's really just doing the kinematics math. If you have an IMU, you'd typically throw that into the mix via a Kalman filter (probably just constant-velocity in our case, I doubt introducing acceleration would matter much). But initially, the tracking is really just some trig for a rigid body. It looks like that source includes all the needed calculations for that.