Paparazzi UAS  v5.2.2_stable-0-gd6b9f29
Paparazzi is a free software Unmanned Aircraft System.
 All Data Structures Files Functions Variables Typedefs Enumerations Enumerator Macros Modules Pages
ahrs_sim.c File Reference

Dummy plug to set the AHRS from the simple OCaml simulator. More...

#include "subsystems/ahrs.h"
#include "subsystems/ahrs/ahrs_sim.h"
#include "math/pprz_algebra_float.h"
#include "generated/airframe.h"
+ Include dependency graph for ahrs_sim.c:

Go to the source code of this file.

Functions

void update_ahrs_from_sim (void)
 
void ahrs_init (void)
 AHRS initialization. More...
 
void ahrs_align (void)
 Aligns the AHRS. More...
 
void ahrs_propagate (void)
 Propagation. More...
 

Variables

float sim_phi
 in radians More...
 
float sim_theta
 in radians More...
 
float sim_psi
 in radians More...
 
float sim_p
 in radians/s More...
 
float sim_q
 in radians/s More...
 
float sim_r
 in radians/s More...
 
bool_t ahrs_sim_available
 

Detailed Description

Dummy plug to set the AHRS from the simple OCaml simulator.

Definition in file ahrs_sim.c.

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 78 of file ahrs_sim.c.

References ahrs, AHRS_RUNNING, Ahrs::status, and update_ahrs_from_sim().

+ Here is the call graph for this function:

void ahrs_init ( void  )

AHRS initialization.

Called at startup. Needs to be implemented by each AHRS algorithm.

Definition at line 69 of file ahrs_sim.c.

References ahrs, AHRS_RUNNING, ahrs_sim_available, FALSE, and Ahrs::status.

void ahrs_propagate ( void  )

Propagation.

Usually integrates the gyro rates to angles. Reads the global imu data struct. Does nothing if not implemented by specific AHRS algorithm.

Definition at line 90 of file ahrs_sim.c.

References ahrs_sim_available, FALSE, and update_ahrs_from_sim().

+ Here is the call graph for this function:

void update_ahrs_from_sim ( void  )

Definition at line 54 of file ahrs_sim.c.

References ins_pitch_neutral, ins_roll_neutral, FloatEulers::phi, sim_p, sim_phi, sim_psi, sim_q, sim_r, sim_theta, stateSetBodyRates_f(), stateSetNedToBodyEulers_f(), and FloatEulers::theta.

Referenced by ahrs_align(), and ahrs_propagate().

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

Variable Documentation

bool_t ahrs_sim_available

Definition at line 17 of file jsbsim_ahrs.c.

Referenced by ahrs_init(), and ahrs_propagate().

float sim_p

in radians/s

Definition at line 14 of file jsbsim_ahrs.c.

Referenced by provide_attitude_and_rates(), provide_rates(), and update_ahrs_from_sim().

float sim_phi

in radians

Definition at line 11 of file jsbsim_ahrs.c.

Referenced by provide_attitude(), provide_attitude_and_rates(), and update_ahrs_from_sim().

float sim_psi

in radians

Definition at line 13 of file jsbsim_ahrs.c.

Referenced by provide_attitude(), provide_attitude_and_rates(), and update_ahrs_from_sim().

float sim_q

in radians/s

Definition at line 15 of file jsbsim_ahrs.c.

Referenced by provide_attitude_and_rates(), provide_rates(), and update_ahrs_from_sim().

float sim_r

in radians/s

Definition at line 16 of file jsbsim_ahrs.c.

Referenced by provide_attitude_and_rates(), provide_rates(), and update_ahrs_from_sim().

float sim_theta

in radians

Definition at line 12 of file jsbsim_ahrs.c.

Referenced by provide_attitude(), provide_attitude_and_rates(), and update_ahrs_from_sim().