feat(driver): autodetect IMU, add support for SC7U22#7191
Merged
Conversation
Collaborator
Author
|
I'll work with Raph on this over the week end, we want to improve it |
08e15ce to
7a098ca
Compare
Introduce etx_imu_driver_t/etx_imu_t structs separating driver interface (init/read) from I2C configuration (bus/addr). Board provides an array of candidates iterated by generic imuDetect(), following the gimbalsDetect() pattern. Drivers output raw sensor data via etx_imu_data_t struct; filtering is done generically in gyro.cpp. Replace Gyro class with C-style functions consistent with the rest of the codebase. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com> # Conflicts: # radio/src/drivers/icm42607C.h
Move lsm6ds_driver.cpp from targets/common/arm/stm32/ to drivers/ alongside the other IMU drivers. Move imu.cpp to hal/. Convert all three IMU drivers (ICM42607C, SC7U22, LSM6DS) to use HAL i2c_read/ i2c_write instead of stm32-specific I2C functions. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
de901e5 to
b136fa7
Compare
b136fa7 to
8360359
Compare
Collaborator
Author
|
Retested ok on existing radio and test hardware. Would be nice to test on x12s, xlites, but shouldn't defer merge imho |
Member
|
I'll see if the x12s user is still around otherwise "community supported" - speak up or we don't know about it - applies 🤪 |
Member
|
pfeerick
pushed a commit
that referenced
this pull request
Mar 27, 2026
Co-authored-by: raphaelcoeffic <1050031+raphaelcoeffic@users.noreply.github.com> Co-authored-by: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
This adds generic support for IMU SC7U22 and adds auto detection for RM H7 radios
Review all gyro handling.
needed in 2.12 too