Dual BNO086 over SPI (ESP32-S3 plus) One sensor fails init when both connected

Hi everyone,

I’m working on a wearable embedded system using two SparkFun BNO086 IMUs connected to an ESP32-S3 (XIAO ESP32-S3) over SPI, and I’m running into a persistent issue when both sensors are connected simultaneously.

System Overview

  • MCU: ESP32-S3 (dual-core, SPI2 bus)

  • Sensors: 2 × SparkFun BNO086 (Qwiic breakout)

  • Interface: SPI (shared bus)

SPI configuration

Shared:

  • SCK: GPIO7

  • MISO: GPIO8

  • MOSI: GPIO9

Per sensor:

  • IMU1 → CS=GPIO3, INT=GPIO4, RST=GPIO43

  • IMU2 → CS=GPIO5, INT=GPIO6, RST=GPIO44

Problem Description

Each IMU works perfectly individually.

However, when both are connected:

  • THIGH initializes successfully

  • SHIN fails during beginSPI() very quickly (~30 ms)

What I Already Tried

1. Proper SPI initialization sequence

  • CS pins set HIGH before SPI.begin()

  • Both sensors reset simultaneously:

    • RST LOW → 50 ms → RST HIGH → wait 200 ms

2. Bus isolation logic

Before initializing each sensor:

  • Verified other sensor CS is HIGH

  • Added debug logs to confirm

3. Inter-sensor delay

  • Added 150 ms delay between initializing THIGH and SHIN

4. Verified SPI mode configuration

  • PS0 and PS1 are soldered HIGH on both sensors (SPI mode confirmed)

-Has anyone successfully run two BNO086 sensors on the same SPI bus?
-Is SPI officially recommended over I2C for multi-sensor setups in dynamic/wearable environments?

-Any known hardware quirks when using multiple BNO08x devices together?

Thanks



It could be a few things…

Check out Option #1 here to attempt separating out the 2 SPI buses ; there is also a suggested diagnostic near the very end to test for potential MISO contention

Here’s the main change suggested: