Hivemapper/odc-api

[Spike] Accelerometer calibration

Closed this issue · 2 comments

Extend the imu-controller with accelerometer calibration.

Accelerometer calibration is similar to gyro calibration. Take an average over many readings and use this average value as an offset (i.e. subtract this value from future readings).

This is a quick and dirty solution. It can only calibrate to a single orientation, and cannot fix scale issues.

In practice we may need to reapply calibration over time to maintain accurate readings.

Also working on an imu-calibration command line utility. This uses the imu-controller library to calibrate the device. It has flags for choosing which sensor (gyro, accel) to configure, and can either calibrate or clear calibration.

looks like its working now, wrapping up into PR

PR is ready for review, @punov