From c1c438d5bdc708f92a6343cb14be1bfc27a1d3a9 Mon Sep 17 00:00:00 2001 From: Peter Barker Date: Tue, 7 Jan 2025 15:19:14 +1100 Subject: [PATCH] AP_HAL: replace HAL_NO_UARTDRIVER with AP_HAL_UARTDRIVER_ENABLED --- libraries/AP_HAL/AP_HAL_Boards.h | 4 ++++ libraries/AP_HAL/UARTDriver.h | 2 +- 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/libraries/AP_HAL/AP_HAL_Boards.h b/libraries/AP_HAL/AP_HAL_Boards.h index b5dddb89cb..af233e5596 100644 --- a/libraries/AP_HAL/AP_HAL_Boards.h +++ b/libraries/AP_HAL/AP_HAL_Boards.h @@ -206,6 +206,10 @@ #define HAL_WITH_DSP HAL_GYROFFT_ENABLED #endif +#ifndef AP_HAL_UARTDRIVER_ENABLED +#define AP_HAL_UARTDRIVER_ENABLED 1 +#endif + #ifndef HAL_OS_FATFS_IO #define HAL_OS_FATFS_IO 0 #endif diff --git a/libraries/AP_HAL/UARTDriver.h b/libraries/AP_HAL/UARTDriver.h index 317ddd1fba..cf8494f2c9 100644 --- a/libraries/AP_HAL/UARTDriver.h +++ b/libraries/AP_HAL/UARTDriver.h @@ -7,7 +7,7 @@ #include #ifndef HAL_UART_STATS_ENABLED -#define HAL_UART_STATS_ENABLED !defined(HAL_NO_UARTDRIVER) +#define HAL_UART_STATS_ENABLED AP_HAL_UARTDRIVER_ENABLED #endif #ifndef AP_UART_MONITOR_ENABLED