|
Paparazzi UAS
v5.18.0_stable
Paparazzi is a free software Unmanned Aircraft System.
|
Go to the documentation of this file.
36 PRINT_CONFIG_VAR(IMU_B2_MAG_TYPE)
42 #if defined IMU_B2_MAG_TYPE && IMU_B2_MAG_TYPE == IMU_B2_MAG_MS2100
44 #elif defined IMU_B2_MAG_TYPE && IMU_B2_MAG_TYPE == IMU_B2_MAG_AMI601
46 #elif defined IMU_B2_MAG_TYPE && IMU_B2_MAG_TYPE == IMU_B2_MAG_HMC5843
48 #elif defined IMU_B2_MAG_TYPE && IMU_B2_MAG_TYPE == IMU_B2_MAG_HMC58XX
63 #if defined IMU_B2_MAG_TYPE && IMU_B2_MAG_TYPE == IMU_B2_MAG_MS2100
65 #elif defined IMU_B2_MAG_TYPE && IMU_B2_MAG_TYPE == IMU_B2_MAG_AMI601
67 #elif defined IMU_B2_MAG_TYPE && IMU_B2_MAG_TYPE == IMU_B2_MAG_HMC58XX
73 #if defined IMU_MAG_45_HACK
78 _imu->
mag.
x = msx - msy;
79 _imu->
mag.
y = msx + msy;
82 #elif defined IMU_B2_MAG_TYPE && IMU_B2_MAG_TYPE == IMU_B2_MAG_NONE
93 #if defined IMU_B2_MAG_TYPE && IMU_B2_MAG_TYPE == IMU_B2_MAG_MS2100
106 #elif defined IMU_B2_MAG_TYPE && IMU_B2_MAG_TYPE == IMU_B2_MAG_AMI601
107 static inline void foo_handler(
void) {}
120 #elif defined IMU_B2_MAG_TYPE && IMU_B2_MAG_TYPE == IMU_B2_MAG_HMC5843
121 static inline void foo_handler(
void) {}
134 #elif defined IMU_B2_MAG_TYPE && IMU_B2_MAG_TYPE == IMU_B2_MAG_HMC58XX
138 if (
imu_b2.mag_hmc.data_available) {
144 imu_b2.mag_hmc.data_available =
false;
148 #define ImuMagEvent() {}
struct Int32Rates gyro_unscaled
unscaled gyroscope measurements
void hmc5843_idle_task(void)
void hmc58xx_event(struct Hmc58xx *hmc)
uint16_t max1168_values[MAX1168_NB_CHAN]
struct Int32Vect3 accel
accelerometer measurements in m/s^2 in BFP with INT32_ACCEL_FRAC
#define IMU_MAG_Y_SENS_DEN
int32_t q
in rad/s with INT32_RATE_FRAC
uint16_t ami601_values[AMI601_NB_CHAN]
struct Int32Vect3 mag_neutral
magnetometer neutral readings (bias) in raw/unscaled units
#define IMU_MAG_Y_SENS_NUM
#define IMU_MAG_X_SENS_NUM
#define IMU_MAG_Z_SENS_DEN
struct Int32Vect3 accel_unscaled
unscaled accelerometer measurements
#define AMI601Event(_handler)
uint32_t get_sys_time_usec(void)
Get the time in microseconds since startup.
int32_t p
in rad/s with INT32_RATE_FRAC
abstract IMU interface providing fixed point interface
#define AMI601_DATA_AVAILABLE
#define Max1168Periodic()
volatile uint8_t max1168_status
Architecture independent timing functions.
void imu_scale_gyro(struct Imu *_imu)
#define MAX1168_DATA_AVAILABLE
#define IMU_MAG_X_SENS_DEN
volatile uint8_t ami601_status
static void hmc58xx_periodic(struct Hmc58xx *hmc)
convenience function: read or start configuration if not already initialized
arch independent LED (Light Emitting Diodes) API
#define IMU_MAG_Z_SENS_NUM
struct Imu imu
global IMU state
void hmc58xx_init(struct Hmc58xx *hmc, struct i2c_periph *i2c_p, uint8_t addr)
Initialize Hmc58xx struct and set default config options.
void imu_scale_mag(struct Imu *_imu)
struct Int32Vect3 mag
magnetometer measurements scaled to 1 in BFP with INT32_MAG_FRAC
struct Int32Vect3 mag_unscaled
unscaled magnetometer measurements
static void ms2100_periodic(struct Ms2100 *ms)
#define ImuMagEvent()
Event functions for imu_b2.
void ms2100_init(struct Ms2100 *ms, struct spi_periph *spi_p, uint8_t slave_idx)
void imu_b2_periodic(void)
int32_t r
in rad/s with INT32_RATE_FRAC
void imu_scale_accel(struct Imu *_imu)
void ms2100_event(struct Ms2100 *ms)
struct Int32Rates gyro
gyroscope measurements in rad/s in BFP with INT32_RATE_FRAC