![]() |
LibDriver MPU6050
|
mpu6050 example driver modules More...
Functions | |
| uint8_t | mpu6050_basic_init (mpu6050_address_t addr_pin) |
| basic example init | |
| uint8_t | mpu6050_basic_deinit (void) |
| basic example deinit | |
| uint8_t | mpu6050_basic_read (float g[3], float dps[3]) |
| basic example read | |
| uint8_t | mpu6050_basic_read_temperature (float *degrees) |
| basic example read temperature | |
| uint8_t | mpu6050_dmp_irq_handler (void) |
| dmp irq | |
| uint8_t | mpu6050_dmp_init (mpu6050_address_t addr_pin, void(*receive_callback)(uint8_t type), void(*tap_callback)(uint8_t count, uint8_t direction), void(*orient_callback)(uint8_t orientation)) |
| dmp example init | |
| uint8_t | mpu6050_dmp_deinit (void) |
| dmp example deinit | |
| uint8_t | mpu6050_dmp_read_all (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 example read | |
| uint8_t | mpu6050_dmp_get_pedometer_counter (uint32_t *cnt) |
| dmp example get pedometer counter | |
| uint8_t | mpu6050_fifo_irq_handler (void) |
| fifo irq | |
| uint8_t | mpu6050_fifo_init (mpu6050_address_t addr_pin) |
| fifo example init | |
| uint8_t | mpu6050_fifo_read (int16_t(*accel_raw)[3], float(*accel_g)[3], int16_t(*gyro_raw)[3], float(*gyro_dps)[3], uint16_t *len) |
| fifo example read | |
| uint8_t | mpu6050_fifo_deinit (void) |
| fifo example deinit | |
mpu6050 example driver modules
| #define MPU6050_BASIC_DEFAULT_ACCELEROMETER_RANGE MPU6050_ACCELEROMETER_RANGE_2G |
2g
Definition at line 63 of file driver_mpu6050_basic.h.
| #define MPU6050_BASIC_DEFAULT_CLOCK_SOURCE MPU6050_CLOCK_SOURCE_PLL_X_GYRO |
mpu6050 basic example default definition
gyro pll x
Definition at line 56 of file driver_mpu6050_basic.h.
| #define MPU6050_BASIC_DEFAULT_CYCLE_WAKE_UP MPU6050_BOOL_FALSE |
disable cycle wake up
Definition at line 59 of file driver_mpu6050_basic.h.
| #define MPU6050_BASIC_DEFAULT_EXTERN_SYNC MPU6050_EXTERN_SYNC_INPUT_DISABLED |
extern sync input disable
Definition at line 72 of file driver_mpu6050_basic.h.
| #define MPU6050_BASIC_DEFAULT_FSYNC_INTERRUPT MPU6050_BOOL_FALSE |
disable fsync interrupt
Definition at line 73 of file driver_mpu6050_basic.h.
| #define MPU6050_BASIC_DEFAULT_FSYNC_INTERRUPT_LEVEL MPU6050_PIN_LEVEL_LOW |
low level
Definition at line 74 of file driver_mpu6050_basic.h.
| #define MPU6050_BASIC_DEFAULT_GYROSCOPE_RANGE MPU6050_GYROSCOPE_RANGE_2000DPS |
2000dps
Definition at line 64 of file driver_mpu6050_basic.h.
| #define MPU6050_BASIC_DEFAULT_IIC_BYPASS MPU6050_BOOL_FALSE |
disable iic bypass
Definition at line 76 of file driver_mpu6050_basic.h.
| #define MPU6050_BASIC_DEFAULT_IIC_MASTER MPU6050_BOOL_FALSE |
disable iic master
Definition at line 75 of file driver_mpu6050_basic.h.
| #define MPU6050_BASIC_DEFAULT_INTERRUPT_DATA_READY MPU6050_BOOL_FALSE |
disable data ready
Definition at line 69 of file driver_mpu6050_basic.h.
| #define MPU6050_BASIC_DEFAULT_INTERRUPT_DMP MPU6050_BOOL_FALSE |
disable dmp
Definition at line 67 of file driver_mpu6050_basic.h.
| #define MPU6050_BASIC_DEFAULT_INTERRUPT_FIFO_OVERFLOW MPU6050_BOOL_FALSE |
disable fifo overflow
Definition at line 66 of file driver_mpu6050_basic.h.
| #define MPU6050_BASIC_DEFAULT_INTERRUPT_I2C_MAST MPU6050_BOOL_FALSE |
disable i2c master
Definition at line 68 of file driver_mpu6050_basic.h.
| #define MPU6050_BASIC_DEFAULT_INTERRUPT_LATCH MPU6050_BOOL_TRUE |
enable latch
Definition at line 70 of file driver_mpu6050_basic.h.
| #define MPU6050_BASIC_DEFAULT_INTERRUPT_MOTION MPU6050_BOOL_FALSE |
disable motion
Definition at line 65 of file driver_mpu6050_basic.h.
| #define MPU6050_BASIC_DEFAULT_INTERRUPT_PIN_LEVEL MPU6050_PIN_LEVEL_LOW |
low level
Definition at line 61 of file driver_mpu6050_basic.h.
| #define MPU6050_BASIC_DEFAULT_INTERRUPT_PIN_TYPE MPU6050_PIN_TYPE_PUSH_PULL |
push pull
Definition at line 62 of file driver_mpu6050_basic.h.
| #define MPU6050_BASIC_DEFAULT_INTERRUPT_READ_CLEAR MPU6050_BOOL_TRUE |
enable interrupt read clear
Definition at line 71 of file driver_mpu6050_basic.h.
| #define MPU6050_BASIC_DEFAULT_LOW_PASS_FILTER MPU6050_LOW_PASS_FILTER_3 |
low pass filter 3
Definition at line 58 of file driver_mpu6050_basic.h.
| #define MPU6050_BASIC_DEFAULT_RATE 50 |
50Hz
Definition at line 57 of file driver_mpu6050_basic.h.
| #define MPU6050_BASIC_DEFAULT_WAKE_UP_FREQUENCY MPU6050_WAKE_UP_FREQUENCY_1P25_HZ |
1.25Hz
Definition at line 60 of file driver_mpu6050_basic.h.
| #define MPU6050_DMP_DEFAULT_ACCELEROMETER_RANGE MPU6050_ACCELEROMETER_RANGE_2G |
2g
Definition at line 56 of file driver_mpu6050_dmp.h.
| #define MPU6050_DMP_DEFAULT_CLOCK_SOURCE MPU6050_CLOCK_SOURCE_PLL_X_GYRO |
mpu6050 dmp example default definition
gyro pll x
Definition at line 54 of file driver_mpu6050_dmp.h.
| #define MPU6050_DMP_DEFAULT_CYCLE_WAKE_UP MPU6050_BOOL_FALSE |
disable cycle wake up
Definition at line 59 of file driver_mpu6050_dmp.h.
| #define MPU6050_DMP_DEFAULT_EXTERN_SYNC MPU6050_EXTERN_SYNC_INPUT_DISABLED |
extern sync input disable
Definition at line 70 of file driver_mpu6050_dmp.h.
| #define MPU6050_DMP_DEFAULT_FSYNC_INTERRUPT MPU6050_BOOL_FALSE |
disable fsync interrupt
Definition at line 71 of file driver_mpu6050_dmp.h.
| #define MPU6050_DMP_DEFAULT_FSYNC_INTERRUPT_LEVEL MPU6050_PIN_LEVEL_LOW |
low level
Definition at line 72 of file driver_mpu6050_dmp.h.
| #define MPU6050_DMP_DEFAULT_GYROSCOPE_RANGE MPU6050_GYROSCOPE_RANGE_2000DPS |
2000dps
Definition at line 57 of file driver_mpu6050_dmp.h.
| #define MPU6050_DMP_DEFAULT_IIC_BYPASS MPU6050_BOOL_FALSE |
disable iic bypass
Definition at line 74 of file driver_mpu6050_dmp.h.
| #define MPU6050_DMP_DEFAULT_IIC_MASTER MPU6050_BOOL_FALSE |
disable iic master
Definition at line 73 of file driver_mpu6050_dmp.h.
| #define MPU6050_DMP_DEFAULT_INTERRUPT_DATA_READY MPU6050_BOOL_FALSE |
disable data ready
Definition at line 67 of file driver_mpu6050_dmp.h.
| #define MPU6050_DMP_DEFAULT_INTERRUPT_DMP MPU6050_BOOL_FALSE |
disable dmp
Definition at line 65 of file driver_mpu6050_dmp.h.
| #define MPU6050_DMP_DEFAULT_INTERRUPT_FIFO_OVERFLOW MPU6050_BOOL_TRUE |
enable fifo overflow
Definition at line 64 of file driver_mpu6050_dmp.h.
| #define MPU6050_DMP_DEFAULT_INTERRUPT_I2C_MAST MPU6050_BOOL_FALSE |
disable i2c master
Definition at line 66 of file driver_mpu6050_dmp.h.
| #define MPU6050_DMP_DEFAULT_INTERRUPT_LATCH MPU6050_BOOL_TRUE |
enable latch
Definition at line 68 of file driver_mpu6050_dmp.h.
| #define MPU6050_DMP_DEFAULT_INTERRUPT_MODE MPU6050_DMP_INTERRUPT_MODE_CONTINUOUS |
interrupt continuous mode
Definition at line 86 of file driver_mpu6050_dmp.h.
| #define MPU6050_DMP_DEFAULT_INTERRUPT_MOTION MPU6050_BOOL_TRUE |
enable motion
Definition at line 63 of file driver_mpu6050_dmp.h.
| #define MPU6050_DMP_DEFAULT_INTERRUPT_PIN_LEVEL MPU6050_PIN_LEVEL_LOW |
low level
Definition at line 61 of file driver_mpu6050_dmp.h.
| #define MPU6050_DMP_DEFAULT_INTERRUPT_PIN_TYPE MPU6050_PIN_TYPE_PUSH_PULL |
push pull
Definition at line 62 of file driver_mpu6050_dmp.h.
| #define MPU6050_DMP_DEFAULT_INTERRUPT_READ_CLEAR MPU6050_BOOL_TRUE |
enable interrupt read clear
Definition at line 69 of file driver_mpu6050_dmp.h.
| #define MPU6050_DMP_DEFAULT_LOW_PASS_FILTER MPU6050_LOW_PASS_FILTER_3 |
low pass filter 3
Definition at line 58 of file driver_mpu6050_dmp.h.
| #define MPU6050_DMP_DEFAULT_MIN_TAP_COUNT 1 |
1
Definition at line 82 of file driver_mpu6050_dmp.h.
| #define MPU6050_DMP_DEFAULT_MOTION_DURATION 200 |
200 ms
Definition at line 87 of file driver_mpu6050_dmp.h.
| #define MPU6050_DMP_DEFAULT_MOTION_THRESHOLD 200 |
200 mg
Definition at line 88 of file driver_mpu6050_dmp.h.
| #define MPU6050_DMP_DEFAULT_PEOMETER_STEP_COUNT 0 |
0
Definition at line 76 of file driver_mpu6050_dmp.h.
| #define MPU6050_DMP_DEFAULT_PEOMETER_WALK_TIME 200 |
200ms
Definition at line 75 of file driver_mpu6050_dmp.h.
| #define MPU6050_DMP_DEFAULT_RATE 50 |
50Hz
Definition at line 55 of file driver_mpu6050_dmp.h.
| #define MPU6050_DMP_DEFAULT_SHAKE_REJECT_THRESH 200 |
200dps
Definition at line 79 of file driver_mpu6050_dmp.h.
| #define MPU6050_DMP_DEFAULT_SHAKE_REJECT_TIME 40 |
40ms
Definition at line 78 of file driver_mpu6050_dmp.h.
| #define MPU6050_DMP_DEFAULT_SHAKE_REJECT_TIMEOUT 10 |
10ms
Definition at line 77 of file driver_mpu6050_dmp.h.
| #define MPU6050_DMP_DEFAULT_TAP_TIME 100 |
100ms
Definition at line 81 of file driver_mpu6050_dmp.h.
| #define MPU6050_DMP_DEFAULT_TAP_TIME_MULTI 200 |
200ms
Definition at line 80 of file driver_mpu6050_dmp.h.
| #define MPU6050_DMP_DEFAULT_TAP_X_THRESH 250 |
250 mg/ms
Definition at line 83 of file driver_mpu6050_dmp.h.
| #define MPU6050_DMP_DEFAULT_TAP_Y_THRESH 250 |
250 mg/ms
Definition at line 84 of file driver_mpu6050_dmp.h.
| #define MPU6050_DMP_DEFAULT_TAP_Z_THRESH 250 |
250 mg/ms
Definition at line 85 of file driver_mpu6050_dmp.h.
| #define MPU6050_DMP_DEFAULT_WAKE_UP_FREQUENCY MPU6050_WAKE_UP_FREQUENCY_1P25_HZ |
1.25Hz
Definition at line 60 of file driver_mpu6050_dmp.h.
| #define MPU6050_FIFO_DEFAULT_ACCELEROMETER_RANGE MPU6050_ACCELEROMETER_RANGE_2G |
2g
Definition at line 56 of file driver_mpu6050_fifo.h.
| #define MPU6050_FIFO_DEFAULT_CLOCK_SOURCE MPU6050_CLOCK_SOURCE_PLL_X_GYRO |
mpu6050 fifo example default definition
gyro pll x
Definition at line 54 of file driver_mpu6050_fifo.h.
| #define MPU6050_FIFO_DEFAULT_CYCLE_WAKE_UP MPU6050_BOOL_FALSE |
disable cycle wake up
Definition at line 59 of file driver_mpu6050_fifo.h.
| #define MPU6050_FIFO_DEFAULT_EXTERN_SYNC MPU6050_EXTERN_SYNC_INPUT_DISABLED |
extern sync input disable
Definition at line 70 of file driver_mpu6050_fifo.h.
| #define MPU6050_FIFO_DEFAULT_FSYNC_INTERRUPT MPU6050_BOOL_FALSE |
disable fsync interrupt
Definition at line 71 of file driver_mpu6050_fifo.h.
| #define MPU6050_FIFO_DEFAULT_FSYNC_INTERRUPT_LEVEL MPU6050_PIN_LEVEL_LOW |
low level
Definition at line 72 of file driver_mpu6050_fifo.h.
| #define MPU6050_FIFO_DEFAULT_GYROSCOPE_RANGE MPU6050_GYROSCOPE_RANGE_2000DPS |
2000dps
Definition at line 57 of file driver_mpu6050_fifo.h.
| #define MPU6050_FIFO_DEFAULT_IIC_BYPASS MPU6050_BOOL_FALSE |
disable iic bypass
Definition at line 74 of file driver_mpu6050_fifo.h.
| #define MPU6050_FIFO_DEFAULT_IIC_MASTER MPU6050_BOOL_FALSE |
disable iic master
Definition at line 73 of file driver_mpu6050_fifo.h.
| #define MPU6050_FIFO_DEFAULT_INTERRUPT_DATA_READY MPU6050_BOOL_FALSE |
disable data ready
Definition at line 67 of file driver_mpu6050_fifo.h.
| #define MPU6050_FIFO_DEFAULT_INTERRUPT_DMP MPU6050_BOOL_FALSE |
disable dmp
Definition at line 65 of file driver_mpu6050_fifo.h.
| #define MPU6050_FIFO_DEFAULT_INTERRUPT_FIFO_OVERFLOW MPU6050_BOOL_TRUE |
enable fifo overflow
Definition at line 64 of file driver_mpu6050_fifo.h.
| #define MPU6050_FIFO_DEFAULT_INTERRUPT_I2C_MAST MPU6050_BOOL_FALSE |
disable i2c master
Definition at line 66 of file driver_mpu6050_fifo.h.
| #define MPU6050_FIFO_DEFAULT_INTERRUPT_LATCH MPU6050_BOOL_TRUE |
enable latch
Definition at line 68 of file driver_mpu6050_fifo.h.
| #define MPU6050_FIFO_DEFAULT_INTERRUPT_MOTION MPU6050_BOOL_FALSE |
disable motion
Definition at line 63 of file driver_mpu6050_fifo.h.
| #define MPU6050_FIFO_DEFAULT_INTERRUPT_PIN_LEVEL MPU6050_PIN_LEVEL_LOW |
low level
Definition at line 61 of file driver_mpu6050_fifo.h.
| #define MPU6050_FIFO_DEFAULT_INTERRUPT_PIN_TYPE MPU6050_PIN_TYPE_PUSH_PULL |
push pull
Definition at line 62 of file driver_mpu6050_fifo.h.
| #define MPU6050_FIFO_DEFAULT_INTERRUPT_READ_CLEAR MPU6050_BOOL_TRUE |
enable interrupt read clear
Definition at line 69 of file driver_mpu6050_fifo.h.
| #define MPU6050_FIFO_DEFAULT_LOW_PASS_FILTER MPU6050_LOW_PASS_FILTER_3 |
low pass filter 3
Definition at line 58 of file driver_mpu6050_fifo.h.
| #define MPU6050_FIFO_DEFAULT_RATE 50 |
50Hz
Definition at line 55 of file driver_mpu6050_fifo.h.
| #define MPU6050_FIFO_DEFAULT_WAKE_UP_FREQUENCY MPU6050_WAKE_UP_FREQUENCY_1P25_HZ |
1.25Hz
Definition at line 60 of file driver_mpu6050_fifo.h.
| uint8_t mpu6050_basic_deinit | ( | void | ) |
basic example deinit
Definition at line 566 of file driver_mpu6050_basic.c.
| uint8_t mpu6050_basic_init | ( | mpu6050_address_t | addr_pin | ) |
basic example init
| [in] | addr_pin | iic device address |
Definition at line 49 of file driver_mpu6050_basic.c.
| uint8_t mpu6050_basic_read | ( | float | g[3], |
| float | dps[3] ) |
basic example read
| [out] | *g | pointer to a converted data buffer |
| [out] | *dps | pointer to a converted data buffer |
Definition at line 527 of file driver_mpu6050_basic.c.
| uint8_t mpu6050_basic_read_temperature | ( | float * | degrees | ) |
basic example read temperature
| [out] | *degrees | pointer to a converted data buffer |
Definition at line 505 of file driver_mpu6050_basic.c.
| uint8_t mpu6050_dmp_deinit | ( | void | ) |
dmp example deinit
Definition at line 918 of file driver_mpu6050_dmp.c.
| uint8_t mpu6050_dmp_get_pedometer_counter | ( | uint32_t * | cnt | ) |
dmp example get pedometer counter
| [out] | *cnt | pointer to a cnt buffer |
Definition at line 865 of file driver_mpu6050_dmp.c.
| uint8_t mpu6050_dmp_init | ( | mpu6050_address_t | addr_pin, |
| void(* | receive_callback )(uint8_t type), | ||
| void(* | tap_callback )(uint8_t count, uint8_t direction), | ||
| void(* | orient_callback )(uint8_t orientation) ) |
dmp example init
| [in] | addr_pin | iic device address |
| [in] | *receive_callback | pointer to a receive callback function |
| [in] | *tap_callback | pointer to a tap callback function |
| [in] | *orient_callback | pointer to an orient callback function |
Definition at line 71 of file driver_mpu6050_dmp.c.
| uint8_t mpu6050_dmp_irq_handler | ( | void | ) |
dmp irq
Definition at line 48 of file driver_mpu6050_dmp.c.
| uint8_t mpu6050_dmp_read_all | ( | 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 example read
| [out] | *accel_raw | pointer to an accel raw buffer |
| [out] | *accel_g | pointer to an accel g buffer |
| [out] | *gyro_raw | pointer to a gyro raw buffer |
| [out] | *gyro_dps | pointer to a gyro dps buffer |
| [out] | *quat | pointer to a quat buffer |
| [out] | *pitch | pointer to a pitch buffer |
| [out] | *roll | pointer to a roll buffer |
| [out] | *yaw | pointer to a yaw buffer |
| [in,out] | *l | pointer to a length buffer |
Definition at line 892 of file driver_mpu6050_dmp.c.
| uint8_t mpu6050_fifo_deinit | ( | void | ) |
fifo example deinit
Definition at line 560 of file driver_mpu6050_fifo.c.
| uint8_t mpu6050_fifo_init | ( | mpu6050_address_t | addr_pin | ) |
fifo example init
| [in] | addr_pin | iic device address |
Definition at line 68 of file driver_mpu6050_fifo.c.
| uint8_t mpu6050_fifo_irq_handler | ( | void | ) |
fifo irq
Definition at line 48 of file driver_mpu6050_fifo.c.
| uint8_t mpu6050_fifo_read | ( | int16_t(*) | accel_raw[3], |
| float(*) | accel_g[3], | ||
| int16_t(*) | gyro_raw[3], | ||
| float(*) | gyro_dps[3], | ||
| uint16_t * | len ) |
fifo example read
| [out] | **accel_raw | pointer to an accel raw data buffer |
| [out] | **accel_g | pointer to a converted accel data buffer |
| [out] | **gyro_raw | pointer to an gyro raw data buffer |
| [out] | **gyro_dps | pointer to a converted gyro data buffer |
| [in,out] | *len | pointer to a length buffer |
Definition at line 538 of file driver_mpu6050_fifo.c.