IT lexicon › Hardware › Sensor fusion

Sensor fusion

Hardware På svenska → Updated: 2026-11-04

Combining several bad sensors into an estimate that beats any one of them on its own.

The textbook case is orientation. A gyroscope is fast and smooth but drifts over time. An accelerometer knows which way is down but is thrown off by every bump. A magnetometer knows where north is, right up until someone puts a speaker next to it. None of them is usable alone, but their errors differ, and that's the whole trick.

The simplest recipe is a complementary filter: trust the gyro in the short term and the accelerometer in the long term. A Kalman filter does the same thing with proper statistics, at the price of matrix maths that a small microcontroller will struggle with. Madgwick's filter from 2010 caught on because it was cheap enough for 8-bit parts. These days the fusion often runs inside the sensor itself, and the microcontroller just reads a finished quaternion over I²C.

← Back to the lexicon