Paparazzi UAS
v5.18.0_stable
Paparazzi is a free software Unmanned Aircraft System.
|
#include "peripherals/bmi088_i2c.h"
Go to the source code of this file.
Macros | |
#define | Int16FromBuf(_buf, _idx) ((int16_t)((_buf[_idx+1]<<8) | _buf[_idx])) |
Functions | |
void | bmi088_i2c_init (struct Bmi088_I2c *bmi, struct i2c_periph *i2c_p, uint8_t gyro_addr, uint8_t accel_addr) |
static void | bmi088_i2c_write_to_reg (void *bmi, uint8_t _reg, uint8_t _val, uint8_t _type) |
void | bmi088_i2c_start_configure (struct Bmi088_I2c *bmi) |
void | bmi088_i2c_read (struct Bmi088_I2c *bmi) |
void | bmi088_i2c_event (struct Bmi088_I2c *bmi) |
Driver for the BMI088 using I2C.
Definition in file bmi088_i2c.c.
#define Int16FromBuf | ( | _buf, | |
_idx | |||
) | ((int16_t)((_buf[_idx+1]<<8) | _buf[_idx])) |
Definition at line 91 of file bmi088_i2c.c.
void bmi088_i2c_event | ( | struct Bmi088_I2c * | bmi | ) |
Definition at line 93 of file bmi088_i2c.c.
References Bmi088_I2c::accel_available, Bmi088_I2c::accel_trans, BMI088_CONF_ACCEL_PWR_CTRL, BMI088_CONF_UNINIT, bmi088_i2c_write_to_reg(), bmi088_send_config(), i2c_transaction::buf, Bmi088_I2c::config, Bmi088_I2c::data_accel, Bmi088_I2c::data_rates, Bmi088_I2c::gyro_available, Bmi088_I2c::gyro_trans, I2CTransDone, I2CTransFailed, I2CTransSuccess, Bmi088Config::init_status, Bmi088Config::initialized, Int16FromBuf, and i2c_transaction::status.
Referenced by imu_bmi088_event().
void bmi088_i2c_init | ( | struct Bmi088_I2c * | bmi, |
struct i2c_periph * | i2c_p, | ||
uint8_t | gyro_addr, | ||
uint8_t | accel_addr | ||
) |
Definition at line 30 of file bmi088_i2c.c.
References Bmi088_I2c::accel_available, Bmi088_I2c::accel_trans, BMI088_CONF_UNINIT, bmi088_set_default_config(), Bmi088_I2c::config, Bmi088_I2c::gyro_available, Bmi088_I2c::gyro_trans, Bmi088_I2c::i2c_p, I2CTransDone, Bmi088Config::init_status, Bmi088Config::initialized, i2c_transaction::slave_addr, and i2c_transaction::status.
Referenced by imu_bmi088_init().
void bmi088_i2c_read | ( | struct Bmi088_I2c * | bmi | ) |
Definition at line 77 of file bmi088_i2c.c.
References Bmi088_I2c::accel_trans, BMI088_ACCEL_X_LSB, BMI088_GYRO_RATE_X_LSB, i2c_transaction::buf, Bmi088_I2c::config, Bmi088_I2c::gyro_trans, Bmi088_I2c::i2c_p, i2c_transceive(), I2CTransDone, Bmi088Config::initialized, i2c_transaction::slave_addr, and i2c_transaction::status.
Referenced by bmi088_i2c_periodic().
void bmi088_i2c_start_configure | ( | struct Bmi088_I2c * | bmi | ) |
Definition at line 67 of file bmi088_i2c.c.
References Bmi088_I2c::accel_trans, BMI088_CONF_UNINIT, bmi088_i2c_write_to_reg(), bmi088_send_config(), Bmi088_I2c::config, I2CTransDone, I2CTransSuccess, Bmi088Config::init_status, and i2c_transaction::status.
Referenced by bmi088_i2c_periodic().
|
static |
Definition at line 52 of file bmi088_i2c.c.
References Bmi088_I2c::accel_trans, BMI088_CONFIG_ACCEL, BMI088_CONFIG_GYRO, i2c_transaction::buf, Bmi088_I2c::gyro_trans, Bmi088_I2c::i2c_p, i2c_transmit(), and i2c_transaction::slave_addr.
Referenced by bmi088_i2c_event(), and bmi088_i2c_start_configure().