Spi support (2) #99

Closed
opened 2026-04-05 17:51:49 +02:00 by MrUnknownDE · 0 comments
Owner

Originally created by @Eirenliel on 4/23/2025

Imagine if we supported SPI twice?

  • Adds another RegisterInterface abstraction layer to communicate with Sensor that can be either I2C or SPI
  • Separates sensor building factory into separte file to reduce clutter
  • Adds support for SPI connection to an IMU, combinding I2C and SPI is also allowed
  • Adds IMU_AUTO imu, which does a search of IMUs on the provided bus and creates the sensor based on what's found
    • Only a few IMU models get checked by default: BNO085, ICM-45686, LSM6DSV and BMI270 - the best ones currently supported and the ones used on official trackers. Adding support for more will inflate the binary size and won't fit into ESP12-F. Maybe if we use less templates, we could fit more in the future.
  • Aligns axelerometer readings to IMU_ROTATION

TODO:

  • Return pinout for SlimeVR board definition back and add new one for SlimeVR v1.2
  • Test ICM-45686 in the CI along with BNO
  • Whatever cleanup @gorbit99 wanted to do
  • Fix MCP23X17 being improssible to build fw with

@loucass003 this PR adds new board definition BOARD_SLIMEVR_V1_2 with new default pinouts and IMU settings. Also the fw builder for BOARD_SLIMEVR should use IMU_AUTO as default instead of IMU_BNO085 now.

*Originally created by @Eirenliel on 4/23/2025* Imagine if we supported SPI twice? * Adds another RegisterInterface abstraction layer to communicate with Sensor that can be either I2C or SPI * Separates sensor building factory into separte file to reduce clutter * Adds support for SPI connection to an IMU, combinding I2C and SPI is also allowed * Adds IMU_AUTO imu, which does a search of IMUs on the provided bus and creates the sensor based on what's found * Only a few IMU models get checked by default: BNO085, ICM-45686, LSM6DSV and BMI270 - the best ones currently supported and the ones used on official trackers. Adding support for more will inflate the binary size and won't fit into ESP12-F. Maybe if we use less templates, we could fit more in the future. * Aligns axelerometer readings to IMU_ROTATION TODO: * [x] Return pinout for SlimeVR board definition back and add new one for SlimeVR v1.2 * [x] Test ICM-45686 in the CI along with BNO * [x] Whatever cleanup @gorbit99 wanted to do * [x] Fix MCP23X17 being improssible to build fw with @loucass003 this PR adds new board definition BOARD_SLIMEVR_V1_2 with new default pinouts and IMU settings. Also the fw builder for BOARD_SLIMEVR should use IMU_AUTO as default instead of IMU_BNO085 now.
Sign in to join this conversation.
No Label
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: github/SlimeVR-Tracker-ESP#99