From cee45a2fc2ecb0c8a8f5f8b2f98119eca280e510 Mon Sep 17 00:00:00 2001 From: Peter Barker Date: Wed, 7 Aug 2024 13:17:21 +1000 Subject: [PATCH] AP_Radio: use GCS_SEND_TEXT rather than gcs().send_text Co-authored-by: muramura --- libraries/AP_Radio/AP_Radio_bk2425.cpp | 2 +- libraries/AP_Radio/AP_Radio_cc2500.cpp | 2 +- libraries/AP_Radio/AP_Radio_cypress.cpp | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/libraries/AP_Radio/AP_Radio_bk2425.cpp b/libraries/AP_Radio/AP_Radio_bk2425.cpp index 2ed5b64f1b..773205cf88 100644 --- a/libraries/AP_Radio/AP_Radio_bk2425.cpp +++ b/libraries/AP_Radio/AP_Radio_bk2425.cpp @@ -35,7 +35,7 @@ extern const AP_HAL::HAL& hal; // This is for debugging issues with frequency hopping and synchronisation. #define DebugPrintf(level, fmt, args...) do { if (AP_Radio_beken::radio_singleton && ((level) <= AP_Radio_beken::radio_singleton->get_debug_level())) { printf(fmt, ##args); }} while (0) // Output debug information on the mavlink to the UART connected to the WiFi, wrapped in MavLink packets -#define DebugMavlink(level, fmt, args...) do { if ((level) <= get_debug_level()) { gcs().send_text(MAV_SEVERITY_INFO, fmt, ##args); }} while (0) +#define DebugMavlink(level, fmt, args...) do { if ((level) <= get_debug_level()) { GCS_SEND_TEXT(MAV_SEVERITY_INFO, fmt, ##args); }} while (0) #if SUPPORT_BK_DEBUG_PINS diff --git a/libraries/AP_Radio/AP_Radio_cc2500.cpp b/libraries/AP_Radio/AP_Radio_cc2500.cpp index 34ef0eef30..cce9b4ffcf 100644 --- a/libraries/AP_Radio/AP_Radio_cc2500.cpp +++ b/libraries/AP_Radio/AP_Radio_cc2500.cpp @@ -30,7 +30,7 @@ extern const AP_HAL::HAL& hal; -#define Debug(level, fmt, args...) do { if ((level) <= get_debug_level()) { gcs().send_text(MAV_SEVERITY_INFO, fmt, ##args); }} while (0) +#define Debug(level, fmt, args...) do { if ((level) <= get_debug_level()) { GCS_SEND_TEXT(MAV_SEVERITY_INFO, fmt, ##args); }} while (0) // object instance for trampoline AP_Radio_cc2500 *AP_Radio_cc2500::radio_singleton; diff --git a/libraries/AP_Radio/AP_Radio_cypress.cpp b/libraries/AP_Radio/AP_Radio_cypress.cpp index 7d3d2101be..fc27088469 100644 --- a/libraries/AP_Radio/AP_Radio_cypress.cpp +++ b/libraries/AP_Radio/AP_Radio_cypress.cpp @@ -42,7 +42,7 @@ extern const AP_HAL::HAL& hal; -#define Debug(level, fmt, args...) do { if ((level) <= get_debug_level()) { gcs().send_text(MAV_SEVERITY_INFO, fmt, ##args); }} while (0) +#define Debug(level, fmt, args...) do { if ((level) <= get_debug_level()) { GCS_SEND_TEXT(MAV_SEVERITY_INFO, fmt, ##args); }} while (0) #define LP_FIFO_SIZE 16 // Physical data FIFO lengths in Radio