#include <breezystm32.h>
#include <math.h>
Go to the source code of this file.
|
| enum | accel_fsr_e {
INV_FSR_2G = 0,
INV_FSR_4G,
INV_FSR_8G,
INV_FSR_16G,
NUM_ACCEL_FSR
} |
| |
| enum | clock_sel_e { INV_CLK_INTERNAL = 0,
INV_CLK_PLL,
NUM_CLK
} |
| |
| enum | gyro_fsr_e {
INV_FSR_250DPS = 0,
INV_FSR_500DPS,
INV_FSR_1000DPS,
INV_FSR_2000DPS,
NUM_GYRO_FSR
} |
| |
| enum | lpf_e {
INV_FILTER_256HZ_NOLPF2 = 0,
INV_FILTER_188HZ,
INV_FILTER_98HZ,
INV_FILTER_42HZ,
INV_FILTER_20HZ,
INV_FILTER_10HZ,
INV_FILTER_5HZ,
INV_FILTER_2100HZ_NOLPF,
NUM_FILTER
} |
| |
|
| void | EXTI15_10_IRQHandler (void) |
| |
| void | mpu6050_async_read_all (volatile int16_t *accData, volatile int16_t *tempData, volatile int16_t *gyroData, volatile uint64_t *timeData) |
| |
| void | mpu6050_exti_init (int boardVersion) |
| |
| void | mpu6050_init (bool enableInterrupt, uint16_t *acc1G, float *gyroScale, int boardVersion) |
| |
| bool | mpu6050_new_data () |
| |
| void | mpu6050_read_accel (int16_t *accData) |
| |
| void | mpu6050_read_all (int16_t *accData, int16_t *gyroData, int16_t *tempData, uint64_t *time_us) |
| |
| void | mpu6050_read_gyro (int16_t *gyroData) |
| |
| void | mpu6050_read_temperature (int16_t *tempData) |
| |
| void | mpu6050_request_async_update_all () |
| |
| static bool | mpuReadRegisterI2C (uint8_t reg, uint8_t *data, int length) |
| |
| static bool | mpuWriteRegisterI2C (uint8_t reg, uint8_t data) |
| |
| void | read_all_CB (uint8_t result) |
| |
| #define MPU6050_BIT_DMP_RST 0x08 |
| #define MPU6050_BIT_FIFO_EN 0x40 |
| #define MPU6050_BIT_FIFO_RST 0x04 |
| #define MPU6050_INV_CLK_GYROZ 0x03 |
| #define MPU_ADDRESS (0x68) |
| #define MPU_RA_ACCEL_CONFIG 0x1C |
| #define MPU_RA_ACCEL_XOUT_H (0x3B) |
| #define MPU_RA_CONFIG 0x1A |
| #define MPU_RA_FIFO_COUNT_H 0x72 |
| #define MPU_RA_FIFO_EN 0x23 |
| #define MPU_RA_FIFO_R_W 0x74 |
| #define MPU_RA_GYRO_CONFIG 0x1B |
| #define MPU_RA_GYRO_XOUT_H (0x43) |
| #define MPU_RA_I2C_MST_CTRL 0x24 |
| #define MPU_RA_INT_ENABLE 0x38 |
| #define MPU_RA_INT_PIN_CFG 0x37 |
| #define MPU_RA_PRODUCT_ID (0x0C) |
| #define MPU_RA_PWR_MGMT_1 0x6B |
| #define MPU_RA_PWR_MGMT_2 0x6C |
| #define MPU_RA_SIGNAL_PATH_RST 0x68 |
| #define MPU_RA_SMPLRT_DIV 0x19 |
| #define MPU_RA_TEMP_OUT_A (0x41) |
| #define MPU_RA_USER_CTRL 0x6A |
| #define MPU_RA_WHO_AM_I (0x75) |
| #define MPU_RA_XA_OFFS_H (0x06) |
| #define MPUx0x0_WHO_AM_I_CONST (0x68) |
| Enumerator |
|---|
| INV_FSR_2G |
|
| INV_FSR_4G |
|
| INV_FSR_8G |
|
| INV_FSR_16G |
|
| NUM_ACCEL_FSR |
|
Definition at line 81 of file drv_mpu6050.c.
| Enumerator |
|---|
| INV_CLK_INTERNAL |
|
| INV_CLK_PLL |
|
| NUM_CLK |
|
Definition at line 75 of file drv_mpu6050.c.
| Enumerator |
|---|
| INV_FSR_250DPS |
|
| INV_FSR_500DPS |
|
| INV_FSR_1000DPS |
|
| INV_FSR_2000DPS |
|
| NUM_GYRO_FSR |
|
Definition at line 67 of file drv_mpu6050.c.
| Enumerator |
|---|
| INV_FILTER_256HZ_NOLPF2 |
|
| INV_FILTER_188HZ |
|
| INV_FILTER_98HZ |
|
| INV_FILTER_42HZ |
|
| INV_FILTER_20HZ |
|
| INV_FILTER_10HZ |
|
| INV_FILTER_5HZ |
|
| INV_FILTER_2100HZ_NOLPF |
|
| NUM_FILTER |
|
Definition at line 55 of file drv_mpu6050.c.
| void EXTI15_10_IRQHandler |
( |
void |
| ) |
|
| void mpu6050_async_read_all |
( |
volatile int16_t * |
accData, |
|
|
volatile int16_t * |
tempData, |
|
|
volatile int16_t * |
gyroData, |
|
|
volatile uint64_t * |
timeData |
|
) |
| |
| void mpu6050_exti_init |
( |
int |
boardVersion | ) |
|
| void mpu6050_init |
( |
bool |
enableInterrupt, |
|
|
uint16_t * |
acc1G, |
|
|
float * |
gyroScale, |
|
|
int |
boardVersion |
|
) |
| |
| bool mpu6050_new_data |
( |
| ) |
|
| void mpu6050_read_accel |
( |
int16_t * |
accData | ) |
|
| void mpu6050_read_all |
( |
int16_t * |
accData, |
|
|
int16_t * |
gyroData, |
|
|
int16_t * |
tempData, |
|
|
uint64_t * |
time_us |
|
) |
| |
| void mpu6050_read_gyro |
( |
int16_t * |
gyroData | ) |
|
| void mpu6050_read_temperature |
( |
int16_t * |
tempData | ) |
|
| void mpu6050_request_async_update_all |
( |
| ) |
|
| static bool mpuReadRegisterI2C |
( |
uint8_t |
reg, |
|
|
uint8_t * |
data, |
|
|
int |
length |
|
) |
| |
|
static |
| static bool mpuWriteRegisterI2C |
( |
uint8_t |
reg, |
|
|
uint8_t |
data |
|
) |
| |
|
static |
| void read_all_CB |
( |
uint8_t |
result | ) |
|
| volatile int16_t accel[3] |
|
static |
| uint64_t measurement_time = 0 |
| volatile bool need_to_queue_new_i2c_job = false |
|
static |
| bool new_imu_data = false |
|
static |