How to access BNO055 absolute orientation sensor from adafruit feather ESP8266 using its libraries?

Thread Starter

Iannis Zannos

Joined Jun 10, 2018

I am trying to get data on a feather huzzah ESP8266 from a BNO055 absolute orientation sensor,
using Adafruits own in-house library for that sensor, adafruit_bno055.
I get the error described below when I try to access the sensor from the code described in
Below is a complete transcript of the code that I used and the error that I got.

I am using circuit python and have the modules required on the board.
The code posted below recognizes that there is an i2c device connected and posts as array of addresses:


However, when I try to create an instance of BNO055 in python, I get an error. I.e.:

sensor = adafruit_bno055.BNO055(i2c)

Gives the error:

Traceback (most recent call last):
File "<stdin>", line 1, in <module>
File "", line 123, in __init__
File "", line 144, in _read_register
File "", line 143, in _read_register
File "adafruit_bus_device/", line 102, in write
OSError: [Errno 5] EIO

Can someone please help me solve this problem?
Present hardware is an essential part of the project, therefore I would appreciate any help.

Iannis Zannos

======== CODE USED =========
import board
print("board imported, next importing bitbangio")
import bitbangio
print("imported bitbangio, next importing adafruit_bno055")
import adafruit_bno055
print("imported adafruit_bno055, will try to connect i2c, in 1 sec.")
print("trying bitbangio.I2C now")
i2c = bitbangio.I2C(board.SCL, board.SDA)
# Following failed. Trying scan instead
# print("done, now getting sensor instance")
# sensor = adafruit_bno055.BNO055(i2c)
# print("done")
print("done, now importing machine")
import machine
print("done, now getting I2C instance")
i2c = machine.I2C(scl=machine.Pin(5), sda=machine.Pin(4))
print("done, now scanning i2c instance")
i2caddreses = i2c.scan()
print("i2c addresses are:")

Posts: 4
Joined: Sun Jun 10, 2018 11:02 am


Joined Jul 7, 2017
I'm not familiar with those particular Adafruit products - but I have found the forum on the Adafruit site to be magnificent. They have always helped me out promptly.

Good luck.