![]() |
LibDriver MPU9250
1.0.0
MPU9250 full function driver
|
mpu9250 dmp driver modules More...
Macros | |
| #define | MPU9250_DMP_CODE_SIZE 3062 |
| mpu9250 dmp code definition More... | |
Functions | |
| uint8_t | mpu9250_dmp_load_firmware (mpu9250_handle_t *handle) |
| load the dmp firmware More... | |
| uint8_t | mpu9250_dmp_set_pedometer_walk_time (mpu9250_handle_t *handle, uint32_t ms) |
| dmp set the pedometer walk time More... | |
| uint8_t | mpu9250_dmp_get_pedometer_walk_time (mpu9250_handle_t *handle, uint32_t *ms) |
| dmp get the pedometer walk time More... | |
| uint8_t | mpu9250_dmp_set_pedometer_step_count (mpu9250_handle_t *handle, uint32_t count) |
| dmp set the pedometer step count More... | |
| uint8_t | mpu9250_dmp_get_pedometer_step_count (mpu9250_handle_t *handle, uint32_t *count) |
| dmp get the pedometer step count More... | |
| uint8_t | mpu9250_dmp_set_shake_reject_timeout (mpu9250_handle_t *handle, uint16_t ms) |
| dmp set the shake reject timeout More... | |
| uint8_t | mpu9250_dmp_get_shake_reject_timeout (mpu9250_handle_t *handle, uint16_t *ms) |
| dmp get the shake reject timeout More... | |
| uint8_t | mpu9250_dmp_set_shake_reject_time (mpu9250_handle_t *handle, uint16_t ms) |
| dmp set the shake reject time More... | |
| uint8_t | mpu9250_dmp_get_shake_reject_time (mpu9250_handle_t *handle, uint16_t *ms) |
| dmp get the shake reject time More... | |
| uint8_t | mpu9250_dmp_set_shake_reject_thresh (mpu9250_handle_t *handle, uint16_t dps) |
| dmp set the shake reject thresh More... | |
| uint8_t | mpu9250_dmp_get_shake_reject_thresh (mpu9250_handle_t *handle, uint16_t *dps) |
| dmp get the shake reject thresh More... | |
| uint8_t | mpu9250_dmp_set_tap_time_multi (mpu9250_handle_t *handle, uint16_t ms) |
| dmp set max time between taps to register as a multi tap More... | |
| uint8_t | mpu9250_dmp_get_tap_time_multi (mpu9250_handle_t *handle, uint16_t *ms) |
| dmp get max time between taps to register as a multi tap More... | |
| uint8_t | mpu9250_dmp_set_tap_time (mpu9250_handle_t *handle, uint16_t ms) |
| dmp set the tap time More... | |
| uint8_t | mpu9250_dmp_get_tap_time (mpu9250_handle_t *handle, uint16_t *ms) |
| dmp get the tap time More... | |
| uint8_t | mpu9250_dmp_set_min_tap_count (mpu9250_handle_t *handle, uint8_t cnt) |
| dmp set the min tap count More... | |
| uint8_t | mpu9250_dmp_get_min_tap_count (mpu9250_handle_t *handle, uint8_t *cnt) |
| dmp get the min tap count More... | |
| uint8_t | mpu9250_dmp_set_gyro_calibrate (mpu9250_handle_t *handle, mpu9250_bool_t enable) |
| dmp enable or disable gyro calibrate More... | |
| uint8_t | mpu9250_dmp_set_3x_quaternion (mpu9250_handle_t *handle, mpu9250_bool_t enable) |
| dmp enable or disable generate 3 axis quaternions from dmp More... | |
| uint8_t | mpu9250_dmp_set_6x_quaternion (mpu9250_handle_t *handle, mpu9250_bool_t enable) |
| dmp enable or disable generate 6 axis quaternions from dmp More... | |
| uint8_t | mpu9250_dmp_set_interrupt_mode (mpu9250_handle_t *handle, mpu9250_dmp_interrupt_mode_t mode) |
| dmp set the interrupt mode More... | |
| uint8_t | mpu9250_dmp_set_gyro_bias (mpu9250_handle_t *handle, int32_t bias[3]) |
| dmp set the gyro bias More... | |
| uint8_t | mpu9250_dmp_set_accel_bias (mpu9250_handle_t *handle, int32_t bias[3]) |
| dmp set the accel bias More... | |
| uint8_t | mpu9250_dmp_set_orientation (mpu9250_handle_t *handle, int8_t mat[9]) |
| dmp set the orientation More... | |
| uint8_t | mpu9250_dmp_set_feature (mpu9250_handle_t *handle, uint16_t mask) |
| dmp enable or disable the dmp feature More... | |
| uint8_t | mpu9250_dmp_set_fifo_rate (mpu9250_handle_t *handle, uint16_t rate) |
| dmp set the fifo rate More... | |
| uint8_t | mpu9250_dmp_get_fifo_rate (mpu9250_handle_t *handle, uint16_t *rate) |
| dmp get the fifo rate More... | |
| uint8_t | mpu9250_dmp_set_tap_axes (mpu9250_handle_t *handle, mpu9250_axis_t axis, mpu9250_bool_t enable) |
| dmp enable or disable the tap axes More... | |
| uint8_t | mpu9250_dmp_get_tap_axes (mpu9250_handle_t *handle, mpu9250_axis_t axis, mpu9250_bool_t *enable) |
| dmp get the tap axes status More... | |
| uint8_t | mpu9250_dmp_set_tap_thresh (mpu9250_handle_t *handle, mpu9250_axis_t axis, uint16_t mg_ms) |
| dmp set the tap thresh More... | |
| uint8_t | mpu9250_dmp_get_tap_thresh (mpu9250_handle_t *handle, mpu9250_axis_t axis, uint16_t *mg_ms) |
| dmp get the tap thresh More... | |
| uint8_t | mpu9250_dmp_read (mpu9250_handle_t *handle, int16_t(*accel_raw)[3], float(*accel_g)[3], int16_t(*gyro_raw)[3], float(*gyro_dps)[3], int32_t(*quat)[4], float *pitch, float *roll, float *yaw, uint16_t *l) |
| dmp read the data More... | |
| uint8_t | mpu9250_dmp_set_tap_callback (mpu9250_handle_t *handle, void(*callback)(uint8_t count, uint8_t direction)) |
| dmp set the tap callback More... | |
| uint8_t | mpu9250_dmp_set_orient_callback (mpu9250_handle_t *handle, void(*callback)(uint8_t orientation)) |
| dmp set the orient callback More... | |
| uint8_t | mpu9250_dmp_set_enable (mpu9250_handle_t *handle, mpu9250_bool_t enable) |
| enable or disable the dmp More... | |
| uint8_t | mpu9250_dmp_gyro_accel_raw_offset_convert (mpu9250_handle_t *handle, int32_t gyro_offset_raw[3], int32_t accel_offset_raw[3], int32_t gyro_offset[3], int32_t accel_offset[3]) |
| dmp gyro accel raw offset convert More... | |
mpu9250 dmp driver modules
| #define MPU9250_DMP_CODE_SIZE 3062 |
mpu9250 dmp feature enumeration definition
Definition at line 452 of file driver_mpu9250.h.
mpu9250 dmp interrupt mode enumeration definition
| Enumerator | |
|---|---|
| MPU9250_DMP_INTERRUPT_MODE_CONTINUOUS | continuous mode |
| MPU9250_DMP_INTERRUPT_MODE_GESTURE | gesture mode |
Definition at line 443 of file driver_mpu9250.h.
| enum mpu9250_dmp_orient_t |
mpu9250 dmp orient enumeration definition
| Enumerator | |
|---|---|
| MPU9250_DMP_ORIENT_PORTRAIT | portrait |
| MPU9250_DMP_ORIENT_LANDSCAPE | landscape |
| MPU9250_DMP_ORIENT_REVERSE_PORTRAIT | reverse portrait |
| MPU9250_DMP_ORIENT_REVERSE_LANDSCAPE | reverse landscape |
Definition at line 481 of file driver_mpu9250.h.
| enum mpu9250_dmp_tap_t |
mpu9250 dmp tap enumeration definition
Definition at line 468 of file driver_mpu9250.h.
| uint8_t mpu9250_dmp_get_fifo_rate | ( | mpu9250_handle_t * | handle, |
| uint16_t * | rate | ||
| ) |
dmp get the fifo rate
| [in] | *handle | points to an mpu9250 handle structure |
| [out] | *rate | points to a rate buffer |
Definition at line 3004 of file driver_mpu9250.c.
| uint8_t mpu9250_dmp_get_min_tap_count | ( | mpu9250_handle_t * | handle, |
| uint8_t * | cnt | ||
| ) |
dmp get the min tap count
| [in] | *handle | points to an mpu9250 handle structure |
| [out] | *cnt | points to a tap counter buffer |
Definition at line 1869 of file driver_mpu9250.c.
| uint8_t mpu9250_dmp_get_pedometer_step_count | ( | mpu9250_handle_t * | handle, |
| uint32_t * | count | ||
| ) |
dmp get the pedometer step count
| [in] | *handle | points to an mpu9250 handle structure |
| [out] | *count | points to a step count buffer |
Definition at line 1307 of file driver_mpu9250.c.
| uint8_t mpu9250_dmp_get_pedometer_walk_time | ( | mpu9250_handle_t * | handle, |
| uint32_t * | ms | ||
| ) |
dmp get the pedometer walk time
| [in] | *handle | points to an mpu9250 handle structure |
| [out] | *ms | points to a walk time buffer |
Definition at line 1214 of file driver_mpu9250.c.
| uint8_t mpu9250_dmp_get_shake_reject_thresh | ( | mpu9250_handle_t * | handle, |
| uint16_t * | dps | ||
| ) |
dmp get the shake reject thresh
| [in] | *handle | points to an mpu9250 handle structure |
| [out] | *dps | points to a shake reject thresh dps buffer |
Definition at line 1586 of file driver_mpu9250.c.
| uint8_t mpu9250_dmp_get_shake_reject_time | ( | mpu9250_handle_t * | handle, |
| uint16_t * | ms | ||
| ) |
dmp get the shake reject time
| [in] | *handle | points to an mpu9250 handle structure |
| [out] | *ms | points to a shake reject time buffer |
Definition at line 1491 of file driver_mpu9250.c.
| uint8_t mpu9250_dmp_get_shake_reject_timeout | ( | mpu9250_handle_t * | handle, |
| uint16_t * | ms | ||
| ) |
dmp get the shake reject timeout
| [in] | *handle | points to an mpu9250 handle structure |
| [out] | *ms | points to a reject timeout buffer |
Definition at line 1399 of file driver_mpu9250.c.
| uint8_t mpu9250_dmp_get_tap_axes | ( | mpu9250_handle_t * | handle, |
| mpu9250_axis_t | axis, | ||
| mpu9250_bool_t * | enable | ||
| ) |
dmp get the tap axes status
| [in] | *handle | points to an mpu9250 handle structure |
| [in] | axis | is the set axis |
| [out] | *enable | points to a bool value buffer |
Definition at line 3112 of file driver_mpu9250.c.
| uint8_t mpu9250_dmp_get_tap_thresh | ( | mpu9250_handle_t * | handle, |
| mpu9250_axis_t | axis, | ||
| uint16_t * | mg_ms | ||
| ) |
dmp get the tap thresh
| [in] | *handle | points to an mpu9250 handle structure |
| [in] | axis | is the set axis |
| [out] | *mg_ms | points to an mg/ms thresh buffer |
Definition at line 3313 of file driver_mpu9250.c.
| uint8_t mpu9250_dmp_get_tap_time | ( | mpu9250_handle_t * | handle, |
| uint16_t * | ms | ||
| ) |
dmp get the tap time
| [in] | *handle | points to an mpu9250 handle structure |
| [out] | *ms | points to a tap time buffer |
Definition at line 1773 of file driver_mpu9250.c.
| uint8_t mpu9250_dmp_get_tap_time_multi | ( | mpu9250_handle_t * | handle, |
| uint16_t * | ms | ||
| ) |
dmp get max time between taps to register as a multi tap
| [in] | *handle | points to an mpu9250 handle structure |
| [out] | *ms | points to a delay time buffer |
Definition at line 1681 of file driver_mpu9250.c.
| uint8_t mpu9250_dmp_gyro_accel_raw_offset_convert | ( | mpu9250_handle_t * | handle, |
| int32_t | gyro_offset_raw[3], | ||
| int32_t | accel_offset_raw[3], | ||
| int32_t | gyro_offset[3], | ||
| int32_t | accel_offset[3] | ||
| ) |
dmp gyro accel raw offset convert
| [in] | *handle | points to an mpu9250 handle structure |
| [in] | *gyro_offset_raw | points to a gyro offset raw buffer |
| [in] | *accel_offset_raw | points to an accel offset raw buffer |
| [out] | *gyro_offset | points to a gyro offset buffer |
| [out] | *accel_offset | points to an accel offset buffer |
Definition at line 3822 of file driver_mpu9250.c.
| uint8_t mpu9250_dmp_load_firmware | ( | mpu9250_handle_t * | handle | ) |
load the dmp firmware
| [in] | *handle | points to an mpu9250 handle structure |
Definition at line 1087 of file driver_mpu9250.c.
| uint8_t mpu9250_dmp_read | ( | mpu9250_handle_t * | handle, |
| int16_t(*) | accel_raw[3], | ||
| float(*) | accel_g[3], | ||
| int16_t(*) | gyro_raw[3], | ||
| float(*) | gyro_dps[3], | ||
| int32_t(*) | quat[4], | ||
| float * | pitch, | ||
| float * | roll, | ||
| float * | yaw, | ||
| uint16_t * | l | ||
| ) |
dmp read the data
| [in] | *handle | points to an mpu9250 handle structure |
| [out] | *accel_raw | points to an accel raw buffer |
| [out] | *accel_g | points to an accel g buffer |
| [out] | *gyro_raw | points to a gyro raw buffer |
| [out] | *gyro_dps | points to a gyro dps buffer |
| [out] | *quat | points to a quat buffer |
| [out] | *pitch | points to a pitch buffer |
| [out] | *roll | points to a roll buffer |
| [out] | *yaw | points to a yaw buffer |
| [in,out] | *l | points to a length buffer |
Definition at line 3429 of file driver_mpu9250.c.
| uint8_t mpu9250_dmp_set_3x_quaternion | ( | mpu9250_handle_t * | handle, |
| mpu9250_bool_t | enable | ||
| ) |
dmp enable or disable generate 3 axis quaternions from dmp
| [in] | *handle | points to an mpu9250 handle structure |
| [in] | enable | is a bool value |
Definition at line 1976 of file driver_mpu9250.c.
| uint8_t mpu9250_dmp_set_6x_quaternion | ( | mpu9250_handle_t * | handle, |
| mpu9250_bool_t | enable | ||
| ) |
dmp enable or disable generate 6 axis quaternions from dmp
| [in] | *handle | points to an mpu9250 handle structure |
| [in] | enable | is a bool value |
Definition at line 2053 of file driver_mpu9250.c.
| uint8_t mpu9250_dmp_set_accel_bias | ( | mpu9250_handle_t * | handle, |
| int32_t | bias[3] | ||
| ) |
dmp set the accel bias
| [in] | *handle | points to an mpu9250 handle structure |
| [in] | *bias | points to a bias buffer |
Definition at line 2289 of file driver_mpu9250.c.
| uint8_t mpu9250_dmp_set_enable | ( | mpu9250_handle_t * | handle, |
| mpu9250_bool_t | enable | ||
| ) |
enable or disable the dmp
| [in] | *handle | points to an mpu9250 handle structure |
| [in] | enable | is a bool value |
Definition at line 3767 of file driver_mpu9250.c.
| uint8_t mpu9250_dmp_set_feature | ( | mpu9250_handle_t * | handle, |
| uint16_t | mask | ||
| ) |
dmp enable or disable the dmp feature
| [in] | *handle | points to an mpu9250 handle structure |
| [in] | mask | is the set mask |
Definition at line 2496 of file driver_mpu9250.c.
| uint8_t mpu9250_dmp_set_fifo_rate | ( | mpu9250_handle_t * | handle, |
| uint16_t | rate | ||
| ) |
dmp set the fifo rate
| [in] | *handle | points to an mpu9250 handle structure |
| [in] | rate | is the set rate |
Definition at line 2938 of file driver_mpu9250.c.
| uint8_t mpu9250_dmp_set_gyro_bias | ( | mpu9250_handle_t * | handle, |
| int32_t | bias[3] | ||
| ) |
dmp set the gyro bias
| [in] | *handle | points to an mpu9250 handle structure |
| [in] | *bias | points to a bias buffer |
Definition at line 2199 of file driver_mpu9250.c.
| uint8_t mpu9250_dmp_set_gyro_calibrate | ( | mpu9250_handle_t * | handle, |
| mpu9250_bool_t | enable | ||
| ) |
dmp enable or disable gyro calibrate
| [in] | *handle | points to an mpu9250 handle structure |
| [in] | enable | is a bool value |
Definition at line 1913 of file driver_mpu9250.c.
| uint8_t mpu9250_dmp_set_interrupt_mode | ( | mpu9250_handle_t * | handle, |
| mpu9250_dmp_interrupt_mode_t | mode | ||
| ) |
dmp set the interrupt mode
| [in] | *handle | points to an mpu9250 handle structure |
| [in] | mode | is the dmp interrupt mode |
Definition at line 2130 of file driver_mpu9250.c.
| uint8_t mpu9250_dmp_set_min_tap_count | ( | mpu9250_handle_t * | handle, |
| uint8_t | cnt | ||
| ) |
dmp set the min tap count
| [in] | *handle | points to an mpu9250 handle structure |
| [in] | cnt | is the tap counter |
Definition at line 1819 of file driver_mpu9250.c.
| uint8_t mpu9250_dmp_set_orient_callback | ( | mpu9250_handle_t * | handle, |
| void(*)(uint8_t orientation) | callback | ||
| ) |
dmp set the orient callback
| [in] | *handle | points to an mpu9250 handle structure |
| [in] | *callback | points to a callback function address |
Definition at line 3733 of file driver_mpu9250.c.
| uint8_t mpu9250_dmp_set_orientation | ( | mpu9250_handle_t * | handle, |
| int8_t | mat[9] | ||
| ) |
dmp set the orientation
| [in] | *handle | points to an mpu9250 handle structure |
| [in] | *mat | points to an orientation matrix buffer |
Definition at line 2392 of file driver_mpu9250.c.
| uint8_t mpu9250_dmp_set_pedometer_step_count | ( | mpu9250_handle_t * | handle, |
| uint32_t | count | ||
| ) |
dmp set the pedometer step count
| [in] | *handle | points to an mpu9250 handle structure |
| [in] | count | is the step count |
Definition at line 1259 of file driver_mpu9250.c.
| uint8_t mpu9250_dmp_set_pedometer_walk_time | ( | mpu9250_handle_t * | handle, |
| uint32_t | ms | ||
| ) |
dmp set the pedometer walk time
| [in] | *handle | points to an mpu9250 handle structure |
| [in] | ms | is the walk time |
Definition at line 1165 of file driver_mpu9250.c.
| uint8_t mpu9250_dmp_set_shake_reject_thresh | ( | mpu9250_handle_t * | handle, |
| uint16_t | dps | ||
| ) |
dmp set the shake reject thresh
| [in] | *handle | points to an mpu9250 handle structure |
| [in] | dps | is the shake reject thresh |
Definition at line 1536 of file driver_mpu9250.c.
| uint8_t mpu9250_dmp_set_shake_reject_time | ( | mpu9250_handle_t * | handle, |
| uint16_t | ms | ||
| ) |
dmp set the shake reject time
| [in] | *handle | points to an mpu9250 handle structure |
| [in] | ms | is the shake reject time |
Definition at line 1444 of file driver_mpu9250.c.
| uint8_t mpu9250_dmp_set_shake_reject_timeout | ( | mpu9250_handle_t * | handle, |
| uint16_t | ms | ||
| ) |
dmp set the shake reject timeout
| [in] | *handle | points to an mpu9250 handle structure |
| [in] | ms | is the reject timeout |
Definition at line 1352 of file driver_mpu9250.c.
| uint8_t mpu9250_dmp_set_tap_axes | ( | mpu9250_handle_t * | handle, |
| mpu9250_axis_t | axis, | ||
| mpu9250_bool_t | enable | ||
| ) |
dmp enable or disable the tap axes
| [in] | *handle | points to an mpu9250 handle structure |
| [in] | axis | is the set axis |
| [in] | enable | is a bool value |
Definition at line 3051 of file driver_mpu9250.c.
| uint8_t mpu9250_dmp_set_tap_callback | ( | mpu9250_handle_t * | handle, |
| void(*)(uint8_t count, uint8_t direction) | callback | ||
| ) |
dmp set the tap callback
| [in] | *handle | points to an mpu9250 handle structure |
| [in] | *callback | points to a callback function address |
Definition at line 3699 of file driver_mpu9250.c.
| uint8_t mpu9250_dmp_set_tap_thresh | ( | mpu9250_handle_t * | handle, |
| mpu9250_axis_t | axis, | ||
| uint16_t | mg_ms | ||
| ) |
dmp set the tap thresh
| [in] | *handle | points to an mpu9250 handle structure |
| [in] | axis | is the set axis |
| [in] | mg_ms | is the set thresh |
Definition at line 3168 of file driver_mpu9250.c.
| uint8_t mpu9250_dmp_set_tap_time | ( | mpu9250_handle_t * | handle, |
| uint16_t | ms | ||
| ) |
dmp set the tap time
| [in] | *handle | points to an mpu9250 handle structure |
| [in] | ms | is the tap time |
Definition at line 1726 of file driver_mpu9250.c.
| uint8_t mpu9250_dmp_set_tap_time_multi | ( | mpu9250_handle_t * | handle, |
| uint16_t | ms | ||
| ) |
dmp set max time between taps to register as a multi tap
| [in] | *handle | points to an mpu9250 handle structure |
| [in] | ms | is the delay time |
Definition at line 1634 of file driver_mpu9250.c.