41 #define ITG3200_DEFAULT_SMPLRT_DIV 0
43 #define ITG3200_DEFAULT_FS_SEL 3
45 #define ITG3200_DEFAULT_DLPF_CFG ITG3200_DLPF_42HZ
47 #define ITG3200_DEFAULT_INT_CFG 1
49 #define ITG3200_DEFAULT_CLK_SEL 1
I2C transaction structure.
Architecture independent I2C (Inter-Integrated Circuit Bus) API.
void itg3200_init(struct Itg3200 *itg, struct i2c_periph *i2c_p, uint8_t i2c_address)
Initialize Itg3200 struct and set default config options.
enum Itg3200ConfStatus init_status
init status
enum Itg3200DLPF dlpf_cfg
Digital Low Pass Filter.
struct i2c_transaction i2c_trans
static void itg3200_periodic(struct Itg3200 *itg)
convenience function: read or start configuration if not already initialized
void itg3200_start_configure(struct Itg3200 *itg)
uint8_t smplrt_div
Sample rate divider.
void itg3200_set_default_config(struct Itg3200Config *conf)
void itg3200_event(struct Itg3200 *itg)
uint8_t int_cfg
Interrupt config.
bool initialized
config done flag
uint8_t fs_sel
Full scale range.
uint8_t clk_sel
Clock select.
Itg3200ConfStatus
config status states
struct i2c_periph * i2c_p
struct Itg3200Config config
volatile bool data_available
data ready flag
void itg3200_read(struct Itg3200 *itg)
Register defs for ITG3200 and IMU3000 gyros.
Itg3200DLPF
Digital Low Pass Filter Options.
Paparazzi fixed point algebra.
int int32_t
Typedef defining 32 bit int type.
unsigned char uint8_t
Typedef defining 8 bit unsigned char type.