From b782d24f8749bf900de0c2b841c2607fb9027ad6 Mon Sep 17 00:00:00 2001 From: richaravoil Date: Wed, 12 Jun 2024 17:15:49 +0200 Subject: [PATCH] ArduCopter: get MAV_STATE_BOOT on reboot Co-authored-by: Peter Hall <33176108+IamPete1@users.noreply.github.com> --- ArduCopter/GCS_Mavlink.cpp | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/ArduCopter/GCS_Mavlink.cpp b/ArduCopter/GCS_Mavlink.cpp index b1eaaa0fdd020..1946f95068e6b 100644 --- a/ArduCopter/GCS_Mavlink.cpp +++ b/ArduCopter/GCS_Mavlink.cpp @@ -89,6 +89,10 @@ MAV_STATE GCS_MAVLINK_Copter::vehicle_system_status() const return MAV_STATE_STANDBY; } + if (!copter.ap.initialised) { + return MAV_STATE_BOOT; + } + return MAV_STATE_ACTIVE; }