Definition
IMU
An IMU, or inertial measurement unit, is a small sensor that measures acceleration and rotation to track how something moves and which way it faces.
- An IMU combines an accelerometer and a gyroscope, and sometimes a magnetometer.
- The accelerometer feels gravity, so it can tell which way is down.
- Integrating the gyroscope drifts over time, so an IMU is usually combined with other sensors.
An IMU (inertial measurement unit) is a chip that measures how a device is moving. It holds an accelerometer, which measures acceleration, and a gyroscope, which measures how fast the device is rotating. Many also include a magnetometer, which senses the magnetic field and so gives a compass heading.
Example: a phone knowing which way is up
Lay a phone flat and still. Gravity pulls on the accelerometer's tiny internal mass just as it would on anything, so the sensor reports about 9.8 m/s² along the axis pointing up through the screen, and about 0 along the other two.
Now tilt the phone by 30° around one edge. The reading splits between two axes. Along the screen's normal it is 9.8 × cos 30° ≈ 9.8 × 0.866 ≈ 8.5 m/s², and along the tilted direction it is 9.8 × sin 30° = 9.8 × 0.5 = 4.9 m/s². The phone can recover the angle from the ratio: sin 30° ÷ cos 30° = tan 30° ≈ 0.577, and 4.9 ÷ 8.5 ≈ 0.577.
That is how it knows which way is down while still, and so how it knows to rotate the screen.
Why it matters, and the catch
The accelerometer is noisy when the device is shaken, so a gyroscope fills in. The gyroscope gives a smooth rate of turn, but to get an angle you add up (integrate) the rate over time, and any small constant error adds up with it. This is drift. For instance, a hypothetical bias of 0.1° per second would give 0.1 × 60 = 6° of error after one minute.
To handle this, systems combine an IMU with other measurements, as in SLAM or a PID controller that keeps a robot upright. See how an IMU knows which way is down for more.
Related terms
Further reading
Reviewed . Next review .
Owner: DuckyHelper