diff --git a/libraries/AP_HAL/AP_HAL_Boards.h b/libraries/AP_HAL/AP_HAL_Boards.h index c689a46905..b9cb51bbf9 100644 --- a/libraries/AP_HAL/AP_HAL_Boards.h +++ b/libraries/AP_HAL/AP_HAL_Boards.h @@ -302,12 +302,8 @@ #endif #ifndef HAL_SERIAL_ESC_COMM_ENABLED -#ifdef DISABLE_SERIAL_ESC_COMM -#define HAL_SERIAL_ESC_COMM_ENABLED 0 -#else #define HAL_SERIAL_ESC_COMM_ENABLED 1 #endif -#endif #ifndef AP_BOOTLOADER_FLASHING_ENABLED #define AP_BOOTLOADER_FLASHING_ENABLED 0 diff --git a/libraries/AP_HAL_ChibiOS/hwdef/BirdCANdy/hwdef.dat b/libraries/AP_HAL_ChibiOS/hwdef/BirdCANdy/hwdef.dat index f1022a0409..85ac354b42 100644 --- a/libraries/AP_HAL_ChibiOS/hwdef/BirdCANdy/hwdef.dat +++ b/libraries/AP_HAL_ChibiOS/hwdef/BirdCANdy/hwdef.dat @@ -84,7 +84,6 @@ define HAL_NO_GPIO_IRQ define HAL_NO_RCIN_THREAD define HAL_USE_RTC FALSE -define DISABLE_SERIAL_ESC_COMM TRUE define DMA_RESERVE_SIZE 0 diff --git a/libraries/AP_HAL_ChibiOS/hwdef/CUAV_GPS/hwdef.dat b/libraries/AP_HAL_ChibiOS/hwdef/CUAV_GPS/hwdef.dat index 1f70814fc6..edd84d437a 100644 --- a/libraries/AP_HAL_ChibiOS/hwdef/CUAV_GPS/hwdef.dat +++ b/libraries/AP_HAL_ChibiOS/hwdef/CUAV_GPS/hwdef.dat @@ -114,7 +114,6 @@ define HAL_NO_GPIO_IRQ define HAL_NO_RCIN_THREAD define HAL_USE_RTC FALSE -define DISABLE_SERIAL_ESC_COMM TRUE define DMA_RESERVE_SIZE 0 diff --git a/libraries/AP_HAL_ChibiOS/hwdef/CubeBlack-periph/hwdef.dat b/libraries/AP_HAL_ChibiOS/hwdef/CubeBlack-periph/hwdef.dat index 9de8b26907..e402abdc39 100644 --- a/libraries/AP_HAL_ChibiOS/hwdef/CubeBlack-periph/hwdef.dat +++ b/libraries/AP_HAL_ChibiOS/hwdef/CubeBlack-periph/hwdef.dat @@ -40,7 +40,6 @@ define HAL_NO_MONITOR_THREAD define HAL_DISABLE_LOOP_DELAY define HAL_USE_RTC FALSE -define DISABLE_SERIAL_ESC_COMM TRUE define HAL_NO_RCIN_THREAD diff --git a/libraries/AP_HAL_ChibiOS/hwdef/CubeOrange-periph-heavy/hwdef.dat b/libraries/AP_HAL_ChibiOS/hwdef/CubeOrange-periph-heavy/hwdef.dat index 5c91b7bd2a..c3a699ce25 100644 --- a/libraries/AP_HAL_ChibiOS/hwdef/CubeOrange-periph-heavy/hwdef.dat +++ b/libraries/AP_HAL_ChibiOS/hwdef/CubeOrange-periph-heavy/hwdef.dat @@ -37,7 +37,6 @@ define HAL_NO_MONITOR_THREAD define HAL_DISABLE_LOOP_DELAY define HAL_USE_RTC FALSE -define DISABLE_SERIAL_ESC_COMM TRUE define HAL_GCS_ENABLED 1 diff --git a/libraries/AP_HAL_ChibiOS/hwdef/CubeOrange-periph/hwdef.dat b/libraries/AP_HAL_ChibiOS/hwdef/CubeOrange-periph/hwdef.dat index 8aef94756f..4b96a92fa3 100644 --- a/libraries/AP_HAL_ChibiOS/hwdef/CubeOrange-periph/hwdef.dat +++ b/libraries/AP_HAL_ChibiOS/hwdef/CubeOrange-periph/hwdef.dat @@ -36,7 +36,6 @@ define HAL_NO_MONITOR_THREAD define HAL_DISABLE_LOOP_DELAY define HAL_USE_RTC FALSE -define DISABLE_SERIAL_ESC_COMM TRUE define HAL_NO_RCIN_THREAD diff --git a/libraries/AP_HAL_ChibiOS/hwdef/CubePilot-CANMod/hwdef.dat b/libraries/AP_HAL_ChibiOS/hwdef/CubePilot-CANMod/hwdef.dat index 965cd4462c..4a5f1f780e 100644 --- a/libraries/AP_HAL_ChibiOS/hwdef/CubePilot-CANMod/hwdef.dat +++ b/libraries/AP_HAL_ChibiOS/hwdef/CubePilot-CANMod/hwdef.dat @@ -75,7 +75,6 @@ define HAL_PERIPH_ENABLE_NETWORKING # --------------------------------------------------------------------------------------------- # AP_Periph - boiler-plate configurations that all HW AP-Periph need # --------------------------------------------------------------------------------------------- -define DISABLE_SERIAL_ESC_COMM TRUE define HAL_NO_RCIN_THREAD #define HAL_NO_GPIO_IRQ define HAL_DISABLE_LOOP_DELAY diff --git a/libraries/AP_HAL_ChibiOS/hwdef/CubeRedPrimary-PPPGW/hwdef.dat b/libraries/AP_HAL_ChibiOS/hwdef/CubeRedPrimary-PPPGW/hwdef.dat index b718f762d5..efd0f628e9 100644 --- a/libraries/AP_HAL_ChibiOS/hwdef/CubeRedPrimary-PPPGW/hwdef.dat +++ b/libraries/AP_HAL_ChibiOS/hwdef/CubeRedPrimary-PPPGW/hwdef.dat @@ -27,7 +27,6 @@ define HAL_NO_MONITOR_THREAD define HAL_DISABLE_LOOP_DELAY define HAL_USE_RTC FALSE -define DISABLE_SERIAL_ESC_COMM TRUE define HAL_NO_RCIN_THREAD diff --git a/libraries/AP_HAL_ChibiOS/hwdef/H757I_EVAL/hwdef.dat b/libraries/AP_HAL_ChibiOS/hwdef/H757I_EVAL/hwdef.dat index 76f8c205a8..fb1542badd 100644 --- a/libraries/AP_HAL_ChibiOS/hwdef/H757I_EVAL/hwdef.dat +++ b/libraries/AP_HAL_ChibiOS/hwdef/H757I_EVAL/hwdef.dat @@ -64,7 +64,6 @@ define HAL_DISABLE_ADC_DRIVER TRUE # avoid timer and RCIN threads to save memory define HAL_NO_RCIN_THREAD define HAL_NO_GPIO_IRQ -define DISABLE_SERIAL_ESC_COMM TRUE PB13 VBUS INPUT OPENDRAIN diff --git a/libraries/AP_HAL_ChibiOS/hwdef/H757I_EVAL_intf/hwdef.dat b/libraries/AP_HAL_ChibiOS/hwdef/H757I_EVAL_intf/hwdef.dat index 62b9ed8a67..88990faa62 100644 --- a/libraries/AP_HAL_ChibiOS/hwdef/H757I_EVAL_intf/hwdef.dat +++ b/libraries/AP_HAL_ChibiOS/hwdef/H757I_EVAL_intf/hwdef.dat @@ -64,7 +64,6 @@ define HAL_DISABLE_ADC_DRIVER TRUE # avoid timer and RCIN threads to save memory define HAL_NO_RCIN_THREAD define HAL_NO_GPIO_IRQ -define DISABLE_SERIAL_ESC_COMM TRUE PB13 VBUS INPUT OPENDRAIN diff --git a/libraries/AP_HAL_ChibiOS/hwdef/HitecMosaic/hwdef.dat b/libraries/AP_HAL_ChibiOS/hwdef/HitecMosaic/hwdef.dat index 39c899e583..aa099ecc0d 100644 --- a/libraries/AP_HAL_ChibiOS/hwdef/HitecMosaic/hwdef.dat +++ b/libraries/AP_HAL_ChibiOS/hwdef/HitecMosaic/hwdef.dat @@ -78,7 +78,6 @@ define SERIAL_BUFFERS_SIZE 512 define HAL_NO_RCIN_THREAD define HAL_USE_RTC FALSE -define DISABLE_SERIAL_ESC_COMM TRUE define DMA_RESERVE_SIZE 0 diff --git a/libraries/AP_HAL_ChibiOS/hwdef/HolybroG4_Compass/hwdef.dat b/libraries/AP_HAL_ChibiOS/hwdef/HolybroG4_Compass/hwdef.dat index f5c891c495..844ab6d863 100644 --- a/libraries/AP_HAL_ChibiOS/hwdef/HolybroG4_Compass/hwdef.dat +++ b/libraries/AP_HAL_ChibiOS/hwdef/HolybroG4_Compass/hwdef.dat @@ -79,7 +79,6 @@ define HAL_NO_GPIO_IRQ define HAL_NO_RCIN_THREAD define HAL_USE_RTC FALSE -define DISABLE_SERIAL_ESC_COMM TRUE define DMA_RESERVE_SIZE 0 diff --git a/libraries/AP_HAL_ChibiOS/hwdef/HolybroG4_GPS/hwdef.dat b/libraries/AP_HAL_ChibiOS/hwdef/HolybroG4_GPS/hwdef.dat index 4d1bcf8c2f..c8ace8acb2 100644 --- a/libraries/AP_HAL_ChibiOS/hwdef/HolybroG4_GPS/hwdef.dat +++ b/libraries/AP_HAL_ChibiOS/hwdef/HolybroG4_GPS/hwdef.dat @@ -102,7 +102,6 @@ define HAL_NO_GPIO_IRQ define HAL_NO_RCIN_THREAD define HAL_USE_RTC FALSE -define DISABLE_SERIAL_ESC_COMM TRUE define DMA_RESERVE_SIZE 0 diff --git a/libraries/AP_HAL_ChibiOS/hwdef/HolybroGPS/hwdef.dat b/libraries/AP_HAL_ChibiOS/hwdef/HolybroGPS/hwdef.dat index bbf9342417..544c1d6a98 100644 --- a/libraries/AP_HAL_ChibiOS/hwdef/HolybroGPS/hwdef.dat +++ b/libraries/AP_HAL_ChibiOS/hwdef/HolybroGPS/hwdef.dat @@ -119,7 +119,6 @@ define HAL_NO_GPIO_IRQ define HAL_NO_RCIN_THREAD define HAL_USE_RTC FALSE -define DISABLE_SERIAL_ESC_COMM TRUE define DMA_RESERVE_SIZE 0 diff --git a/libraries/AP_HAL_ChibiOS/hwdef/MatekH743-periph/hwdef.dat b/libraries/AP_HAL_ChibiOS/hwdef/MatekH743-periph/hwdef.dat index e4195fdc27..1d23a70bc3 100644 --- a/libraries/AP_HAL_ChibiOS/hwdef/MatekH743-periph/hwdef.dat +++ b/libraries/AP_HAL_ChibiOS/hwdef/MatekH743-periph/hwdef.dat @@ -43,7 +43,6 @@ define HAL_PERIPH_ADSB_BAUD_DEFAULT 0 define HAL_NO_MONITOR_THREAD define HAL_DISABLE_LOOP_DELAY define HAL_USE_RTC FALSE -#define DISABLE_SERIAL_ESC_COMM TRUE define HAL_NO_RCIN_THREAD diff --git a/libraries/AP_HAL_ChibiOS/hwdef/Pixhawk6X-PPPGW/hwdef.dat b/libraries/AP_HAL_ChibiOS/hwdef/Pixhawk6X-PPPGW/hwdef.dat index f2db5f6038..d9077e22aa 100644 --- a/libraries/AP_HAL_ChibiOS/hwdef/Pixhawk6X-PPPGW/hwdef.dat +++ b/libraries/AP_HAL_ChibiOS/hwdef/Pixhawk6X-PPPGW/hwdef.dat @@ -28,7 +28,6 @@ define HAL_NO_MONITOR_THREAD define HAL_DISABLE_LOOP_DELAY define HAL_USE_RTC FALSE -define DISABLE_SERIAL_ESC_COMM TRUE define HAL_NO_RCIN_THREAD diff --git a/libraries/AP_HAL_ChibiOS/hwdef/Pixracer-periph/hwdef.dat b/libraries/AP_HAL_ChibiOS/hwdef/Pixracer-periph/hwdef.dat index 7b4acfe486..7b0575cffd 100644 --- a/libraries/AP_HAL_ChibiOS/hwdef/Pixracer-periph/hwdef.dat +++ b/libraries/AP_HAL_ChibiOS/hwdef/Pixracer-periph/hwdef.dat @@ -40,7 +40,6 @@ define HAL_NO_MONITOR_THREAD define HAL_DISABLE_LOOP_DELAY define HAL_USE_RTC FALSE -define DISABLE_SERIAL_ESC_COMM TRUE define HAL_NO_RCIN_THREAD diff --git a/libraries/AP_HAL_ChibiOS/hwdef/Sierra-F405/hwdef.dat b/libraries/AP_HAL_ChibiOS/hwdef/Sierra-F405/hwdef.dat index 5fe3d9b3f9..9083cfba9c 100644 --- a/libraries/AP_HAL_ChibiOS/hwdef/Sierra-F405/hwdef.dat +++ b/libraries/AP_HAL_ChibiOS/hwdef/Sierra-F405/hwdef.dat @@ -39,7 +39,6 @@ define DMA_RESERVE_SIZE 0 define HAL_DISABLE_LOOP_DELAY define HAL_NO_MONITOR_THREAD -define DISABLE_SERIAL_ESC_COMM TRUE define HAL_DEVICE_THREAD_STACK 768 diff --git a/libraries/AP_HAL_ChibiOS/hwdef/Sierra-F412/hwdef.dat b/libraries/AP_HAL_ChibiOS/hwdef/Sierra-F412/hwdef.dat index 1e8df2f261..d847d8cf7c 100644 --- a/libraries/AP_HAL_ChibiOS/hwdef/Sierra-F412/hwdef.dat +++ b/libraries/AP_HAL_ChibiOS/hwdef/Sierra-F412/hwdef.dat @@ -87,7 +87,6 @@ define HAL_NO_GPIO_IRQ # avoid RCIN thread to save memory define HAL_NO_RCIN_THREAD define HAL_USE_RTC FALSE -define DISABLE_SERIAL_ESC_COMM TRUE define DMA_RESERVE_SIZE 0 define PERIPH_FW TRUE define HAL_DISABLE_LOOP_DELAY diff --git a/libraries/AP_HAL_ChibiOS/hwdef/Sierra-F9P/hwdef.dat b/libraries/AP_HAL_ChibiOS/hwdef/Sierra-F9P/hwdef.dat index e8096fd5c1..91ca84448d 100644 --- a/libraries/AP_HAL_ChibiOS/hwdef/Sierra-F9P/hwdef.dat +++ b/libraries/AP_HAL_ChibiOS/hwdef/Sierra-F9P/hwdef.dat @@ -98,7 +98,6 @@ define HAL_NO_GPIO_IRQ # avoid RCIN thread to save memory define HAL_NO_RCIN_THREAD define HAL_USE_RTC TRUE -define DISABLE_SERIAL_ESC_COMM TRUE define DMA_RESERVE_SIZE 0 define HAL_DISABLE_LOOP_DELAY define PERIPH_FW TRUE diff --git a/libraries/AP_HAL_ChibiOS/hwdef/ZubaxGNSS/hwdef.dat b/libraries/AP_HAL_ChibiOS/hwdef/ZubaxGNSS/hwdef.dat index fb747418cf..5212c3db57 100644 --- a/libraries/AP_HAL_ChibiOS/hwdef/ZubaxGNSS/hwdef.dat +++ b/libraries/AP_HAL_ChibiOS/hwdef/ZubaxGNSS/hwdef.dat @@ -101,7 +101,6 @@ define HAL_NO_RCIN_THREAD define __FPU_PRESENT 0 define HAL_USE_RTC FALSE -define DISABLE_SERIAL_ESC_COMM TRUE define DMA_RESERVE_SIZE 0 diff --git a/libraries/AP_HAL_ChibiOS/hwdef/f103-periph/hwdef.inc b/libraries/AP_HAL_ChibiOS/hwdef/f103-periph/hwdef.inc index 33cef35688..4cb0c0046f 100644 --- a/libraries/AP_HAL_ChibiOS/hwdef/f103-periph/hwdef.inc +++ b/libraries/AP_HAL_ChibiOS/hwdef/f103-periph/hwdef.inc @@ -70,7 +70,6 @@ define HAL_NO_RCIN_THREAD define __FPU_PRESENT 0 define HAL_USE_RTC FALSE -define DISABLE_SERIAL_ESC_COMM TRUE define DMA_RESERVE_SIZE 0 diff --git a/libraries/AP_HAL_ChibiOS/hwdef/f303-MatekGPS/hwdef.dat b/libraries/AP_HAL_ChibiOS/hwdef/f303-MatekGPS/hwdef.dat index 5fbe6af4be..54527bce14 100644 --- a/libraries/AP_HAL_ChibiOS/hwdef/f303-MatekGPS/hwdef.dat +++ b/libraries/AP_HAL_ChibiOS/hwdef/f303-MatekGPS/hwdef.dat @@ -49,7 +49,6 @@ define PORT_INT_REQUIRED_STACK 64 define HAL_NO_RCIN_THREAD define HAL_USE_RTC FALSE -define DISABLE_SERIAL_ESC_COMM TRUE define DMA_RESERVE_SIZE 0 diff --git a/libraries/AP_HAL_ChibiOS/hwdef/f303-periph/hwdef.inc b/libraries/AP_HAL_ChibiOS/hwdef/f303-periph/hwdef.inc index 68674e6b6e..0203f3e1ab 100644 --- a/libraries/AP_HAL_ChibiOS/hwdef/f303-periph/hwdef.inc +++ b/libraries/AP_HAL_ChibiOS/hwdef/f303-periph/hwdef.inc @@ -70,7 +70,6 @@ define HAL_NO_RCIN_THREAD define HAL_NO_RCOUT_THREAD define HAL_USE_RTC FALSE -define DISABLE_SERIAL_ESC_COMM TRUE define DMA_RESERVE_SIZE 0 diff --git a/libraries/AP_HAL_ChibiOS/hwdef/f405-MatekGPS/hwdef.dat b/libraries/AP_HAL_ChibiOS/hwdef/f405-MatekGPS/hwdef.dat index 6ac2a044f7..24b5e915e7 100644 --- a/libraries/AP_HAL_ChibiOS/hwdef/f405-MatekGPS/hwdef.dat +++ b/libraries/AP_HAL_ChibiOS/hwdef/f405-MatekGPS/hwdef.dat @@ -43,7 +43,6 @@ define PORT_INT_REQUIRED_STACK 64 define HAL_NO_RCIN_THREAD define HAL_USE_RTC FALSE -define DISABLE_SERIAL_ESC_COMM TRUE define DMA_RESERVE_SIZE 0 diff --git a/libraries/AP_HAL_ChibiOS/hwdef/iomcu/hwdef.inc b/libraries/AP_HAL_ChibiOS/hwdef/iomcu/hwdef.inc index 0e66cf8a3a..99decb45db 100644 --- a/libraries/AP_HAL_ChibiOS/hwdef/iomcu/hwdef.inc +++ b/libraries/AP_HAL_ChibiOS/hwdef/iomcu/hwdef.inc @@ -120,7 +120,6 @@ define __FPU_PRESENT 0 define HAL_USE_RTC FALSE define HAL_NO_FLASH_SUPPORT TRUE define HAL_NO_UARTDRIVER TRUE -define DISABLE_SERIAL_ESC_COMM TRUE define HAL_LOGGING_ENABLED 0 define DMA_RESERVE_SIZE 0 diff --git a/libraries/AP_HAL_ChibiOS/hwdef/kha_eth/hwdef.dat b/libraries/AP_HAL_ChibiOS/hwdef/kha_eth/hwdef.dat index fa1157f699..0e5f16d6f6 100644 --- a/libraries/AP_HAL_ChibiOS/hwdef/kha_eth/hwdef.dat +++ b/libraries/AP_HAL_ChibiOS/hwdef/kha_eth/hwdef.dat @@ -131,7 +131,6 @@ define HAL_DISABLE_ADC_DRIVER TRUE # --------------------------------------------------------------------------------------------- # AP_Periph - boiler-plate configurations that all HW AP-Periph need # --------------------------------------------------------------------------------------------- -define DISABLE_SERIAL_ESC_COMM TRUE define HAL_NO_RCIN_THREAD #define HAL_NO_GPIO_IRQ define HAL_DISABLE_LOOP_DELAY diff --git a/libraries/AP_HAL_ChibiOS/hwdef/rGNSS/hwdef.dat b/libraries/AP_HAL_ChibiOS/hwdef/rGNSS/hwdef.dat index 514dabe0eb..2cb0aad262 100644 --- a/libraries/AP_HAL_ChibiOS/hwdef/rGNSS/hwdef.dat +++ b/libraries/AP_HAL_ChibiOS/hwdef/rGNSS/hwdef.dat @@ -96,7 +96,6 @@ define HAL_NO_GPIO_IRQ define HAL_NO_RCIN_THREAD define HAL_USE_RTC FALSE -define DISABLE_SERIAL_ESC_COMM TRUE define DMA_RESERVE_SIZE 0 diff --git a/libraries/AP_HAL_ChibiOS/hwdef/scripts/defaults_periph.h b/libraries/AP_HAL_ChibiOS/hwdef/scripts/defaults_periph.h index 1ac7ab88ec..31ccf363ad 100644 --- a/libraries/AP_HAL_ChibiOS/hwdef/scripts/defaults_periph.h +++ b/libraries/AP_HAL_ChibiOS/hwdef/scripts/defaults_periph.h @@ -317,6 +317,10 @@ #define AP_SCRIPTING_ENABLED 0 #endif +#ifndef HAL_SERIAL_ESC_COMM_ENABLED +#define HAL_SERIAL_ESC_COMM_ENABLED 0 +#endif + #ifndef HAL_WITH_ESC_TELEM #define HAL_WITH_ESC_TELEM 0 #endif