From 3b5395eb2d97ca0b8dcdfe569a5778c692426264 Mon Sep 17 00:00:00 2001 From: Andy Piper Date: Fri, 17 Nov 2023 17:31:21 +0000 Subject: [PATCH] AP_HAL_ChibiOS: fix race condition in sending serial LED data --- libraries/AP_HAL_ChibiOS/RCOutput.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/libraries/AP_HAL_ChibiOS/RCOutput.cpp b/libraries/AP_HAL_ChibiOS/RCOutput.cpp index a7a2e319b4..fd3d5cd81b 100644 --- a/libraries/AP_HAL_ChibiOS/RCOutput.cpp +++ b/libraries/AP_HAL_ChibiOS/RCOutput.cpp @@ -2520,9 +2520,9 @@ void RCOutput::serial_led_send(const uint16_t chan) } if (grp->prepared_send) { - chEvtSignal(led_thread_ctx, EVT_LED_SEND); grp->serial_led_pending = true; serial_led_pending = true; + chEvtSignal(led_thread_ctx, EVT_LED_SEND); } }