Paparazzi UAS
v7.0_unstable
Paparazzi is a free software Unmanned Aircraft System.
|
Sensor driver for BMP280 sensor via I2C. More...
Go to the source code of this file.
Data Structures | |
struct | Bmp280_I2c |
Functions | |
void | bmp280_i2c_read_eeprom_calib (struct Bmp280_I2c *bmp) |
void | bmp280_i2c_init (struct Bmp280_I2c *bmp, struct i2c_periph *i2c_p, uint8_t addr) |
void | bmp280_i2c_periodic (struct Bmp280_I2c *bmp) |
void | bmp280_i2c_event (struct Bmp280_I2c *bmp) |
Sensor driver for BMP280 sensor via I2C.
Definition in file bmp280_i2c.h.
struct Bmp280_I2c |
Definition at line 35 of file bmp280_i2c.h.
Data Fields | ||
---|---|---|
struct bmp280_reg_calib_data | calib | calibration data |
volatile bool | data_available | data ready flag |
struct i2c_periph * | i2c_p | |
struct i2c_transaction | i2c_trans | |
bool | initialized | config done flag |
float | pressure | pressure in Pascal |
uint32_t | raw_pressure | uncompensated pressure |
uint32_t | raw_temperature | uncompensated temperature |
enum Bmp280Status | status | state machine status |
float | temperature | temperature in deg Celcius |
void bmp280_i2c_event | ( | struct Bmp280_I2c * | bmp | ) |
Definition at line 104 of file bmp280_i2c.c.
References BMP280_EOC_BIT, BMP280_NVRAM_COPY_BIT, BMP280_STATUS_CONFIGURE, BMP280_STATUS_GET_CALIB, BMP280_STATUS_READ_DATA_REGS, BMP280_STATUS_READ_STATUS_REG, BMP280_STATUS_UNINIT, i2c_transaction::buf, compensate_pressure(), compensate_temperature(), Bmp280_I2c::data_available, Bmp280_I2c::i2c_trans, I2CTransDone, I2CTransFailed, I2CTransSuccess, Bmp280_I2c::initialized, parse_calib_data(), parse_sensor_data(), i2c_transaction::status, and Bmp280_I2c::status.
Referenced by baro_bmp280_event().
void bmp280_i2c_init | ( | struct Bmp280_I2c * | bmp, |
struct i2c_periph * | i2c_p, | ||
uint8_t | addr | ||
) |
Definition at line 41 of file bmp280_i2c.c.
References BMP280_STATUS_UNINIT, and I2CTransDone.
Referenced by baro_bmp280_init().
void bmp280_i2c_periodic | ( | struct Bmp280_I2c * | bmp | ) |
Definition at line 57 of file bmp280_i2c.c.
References BMP280_CALIB_DATA_LEN, BMP280_CALIB_LSB_DATA_ADDR, BMP280_CONFIG_LEN, BMP280_CONFIG_REG_ADDR, BMP280_CTRL_MEAS_REG_ADDR, BMP280_DATA_START_REG_ADDR, BMP280_IIR_FILTER_COEFF_2, BMP280_INACTIVITY_62_5_MS, BMP280_OVERSAMPLING_1X_T, BMP280_OVERSAMPLING_8X_P, BMP280_P_T_DATA_LEN, BMP280_POWER_NORMAL_MODE, BMP280_STATUS_CONFIGURE, BMP280_STATUS_GET_CALIB, BMP280_STATUS_READ_DATA_REGS, BMP280_STATUS_READ_STATUS_REG, BMP280_STATUS_REG_ADDR, BMP280_STATUS_UNINIT, i2c_transaction::buf, Bmp280_I2c::data_available, Bmp280_I2c::i2c_p, Bmp280_I2c::i2c_trans, i2c_transceive(), i2c_transmit(), I2CTransDone, Bmp280_I2c::initialized, i2c_transaction::slave_addr, i2c_transaction::status, and Bmp280_I2c::status.
Referenced by baro_bmp280_periodic().
void bmp280_i2c_read_eeprom_calib | ( | struct Bmp280_I2c * | bmp | ) |