Automatically detect FlySky digital hall sticks on X10-class radios without necessity of build-time CMake option FLYSKY_HALL_STICKS.
Added special UART4 init to sample if FlySky sticks are present or not. Added boolean globalData.flyskygimbals to save the detection result. Removed FLYSKY_HALL_STICKS and FLYSKY_HALL_STICKS_REVERSE CMake build options. Tested on two RM TX16S radios, one with FlySky digital hall sticks and second with stock analog sticks.
This commit is contained in:
@@ -398,14 +398,6 @@ if(FRSKY_STICKS)
|
||||
add_definitions(-DFRSKY_STICKS)
|
||||
endif()
|
||||
|
||||
if(FLYSKY_HALL_STICKS)
|
||||
add_definitions(-DFLYSKY_HALL_STICKS)
|
||||
endif()
|
||||
|
||||
if(FLYSKY_HALL_STICKS_REVERSE)
|
||||
add_definitions(-DFLYSKY_HALL_STICKS_REVERSE)
|
||||
endif()
|
||||
|
||||
if(IMU_LSM6DS33)
|
||||
add_definitions(-DIMU_LSM6DS33)
|
||||
endif()
|
||||
|
||||
Reference in New Issue
Block a user