JPannetier Geschrieben August 29, 2018 at 09:36 Geschrieben August 29, 2018 at 09:36 Hello everybody, I'm trying to implement a code (Python) to get position x y z from IMU Brick 2.0 accelerometer, in live mode. In the first step, I implemented the rotate accelerometer by quaternion to remove the gravity and rotation of my sensor. After i integrate directly to have velocity and position : example : Vx(k) = Vx(k-1)+Ax(k)*dt X(k) = X(k-1) + Vx(k)*dt Nevertheless, into my accel. data I have an offset. Somebody would have already implemented this type of code to remove the offset (drift) ? to get the position I don't know if i must a kalman filter or other.... Thank you Zitieren
pwab Geschrieben September 2, 2018 at 15:36 Geschrieben September 2, 2018 at 15:36 Hello JPannetier, I wanted to do the same a while back and did some research and I want to help not wasting time on this. To sum things up: you can't get good position information over time by only using an IMU. This topic is called Dead reckoning (https://en.wikipedia.org/wiki/Dead_reckoning) and is way harder to get running as it seems to be at first sight. A lot of people had this idea and ended up using something different. See here for reference: https://stackoverflow.com/questions/26476467/calculating-displacement-using-accelerometer-and-gyroscope-mpu6050https://electronics.stackexchange.com/questions/4983/how-to-determine-position-from-gyroscope-and-accelerometer-input#4986https://electronics.stackexchange.com/questions/96722/tracking-2d-positioning-with-imu-sensor The problem is noise and precision of measurement when using acceleration or velocity data over time for estimating a position. To get a grasp of the topic I can recommend watching this video (the starting position marks the explanation of why your double integration leads to a drift): In fact VR-headsets use sensor fusion by combining their IMU data (gyroscope and accelerometer) with their optical IR-light-based marker positions (also called pose estimation). I can recommend a very good talk by Philipp Zabel about HMD tracking systems (german language but images and animations should give you some impressions) and some related videos on youtube: https://chemnitzer.linux-tage.de/2018/de/programm/beitrag/288 So what you could do is to: Add internal sensors which track the current position with markers, by scanning a known environment with markerless tracking algorithms or by using systems like GPSAdd external sensors which track the position and orientation of your system and use it to recalibrate your IMU data with at least more than 30 HzUse position sensors which will inevitably affect the shape and size of your system (https://en.wikipedia.org/wiki/Position_sensor) Hope this helps Regards, Philipp Zitieren
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.