Implementation of the EKF-based AHRS algorithm based on measurements from three-component accelerometer with orthogonal axes, vector magnetometer and three-axis gyroscope. Estimates the current quaternion attitude.

1 | ```
ahrs.EKF.QUATERNION(Filter, Sensors, Parameters)
``` |

`Filter` |
data structure for Extended Kalman Filter |

`Sensors` |
calibrated gyroscope, accelerometer and magnetometer measurements Sensors.w current calibrated gyroscope measurement [3x1], rad/sec Sensors.a current calibrated accelerometer measurement [3x1], g Sensors.m current calibrated magnetometer measurement [3x1], |m| = 1 |

`Parameters` |
AHRS Parameters Parameters.mn Magnetic Field Vector In Navigation Frame [3x1], |m|= 1 Parameters.an Acceleration vector In Navigation Frame [3x1], g Parameters.dt Sampling period, 1/Hz |

Q estimated attitude quaternion [1x4] Filter data structure for an Extended Kalman Filter dw estimated gyroscopes bias [1x3]

Jose Gama

Vlad Maximov, 2012 Scalar Calibration of Vector accelerometers and magnetometers, GyroLib documentation

Questions? Problems? Suggestions? Tweet to @rdrrHQ or email at ian@mutexlabs.com.

All documentation is copyright its authors; we didn't write any of that.