Paparazzi UAS v7.1_unstable
Paparazzi is a free software Unmanned Aircraft System.
Loading...
Searching...
No Matches
ahrs_madgwick.h File Reference

AHRS using Madgwick implementation. More...

Include dependency graph for ahrs_madgwick.h:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Data Structures

struct  AhrsMadgwick
 Madgwick filter structure. More...

Functions

void ahrs_madgwick_init (void)
void ahrs_madgwick_align (struct FloatRates *lp_gyro, struct FloatVect3 *lp_accel)
void ahrs_madgwick_propagate (struct FloatRates *gyro, float dt)
void ahrs_madgwick_update_accel (struct FloatVect3 *accel)

Variables

struct AhrsMadgwick ahrs_madgwick

Detailed Description

AHRS using Madgwick implementation.

See: https://x-io.co.uk/open-source-imu-and-ahrs-algorithms/

Definition in file ahrs_madgwick.h.


Data Structure Documentation

◆ AhrsMadgwick

struct AhrsMadgwick

Madgwick filter structure.

Definition at line 38 of file ahrs_madgwick.h.

Collaboration diagram for AhrsMadgwick:
Data Fields
struct FloatVect3 accel Measured accelerometers.
struct FloatRates bias Gyro bias (from alignment).
bool is_aligned aligned flag
struct FloatQuat quat Estimated attitude (quaternion).
struct FloatRates rates Measured gyro rates.
bool reset flag to request reset/reinit the filter

Function Documentation

◆ ahrs_madgwick_align()

void ahrs_madgwick_align ( struct FloatRates * lp_gyro,
struct FloatVect3 * lp_accel )
extern

Definition at line 59 of file ahrs_madgwick.c.

References ahrs_float_get_quat_from_accel(), and ahrs_madgwick.

Referenced by aligner_cb().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ ahrs_madgwick_init()

void ahrs_madgwick_init ( void )
extern

Definition at line 50 of file ahrs_madgwick.c.

References ahrs_madgwick, and init_state().

Referenced by ahrs_madgwick_wrapper_init().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ ahrs_madgwick_propagate()

void ahrs_madgwick_propagate ( struct FloatRates * gyro,
float dt )
extern

Definition at line 69 of file ahrs_madgwick.c.

References ahrs_madgwick, AHRS_MADGWICK_BETA, float_quat_derivative(), float_quat_normalize(), float_vect3_norm(), init_state(), FloatQuat::qi, FloatQuat::qx, FloatQuat::qy, FloatQuat::qz, RATES_DIFF, VECT3_SDIV, FloatVect3::x, FloatVect3::y, and FloatVect3::z.

Referenced by gyro_cb().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ ahrs_madgwick_update_accel()

void ahrs_madgwick_update_accel ( struct FloatVect3 * accel)
extern

Definition at line 139 of file ahrs_madgwick.c.

References ahrs_madgwick.

Referenced by accel_cb().

Here is the caller graph for this function:

Variable Documentation

◆ ahrs_madgwick