From aca1651488d3f94bdc0b4d9b6652205f326e1654 Mon Sep 17 00:00:00 2001 From: yaapu Date: Thu, 21 Mar 2019 15:54:39 +0100 Subject: [PATCH] AP_Frsky_Telem: fix ap_status_timer handling method should return only after ap_status_timer has elapsed and vehicle is initialized otherwise we waste a chance to send a packet --- libraries/AP_Frsky_Telem/AP_Frsky_Telem.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/libraries/AP_Frsky_Telem/AP_Frsky_Telem.cpp b/libraries/AP_Frsky_Telem/AP_Frsky_Telem.cpp index 0a4f6309f4..13312d3e5d 100644 --- a/libraries/AP_Frsky_Telem/AP_Frsky_Telem.cpp +++ b/libraries/AP_Frsky_Telem/AP_Frsky_Telem.cpp @@ -118,8 +118,8 @@ void AP_Frsky_Telem::send_SPort_Passthrough(void) if (gcs().vehicle_initialised()) { // send ap status only once vehicle has been initialised send_uint32(DIY_FIRST_ID+1, calc_ap_status()); _passthrough.ap_status_timer = AP_HAL::millis(); + return; } - return; } if ((now - _passthrough.batt_timer) >= 1000) { send_uint32(DIY_FIRST_ID+3, calc_batt(0));