![]() |
Paparazzi UAS v7.0_unstable
Paparazzi is a free software Unmanned Aircraft System.
|
Driver for ITG3200. More...
Go to the source code of this file.
Macros | |
#define | Int16FromBuf(_buf, _idx) ((int16_t)((_buf[_idx]<<8) | _buf[_idx+1])) |
Functions | |
void | itg3200_set_default_config (struct Itg3200Config *c) |
void | itg3200_init (struct Itg3200 *itg, struct i2c_periph *i2c_p, uint8_t addr) |
Initialize Itg3200 struct and set default config options. | |
static void | itg3200_i2c_tx_reg (struct Itg3200 *itg, uint8_t reg, uint8_t val) |
static void | itg3200_send_config (struct Itg3200 *itg) |
void | itg3200_start_configure (struct Itg3200 *itg) |
void | itg3200_read (struct Itg3200 *itg) |
void | itg3200_event (struct Itg3200 *itg) |
Definition at line 126 of file itg3200.c.
References foo, I2CTransDone, I2CTransFailed, I2CTransSuccess, Int16FromBuf, itg3200_send_config(), and ITG_CONF_UNINIT.
Referenced by imu_aspirin_event(), and imu_aspirin_i2c_event().
Definition at line 62 of file itg3200.c.
References foo, i2c_submit(), I2CTransTx, and val.
Referenced by itg3200_send_config().
void itg3200_init | ( | struct Itg3200 * | itg, |
struct i2c_periph * | i2c_p, | ||
uint8_t | addr | ||
) |
Initialize Itg3200 struct and set default config options.
itg | Itg3200 struct |
i2c_p | I2C periperal to use |
addr | I2C address of ITG3200 |
Definition at line 49 of file itg3200.c.
References foo, I2CTransDone, itg3200_set_default_config(), ITG_CONF_UNINIT, and i2c_periph::status.
Referenced by imu_aspirin_i2c_init(), and imu_aspirin_init().
Definition at line 113 of file itg3200.c.
References foo, i2c_submit(), I2CTransDone, I2CTransTxRx, and ITG3200_REG_INT_STATUS.
Referenced by itg3200_periodic().
Definition at line 73 of file itg3200.c.
References foo, I2CTransDone, itg3200_i2c_tx_reg(), ITG3200_REG_DLPF_FS, ITG3200_REG_INT_CFG, ITG3200_REG_PWR_MGM, ITG3200_REG_SMPLRT_DIV, ITG_CONF_DF, ITG_CONF_DONE, ITG_CONF_INT, ITG_CONF_PWR, and ITG_CONF_SD.
Referenced by itg3200_event(), and itg3200_start_configure().
void itg3200_set_default_config | ( | struct Itg3200Config * | c | ) |
Definition at line 33 of file itg3200.c.
References Itg3200Config::clk_sel, Itg3200Config::dlpf_cfg, Itg3200Config::fs_sel, Itg3200Config::int_cfg, ITG3200_DEFAULT_CLK_SEL, ITG3200_DEFAULT_DLPF_CFG, ITG3200_DEFAULT_FS_SEL, ITG3200_DEFAULT_INT_CFG, ITG3200_DEFAULT_SMPLRT_DIV, and Itg3200Config::smplrt_div.
Referenced by itg3200_init().
Definition at line 102 of file itg3200.c.
References foo, I2CTransDone, I2CTransSuccess, itg3200_send_config(), and ITG_CONF_UNINIT.
Referenced by itg3200_periodic().