|
Paparazzi UAS v7.1_unstable
Paparazzi is a free software Unmanned Aircraft System.
|
#include "modules/sensors/sensors_hitl.h"#include "modules/imu/imu.h"#include "modules/gps/gps.h"#include "modules/core/abi.h"#include "mcu_periph/sys_time.h"#include "modules/energy/electrical.h"#include "generated/airframe.h"#include "modules/datalink/datalink.h"#include "modules/datalink/telemetry.h"#include "nps_sensors_params_common.h"Go to the source code of this file.
Data Structures | |
| struct | ImuHitl |
Functions | |
| void | sensors_hitl_init (void) |
| void | sensors_hitl_periodic (void) |
| void | sensors_hitl_parse_HITL_IMU (uint8_t *buf) |
| void | sensors_hitl_parse_HITL_GPS (uint8_t *buf) |
| void | sensors_hitl_parse_HITL_AIR_DATA (uint8_t *buf) |
| void | sensors_hitl_event (void) |
| void | imu_feed_gyro_accel (void) |
| void | imu_feed_mag (void) |
| void | gps_feed_value (void) |
Variables | |
| struct ImuHitl | imu_hitl |
| struct GpsState | gps_hitl = {0} |
| bool | gps_has_fix |
| static bool | sensors_hitl_msg_available = false |
| static uint8_t | sensors_hitl_dl_buffer [DATALINK_MSG_SIZE] |
| static struct pprz_transport | sensors_hitl_tp |
| struct ImuHitl |
Definition at line 35 of file sensors_hitl.c.
| Data Fields | ||
|---|---|---|
| struct Int32Vect3 | accel | |
| uint8_t | accel_available | |
| struct Int32Rates | gyro | |
| uint8_t | gyro_available | |
| struct Int32Vect3 | mag | |
| uint8_t | mag_available | |
| void gps_feed_value | ( | void | ) |
Definition at line 224 of file sensors_hitl.c.
| void imu_feed_gyro_accel | ( | void | ) |
Definition at line 222 of file sensors_hitl.c.
| void imu_feed_mag | ( | void | ) |
Definition at line 223 of file sensors_hitl.c.
| void sensors_hitl_event | ( | void | ) |
Definition at line 201 of file sensors_hitl.c.
References DlCheckAndParse(), get_sys_time_usec(), imu_hitl, IMU_NPS_ID, sensors_hitl_dl_buffer, sensors_hitl_msg_available, and sensors_hitl_tp.
| void sensors_hitl_init | ( | void | ) |
Definition at line 53 of file sensors_hitl.c.
References ACCEL_FLOAT_OF_BFP, gps_has_fix, imu_hitl, IMU_NPS_ID, imu_set_defaults_accel(), imu_set_defaults_gyro(), imu_set_defaults_mag(), MAG_FLOAT_OF_BFP, RATE_FLOAT_OF_BFP, and sensors_hitl_tp.
| void sensors_hitl_parse_HITL_AIR_DATA | ( | uint8_t * | buf | ) |
Definition at line 178 of file sensors_hitl.c.
References AIRSPEED_NPS_ID, BARO_SIM_SENDER_ID, get_sys_time_usec(), and INCIDENCE_NPS_ID.
| void sensors_hitl_parse_HITL_GPS | ( | uint8_t * | buf | ) |
Definition at line 111 of file sensors_hitl.c.
References get_sys_time_usec(), GPS_FIX_3D, GPS_FIX_NONE, gps_has_fix, gps_hitl, GPS_SIM_ID, GPS_VALID_COURSE_BIT, GPS_VALID_HMSL_BIT, GPS_VALID_POS_LLA_BIT, GPS_VALID_VEL_ECEF_BIT, GPS_VALID_VEL_NED_BIT, ltp_def_from_lla_i(), sys_time::nb_sec, sys_time::nb_sec_rem, ned_of_ecef_vect_i(), VECT3_FLOAT_OF_CM, NedCoor_f::x, NedCoor_i::x, NedCoor_f::y, NedCoor_i::y, NedCoor_f::z, and NedCoor_i::z.
| void sensors_hitl_parse_HITL_IMU | ( | uint8_t * | buf | ) |
Definition at line 87 of file sensors_hitl.c.
References imu_hitl, RATES_ASSIGN, and VECT3_ASSIGN.
| void sensors_hitl_periodic | ( | void | ) |
Definition at line 76 of file sensors_hitl.c.
References electrical.
| bool gps_has_fix |
Definition at line 47 of file sensors_hitl.c.
| struct GpsState gps_hitl = {0} |
Definition at line 46 of file sensors_hitl.c.
Referenced by sensors_hitl_parse_HITL_GPS().
| struct ImuHitl imu_hitl |
Definition at line 45 of file sensors_hitl.c.
Referenced by sensors_hitl_event(), sensors_hitl_init(), and sensors_hitl_parse_HITL_IMU().
|
static |
Definition at line 50 of file sensors_hitl.c.
Referenced by sensors_hitl_event().
|
static |
Definition at line 49 of file sensors_hitl.c.
Referenced by sensors_hitl_event().
|
static |
Definition at line 51 of file sensors_hitl.c.
Referenced by sensors_hitl_event(), and sensors_hitl_init().