micropython-fusion
micropython-fusion copied to clipboard
How to get position updates?
So I see how we get heading, pitch, roll. How to get position updates?
That is not possible using an IMU. In theory it can be done by double integrating the accelerometer, but in practice errors accumulate exponentially. I believe it can be done with extreme precision accelerometers, but not with ones we can buy.
You need to find another way: counting wheel revolutions on a wheeled robot, or using GPS.
These guys tend to promise position+quaternion pairs. Here is their implementation sample, their license is also MITish.
I would be fascinated to hear of any success with this. My own experiments produced exactly the (bad) result I expected.
As far as I can see, basic physics requires double integration with its inherent vice of amplifying errors. This code comment seems to suggest that they are double integrating. However I'm willing to be convinced that they have discovered something I've missed. Perhaps there is some clever filtering technique?
@OlegJakushkin have you had any success from that implementation? As @peterhinch mentioned, I also haven't any good results double integrating due to cumulative errors.