# Tracking 2D positioning with IMU Sensor [duplicate]

I am using a miniature car and I want to estimate the position. We can not use GPS modules and most of the tracking systems that I saw, are using IMU senson with the GPS module. In our car we are able to find our exact correct location with image processing but for some parts that dont have enough markings we can not do this. So we want to use the IMU as backup for our positioning. so as long as the positioning is close is good for us.

And we are only interested in our 2D position since the car is on a flat ground.

I am using a IMU 9DOF sensor and I want to calculate my movement. I have seen some amazing works with IMU for tracking body movements but no code or simple explanation is anywhere about it. So basically I have the reading from accelerometer, gyro and magnetometer. I also have orientation in quarternions. From the device I am getting also the linear acceleration but even when I am not moving it in any direction the values are not 0 which is really confusing.

Can you please help me how to approach this?

Thanks in advance

## 1 Answer

An IMU as any sensor is not perfect and it is affected by errors.

In IMUs case there are some accelerometers and gyros. They should be orthogonal each other but for construction constraints they can't really be.

Expensive IMUs come with a calibration matrix which is "personal" for each device, and here is why of the extra costs. So someone should calibrate it before use it.

IMUs are affected by many others things like magnetic fields as example. This is another reason for why you won't never read a zero value if the IMU is not moving.

All these error affect the pose estimation since they read accelerations you have to perform a double integration of the value to reach a pose. Double integration of an error make it error^2 (for a simple constant error due to bad calibration).

I can suggest you to search the web for "pose estimation algorithm" as keywords or go to ROS that maybe have something ready for your IMU.