Adafruit_CircuitPython_BNO055
Adafruit_CircuitPython_BNO055 copied to clipboard
Try to do error recovery and make library more robust on mimxrt1011 and other chip families.
BNO055 gets errors running on i.MX RT1011, but this does not seem to be due to something wrong with the CircuitPython i.MX I2C implementation. Instead it is due to I2C protocol violations by the BNO055. The BNO055 works better with SAMD and RP2040.
I did some testing, with this or similar:
import board, adafruit_bno055, busio
import time
i2c = board.STEMMA_I2C()
b = adafruit_bno055.BNO055_I2C(i2c)
while True:
print(b.quaternion)
time.sleep(1)
- SAMD21: library too large
- SAMD51: fine
- RP2040: fine
- ESP32-S2: fine
- nRF52840: fine
- STM32F4: fine
- ESP32-S3: Gets
ETIMEDOUT
immediately - ESP32: can't even find the sensor on the I2C bus
- RT1011: fails with an
OSError
Input/Output error after only a few cycles.