EFR32 Mighty Gecko 1 Software Documentation  efr32mg1-doc-5.1.2

Detailed Description

Macro definitions used by the IMU driver.

Macros

#define IMU_DEG_TO_RAD(ang)    (ang * IMU_DEG_TO_RAD_FACTOR)
 
#define IMU_DEG_TO_RAD_FACTOR   ( (2.0*IMU_PI) / 360.0 )
 
#define IMU_MAX_ACCEL_FOR_ANGLE   0.9848
 
#define IMU_PI   3.14159265358979323
 
#define IMU_RAD_TO_DEG(ang)    (ang * IMU_RAD_TO_DEG_FACTOR)
 
#define IMU_RAD_TO_DEG_FACTOR   ( 360.0 / (2.0*IMU_PI) )
 
#define IMU_STATE_CALIBRATING   0x03
 
#define IMU_STATE_DISABLED   0x00
 
#define IMU_STATE_INITIALIZING   0x02
 
#define IMU_STATE_READY   0x01
 

Macro Definition Documentation

#define IMU_DEG_TO_RAD (   ang)    (ang * IMU_DEG_TO_RAD_FACTOR)

Degrees to radians converter macro

Definition at line 52 of file imu.h.

#define IMU_DEG_TO_RAD_FACTOR   ( (2.0*IMU_PI) / 360.0 )

Degrees to radians conversion factor

Definition at line 50 of file imu.h.

Referenced by IMU_fuseGyroSetSampleRate().

#define IMU_MAX_ACCEL_FOR_ANGLE   0.9848

Maximum acceleration value for a given angle

Definition at line 55 of file imu.h.

#define IMU_PI   3.14159265358979323

The value of the Pi

Definition at line 49 of file imu.h.

Referenced by IMU_fuseGyroCorrection(), and IMU_normalizeAngle().

#define IMU_RAD_TO_DEG (   ang)    (ang * IMU_RAD_TO_DEG_FACTOR)

Radians to degrees converter macro

Definition at line 53 of file imu.h.

#define IMU_RAD_TO_DEG_FACTOR   ( 360.0 / (2.0*IMU_PI) )

Radians to degrees conversion factor

Definition at line 51 of file imu.h.

Referenced by IMU_orientationGet().

#define IMU_STATE_CALIBRATING   0x03

The IMU is being calibrated

Definition at line 60 of file imu.h.

Referenced by IMU_init().

#define IMU_STATE_DISABLED   0x00

The IMU is disabled

Definition at line 57 of file imu.h.

Referenced by IMU_deInit(), and IMU_init().

#define IMU_STATE_INITIALIZING   0x02

The IMU is being initialized

Definition at line 59 of file imu.h.

Referenced by IMU_config(), and IMU_init().

#define IMU_STATE_READY   0x01

The IMU is fully configured and ready to take measurements

Definition at line 58 of file imu.h.

Referenced by IMU_config(), IMU_fuseUpdate(), IMU_getAccelerometerData(), IMU_getGyroData(), IMU_isDataReady(), and IMU_isDataReadyFlag().