To allow the BNO055 to be used with the Raspberry Pi I found that the answer is to disable the standard Raspberry Pi i2c hardware entirely, replacing it with a software based i2c device already present in the kernel by using a device tree overlay. This software based i2c device correctly implements the i2c protocol clock stretching. Once this is done there no longer any need to worry about clock speed when communicating with the BNO055 from the Raspberry Pi. You will be able to read heading, roll and pitch data from the BNO055 via i2c at 10ms intervals without any problems. For full details of the procedure please see https://gps-pie.com/pi_i2c_config.htm
I'm using a STM32L4 MCU to connect BNO055 using I2C interface.
The MCU is configured in Fast Mode at 400kHz and the communication is working fine.
The BNO055 operation mode is set to NDOF_FMC_OFF and I am getting the Quaternion data (8 bytes).
However when I make a multibyte read I verify that there is a clock stretching around 180us.
Is this normal?
The transfer of a BYTE+ACK takes only 22.5us (9 bits at 400kHz) and after there is a delay of 180us until it starts the transfer of the next byte.
Getting the 8 byte Quaternion data is taking more than 2ms!!!
Can you help on this subject?
Is this normal?
With BNO055, there is a microcontroller between your host and the underlying sensors. This microcontroller mutch fetch the data you requested via register address before it can send it out.
We have an upcoming updated firmware for the BNO055 with optimization to reduce this clock streching effect. But before you ask, unfortunately I cannot comment on timeline for this new firmware release. Keep posted, I will definitely announce it in the forums when available.