CTL_STATUS_t mpu6000_initialize_i2c(MPU6000_t *self,
                                    CTL_I2C_BUS_t *bus,
                                    int addr);

mpu6000_initialize_i2c initializes the MPU-6000's accelerometer and gyroscope on the I2C bus bus using the 8-bit I2C address addr. When complete, the the IMU member core is initialized pointing to the appropriate members within self with the magnetometer set to zero.

Return Value

mpu6000_initialize_i2c returns a standard status code.

Thread Safety

mpu6000_initialize_i2c is thread-safe if a mutex is associated with the I2C bus bus.

See Also