Paparazzi UAS  v4.0.4_stable-3-gf39211a
Paparazzi is a free software Unmanned Aircraft System.
 All Data Structures Files Functions Variables Typedefs Enumerations Enumerator Macros Pages
ahrs_float_cmpl.c File Reference
+ Include dependency graph for ahrs_float_cmpl.c:

Go to the source code of this file.

Macros

#define AHRS_PROPAGATE_FREQUENCY   PERIODIC_FREQUENCY
 

Functions

void ahrs_update_mag_full (void)
 
void ahrs_update_mag_2d (void)
 
void ahrs_update_mag_2d_dumb (void)
 
static void compute_imu_quat_and_euler_from_rmat (void)
 Compute ltp to imu rotation in euler angles and quaternion representations from the rotation matrix representation. More...
 
static void compute_imu_rmat_and_euler_from_quat (void)
 
static void compute_body_orientation_and_rates (void)
 Compute body orientation and rates from imu orientation and rates. More...
 
void ahrs_init (void)
 AHRS initialization. More...
 
void ahrs_align (void)
 Aligns the AHRS. More...
 
void ahrs_propagate (void)
 Propagation. More...
 
void ahrs_update_accel (void)
 Update AHRS state with accerleration measurements. More...
 
void ahrs_update_mag (void)
 Update AHRS state with magnetometer measurements. More...
 
void ahrs_update_gps (void)
 
void ahrs_update_heading (float heading)
 Update yaw based on a heading measurement. More...
 
void ahrs_realign_heading (float heading)
 Hard reset yaw to a heading. More...
 

Variables

struct AhrsFloatCmplRmat ahrs_impl
 

Macro Definition Documentation

#define AHRS_PROPAGATE_FREQUENCY   PERIODIC_FREQUENCY

Definition at line 54 of file ahrs_float_cmpl.c.

Referenced by ahrs_propagate().

Function Documentation

void ahrs_align ( void  )

Aligns the AHRS.

Called after ahrs_aligner has run to set initial attitude and biases. Must set the ahrs status to AHRS_RUNNING. Needs to be implemented by each AHRS algorithm.

Definition at line 100 of file ahrs_float_cmpl.c.

Referenced by on_gyro_accel_event(), and on_gyro_event().

+ Here is the caller graph for this function:

void ahrs_propagate ( void  )

Propagation.

Usually integrates the gyro rates to angles. Reads the global imu data struct. Needs to be implemented by each AHRS algorithm.

Definition at line 131 of file ahrs_float_cmpl.c.

Referenced by on_gyro_accel_event(), and on_gyro_event().

+ Here is the caller graph for this function:

void ahrs_realign_heading ( float  heading)
void ahrs_update_accel ( void  )

Update AHRS state with accerleration measurements.

Reads the global imu data struct. Needs to be implemented by each AHRS algorithm.

Definition at line 170 of file ahrs_float_cmpl.c.

Referenced by on_accel_event(), and on_gyro_accel_event().

+ Here is the caller graph for this function:

void ahrs_update_gps ( void  )

Definition at line 310 of file ahrs_float_cmpl.c.

void ahrs_update_heading ( float  heading)

Update yaw based on a heading measurement.

e.g. from GPS course

Parameters
headingHeading in body frame, radians (CW/north)

Definition at line 342 of file ahrs_float_cmpl.c.

References ahrs_float, ahrs_impl, FLOAT_ANGLE_NORMALIZE, FLOAT_RATES_ADD_SCALED_VECT, FLOAT_RMAT_VECT3_MUL, AhrsFloatCmplRmat::gyro_bias, AhrsFloat::ltp_to_body_rmat, AhrsFloat::ltp_to_imu_rmat, AhrsFloatCmplRmat::rate_correction, RMAT_ELMT, FloatVect2::x, FloatVect2::y, and FloatVect3::z.

Referenced by ahrs_update_gps().

+ Here is the caller graph for this function:

void ahrs_update_mag ( void  )

Update AHRS state with magnetometer measurements.

Reads the global imu data struct. Needs to be implemented by each AHRS algorithm.

Definition at line 228 of file ahrs_float_cmpl.c.

Referenced by on_mag_event().

+ Here is the caller graph for this function:

static void ahrs_update_mag_full ( void  )
inline
static void compute_body_orientation_and_rates ( void  )
inlinestatic
static void compute_imu_quat_and_euler_from_rmat ( void  )
inlinestatic

Compute ltp to imu rotation in euler angles and quaternion representations from the rotation matrix representation.

Definition at line 428 of file ahrs_float_cmpl.c.

References ahrs_float, FLOAT_EULERS_OF_RMAT, FLOAT_QUAT_OF_RMAT, AhrsFloat::ltp_to_imu_euler, AhrsFloat::ltp_to_imu_quat, and AhrsFloat::ltp_to_imu_rmat.

Referenced by ahrs_propagate().

+ Here is the caller graph for this function:

static void compute_imu_rmat_and_euler_from_quat ( void  )
inlinestatic

Variable Documentation