Paparazzi UAS  v5.18.0_stable
Paparazzi is a free software Unmanned Aircraft System.
ahrs_float_mlkf.h File Reference
#include "std.h"
#include "math/pprz_algebra_float.h"
#include "math/pprz_orientation_conversion.h"
+ Include dependency graph for ahrs_float_mlkf.h:
+ This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Data Structures

struct  AhrsMlkf
 

Enumerations

enum  AhrsMlkfStatus { AHRS_MLKF_UNINIT, AHRS_MLKF_RUNNING }
 

Functions

void ahrs_mlkf_init (void)
 
void ahrs_mlkf_set_body_to_imu (struct OrientationReps *body_to_imu)
 
void ahrs_mlkf_set_body_to_imu_quat (struct FloatQuat *q_b2i)
 
bool ahrs_mlkf_align (struct FloatRates *lp_gyro, struct FloatVect3 *lp_accel, struct FloatVect3 *lp_mag)
 
void ahrs_mlkf_propagate (struct FloatRates *gyro, float dt)
 
void ahrs_mlkf_update_accel (struct FloatVect3 *accel)
 
void ahrs_mlkf_update_mag (struct FloatVect3 *mag)
 
void ahrs_mlkf_update_mag_2d (struct FloatVect3 *mag)
 
void ahrs_mlkf_update_mag_full (struct FloatVect3 *mag)
 

Variables

struct AhrsMlkf ahrs_mlkf
 

Detailed Description

Multiplicative linearized Kalman Filter in quaternion formulation.

Estimate the attitude, heading and gyro bias.

Definition in file ahrs_float_mlkf.h.


Data Structure Documentation

◆ AhrsMlkf

struct AhrsMlkf

Definition at line 43 of file ahrs_float_mlkf.h.

+ Collaboration diagram for AhrsMlkf:
Data Fields
struct OrientationReps body_to_imu body_to_imu rotation
struct FloatQuat gibbs_cor
struct FloatRates gyro_bias
struct FloatRates imu_rate Rotational velocity in IMU frame.
bool is_aligned
float lp_accel
struct FloatQuat ltp_to_body_quat Rotation from LocalTangentPlane to body frame as unit quaternion.
struct FloatQuat ltp_to_imu_quat Rotation from LocalTangentPlane to IMU frame as unit quaternion.
struct FloatVect3 mag_h
struct FloatVect3 mag_noise
float P[6][6]
enum AhrsMlkfStatus status

Enumeration Type Documentation

◆ AhrsMlkfStatus

Enumerator
AHRS_MLKF_UNINIT 
AHRS_MLKF_RUNNING 

Definition at line 38 of file ahrs_float_mlkf.h.

Function Documentation

◆ ahrs_mlkf_align()

bool ahrs_mlkf_align ( struct FloatRates lp_gyro,
struct FloatVect3 lp_accel,
struct FloatVect3 lp_mag 
)

Definition at line 107 of file ahrs_float_mlkf.c.

References ahrs_float_get_quat_from_accel_mag(), ahrs_mlkf, AhrsMlkf::gyro_bias, AhrsMlkf::is_aligned, AhrsMlkf::lp_accel, and AhrsMlkf::ltp_to_imu_quat.

Referenced by aligner_cb().

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

◆ ahrs_mlkf_init()

void ahrs_mlkf_init ( void  )

◆ ahrs_mlkf_propagate()

void ahrs_mlkf_propagate ( struct FloatRates gyro,
float  dt 
)

Definition at line 122 of file ahrs_float_mlkf.c.

References propagate_ref(), and propagate_state().

Referenced by gyro_cb().

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

◆ ahrs_mlkf_set_body_to_imu()

void ahrs_mlkf_set_body_to_imu ( struct OrientationReps body_to_imu)

Definition at line 91 of file ahrs_float_mlkf.c.

References ahrs_mlkf_set_body_to_imu_quat(), body_to_imu, and orientationGetQuat_f().

+ Here is the call graph for this function:

◆ ahrs_mlkf_set_body_to_imu_quat()

void ahrs_mlkf_set_body_to_imu_quat ( struct FloatQuat q_b2i)

Definition at line 96 of file ahrs_float_mlkf.c.

References ahrs_mlkf, AhrsMlkf::body_to_imu, AhrsMlkf::is_aligned, AhrsMlkf::ltp_to_imu_quat, orientationGetQuat_f(), and orientationSetQuat_f().

Referenced by ahrs_mlkf_set_body_to_imu(), and body_to_imu_cb().

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

◆ ahrs_mlkf_update_accel()

void ahrs_mlkf_update_accel ( struct FloatVect3 accel)

Definition at line 128 of file ahrs_float_mlkf.c.

References ahrs_mlkf, alpha, dn, float_vect3_norm(), AhrsMlkf::lp_accel, reset_state(), and update_state().

Referenced by accel_cb().

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

◆ ahrs_mlkf_update_mag()

void ahrs_mlkf_update_mag ( struct FloatVect3 mag)

Definition at line 141 of file ahrs_float_mlkf.c.

References ahrs_mlkf_update_mag_2d(), and ahrs_mlkf_update_mag_full().

Referenced by mag_cb().

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

◆ ahrs_mlkf_update_mag_2d()

void ahrs_mlkf_update_mag_2d ( struct FloatVect3 mag)

Definition at line 150 of file ahrs_float_mlkf.c.

References ahrs_mlkf, AhrsMlkf::mag_h, AhrsMlkf::mag_noise, reset_state(), and update_state_heading().

Referenced by ahrs_mlkf_update_mag().

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

◆ ahrs_mlkf_update_mag_full()

void ahrs_mlkf_update_mag_full ( struct FloatVect3 mag)

Definition at line 156 of file ahrs_float_mlkf.c.

References ahrs_mlkf, AhrsMlkf::mag_h, AhrsMlkf::mag_noise, reset_state(), and update_state().

Referenced by ahrs_mlkf_update_mag().

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

Variable Documentation

◆ ahrs_mlkf