diff --git a/src/mpu9150/mpu9250.cxx b/src/mpu9150/mpu9250.cxx index 6eccf8c8..c646a983 100644 --- a/src/mpu9150/mpu9250.cxx +++ b/src/mpu9150/mpu9250.cxx @@ -31,8 +31,8 @@ using namespace upm; using namespace std; -MPU9250::MPU9250 (int bus, int address, int magAddress) : - MPU9150(bus, address, magAddress) +MPU9250::MPU9250 (int bus, int address, int magAddress, bool enableAk8975) : + MPU9150(bus, address, magAddress, enableAk8975) { } diff --git a/src/mpu9150/mpu9250.h b/src/mpu9150/mpu9250.h index 2b2b95c7..b7d0f061 100644 --- a/src/mpu9150/mpu9250.h +++ b/src/mpu9150/mpu9250.h @@ -58,9 +58,11 @@ namespace upm { * @param bus I2C bus to use * @param address The address for this device * @param magAddress The address of the connected magnetometer + * @param enableAk8975 Enables i2c bypass mode for magnetometer, default + * is true */ MPU9250 (int bus=MPU9250_I2C_BUS, int address=MPU9250_DEFAULT_I2C_ADDR, - int magAddress=AK8975_DEFAULT_I2C_ADDR); + int magAddress=AK8975_DEFAULT_I2C_ADDR, bool enableAk8975=true); /** * MPU9250 destructor