Help with BNO055 Sensor Data


I am working with the BNO055 Absolute Orientation Sensor and wanted to try and see if I could get the outputs by sending the I2C registers to the sensor, instead of using the getVector() or getEvent() functions. I tried using the following code to get the accelerometer values, but I got an error saying “no matching function for call to ‘TwoWire::read(int)’”. I’m not even sure if this is the right way to send the I2C registers to the sensor, so if you could provide any help or feedback on my code, that would be much appreciated! Also, if you have any idea what the error is referring to, please let me know as well!

Thanks for your help!

#include <Wire.h>
#include <Adafruit_Sensor.h>
#include <Adafruit_BNO055.h>
#include <utility/imumaths.h>
#define BNO055_ACCEL_DATA_X_LSB_ADDR    (0x08)
#define BNO055_ACCEL_DATA_X_MSB_ADDR    (0x09)

Adafruit_BNO055 bno = Adafruit_BNO055(55);

void setup(void) 
  /* Initialise the sensor */
    /* There was a problem detecting the BNO055 ... check your connections */
    Serial.print("Ooops, no BNO055 detected ... Check your wiring or I2C ADDR!");

void loop() {

float x_accel = ( << 8) | (;
float y_accel = ( << 8) | (;
float z_accel = ( << 8) | (;

Serial.print("ax: ");Serial.print(x_accel); Serial.print(" "); 
Serial.print("ay: ");Serial.print(y_accel); Serial.print(" ");
Serial.print("az: ");Serial.print(z_accel); Serial.println(); Serial.println();


What you can do is to look into the library files in your posting to see how they are using I2C to talk to the device as a hint on the direction to take. You'd want to download and read the register datasheet for the device you are using.