Accelerometer
Accelerometer
What does it measure?
An accelerometer measures specific force along its three axes, in units of or multiples of ().
A useful model in the sensor/body frame is:
where rotates body coordinates into world coordinates. At rest, the accelerometer still registers approximately 1 g in magnitude because it senses the supporting force opposing gravity. The measured sign depends on the axis orientation.
Estimating roll and pitch
For the common body-axis convention in which a level, stationary sensor reads approximately :
Here denotes roll and pitch. Results are in radians unless converted. These formulas depend on the coordinate/sign convention and assume that non-gravitational linear acceleration is small.
What goes wrong?
| Issue | Why it matters |
|---|---|
| Linear acceleration | Acceleration from a vehicle, robot, or human motion is mixed with the gravity signal, causing false tilt |
| Vibration | High-frequency oscillations make readings noisy and can alias into the sampled signal |
| Bias / zero-g offset | Adds systematic error to measured acceleration and tilt |
| Scale-factor / axis misalignment | Changes magnitude and direction of the measured vector |
| Temperature changes | Bias and sensitivity can vary with temperature |
| Saturation | Accelerations beyond the selected ±g range are clipped |
| Integration | Estimating velocity/position requires integration, magnifying small bias and gravity-removal errors |
Why not use acceleration alone for position?
For a constant acceleration error , the approximate position error from double integration is:
A constant error therefore becomes about 5 m of position error after 10 s, even before considering attitude error. Reliable inertial navigation typically needs more information (e.g. GNSS, vision, wheel odometry, or motion constraints).
Calibration basics
- Check units and axis orientation. At rest, the magnitude should be near , not zero.
- Collect several static orientations (commonly aligned with gravity).
- Use known values to estimate each axis' offset and scale factor; more advanced routines fit cross-axis misalignment as well.
- Repeat or model calibration over temperature if accuracy requirements justify it.
- Apply corrections before passing accelerometer readings to sensor fusion.
For example, with one axis held at and then , the raw mean measurements and give an approximate bias ; their difference gives scale information.
Handling bad gravity measurements
- Apply appropriate low-pass/anti-alias filtering and sample at a suitable rate.
- Down-weight accelerometer tilt updates during likely linear acceleration or high vibration.
- Use as a sanity check, but remember that matching the magnitude of does not prove there is no linear acceleration.
- Record the timing of the accelerometer sample relative to the gyro sample.
Relation to the gyroscope
The accelerometer offers a long-term gravity reference for roll/pitch but is unreliable as a tilt sensor during certain motions. The Gyroscope accurately captures brief rotations but drifts if integrated indefinitely. Their strengths motivate a Complementary Filter or Kalman Filter for IMUs.
See also: 6-DoF IMU · BMI088 - Hardware Connection