From 63b0aa18d5931bbe7ae0671f7d3016549f7738e1 Mon Sep 17 00:00:00 2001 From: Mark Haslinghuis Date: Thu, 15 Aug 2024 23:13:40 +0200 Subject: [PATCH] [4.5.2] FIX: telemetry for Spektrum/SRXL (#13814) (#13820) Fix telemetry for Spektrum/SRXL (#13814) * Fix telemetry for Spektrum/SRXL * Update after ledvinap review * Update comments --- src/main/target/common_post.h | 6 +++--- src/main/target/common_pre.h | 4 ++-- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/src/main/target/common_post.h b/src/main/target/common_post.h index 0b2ad4c6e2..459aa42f5b 100644 --- a/src/main/target/common_post.h +++ b/src/main/target/common_post.h @@ -265,8 +265,8 @@ #undef USE_TELEMETRY_IBUS_EXTENDED #endif -// If USE_SERIALRX_SPEKTRUM was dropped by a target, drop all related options -#ifndef USE_SERIALRX_SPEKTRUM +// If USE_SERIALRX_SPEKTRUM or SERIALRX_SRXL2 was dropped by a target, drop all related options +#if !defined(USE_SERIALRX_SPEKTRUM) && !defined(USE_SERIALRX_SRXL2) #undef USE_SPEKTRUM_BIND #undef USE_SPEKTRUM_BIND_PLUG #undef USE_SPEKTRUM_REAL_RSSI @@ -275,7 +275,7 @@ #undef USE_SPEKTRUM_VTX_CONTROL #undef USE_SPEKTRUM_VTX_TELEMETRY #undef USE_TELEMETRY_SRXL -#endif +#endif // !defined(USE_SERIALRX_SPEKTRUM) && !defined(USE_SERIALRX_SRXL2) #if !defined(USE_CMS) || !defined(USE_TELEMETRY_SRXL) #undef USE_SPEKTRUM_CMS_TELEMETRY diff --git a/src/main/target/common_pre.h b/src/main/target/common_pre.h index 6ccd25212f..c05d5b856d 100644 --- a/src/main/target/common_pre.h +++ b/src/main/target/common_pre.h @@ -327,7 +327,7 @@ #define USE_THRUST_LINEARIZATION #define USE_TPA_MODE -#ifdef USE_SERIALRX_SPEKTRUM +#if defined(USE_SERIALRX_SPEKTRUM) || defined(USE_SERIALRX_SRXL2) #define USE_SPEKTRUM_BIND #define USE_SPEKTRUM_BIND_PLUG #define USE_SPEKTRUM_REAL_RSSI @@ -336,7 +336,7 @@ #define USE_SPEKTRUM_VTX_CONTROL #define USE_SPEKTRUM_VTX_TELEMETRY #define USE_SPEKTRUM_CMS_TELEMETRY -#endif // USE_SERIALRX_SPEKTRUM +#endif // defined(USE_SERIALRX_SPEKTRUM) || defined USE_SERIALRX_SRXL2 #define USE_BOARD_INFO #define USE_RTC_TIME