41 #define L3G4200_DEFAULT_DR L3G4200_DR_100Hz
43 #define L3G4200_DEFAULT_DLPF L3G4200_DLPF_1
45 #define L3G4200_DEFAULT_SCALE L3G4200_SCALE_2000
48 #define L3G4200_DEFAULT_CTRL_REG1 ((L3G4200_DEFAULT_DR<<6) | (L3G4200_DEFAULT_DLPF<<4) | 0xf);
49 #define L3G4200_DEFAULT_CTRL_REG4 (L3G4200_DEFAULT_SCALE<<4) | 0x00;
50 #define L3G4200_DEFAULT_CTRL_REG5 0x00
I2C transaction structure.
Architecture independent I2C (Inter-Integrated Circuit Bus) API.
void l3g4200_start_configure(struct L3g4200 *l3g)
static void l3g4200_periodic(struct L3g4200 *l3g)
convenience function: read or start configuration if not already initialized
bool initialized
config done flag
volatile bool data_available
data ready flag
struct i2c_periph * i2c_p
struct i2c_transaction i2c_trans
struct L3g4200Config config
enum L3g4200ConfStatus init_status
init status
void l3g4200_read(struct L3g4200 *l3g)
L3g4200ConfStatus
config status states
void l3g4200_init(struct L3g4200 *l3g, struct i2c_periph *i2c_p, uint8_t i2c_address)
Initialize L3g4200 struct and set default config options.
void l3g4200_set_default_config(struct L3g4200Config *conf)
void l3g4200_event(struct L3g4200 *l3g)
Register defs for L3G4200 gyros.
Paparazzi fixed point algebra.
int int32_t
Typedef defining 32 bit int type.
unsigned char uint8_t
Typedef defining 8 bit unsigned char type.