From 79de738266f751aafcffff9bc8618427626a5a75 Mon Sep 17 00:00:00 2001 From: Peter Barker Date: Wed, 9 Jun 2021 12:04:17 +1000 Subject: [PATCH] autotest: wait for a few seconds for arm-failure messages to appear If prearms never come true then we try to arm the vehicle so it tells us what is wrong. Since we no longer push statustexts hard, we have to wait for the reasons to come out at normal clocked rates. --- Tools/autotest/common.py | 2 ++ 1 file changed, 2 insertions(+) diff --git a/Tools/autotest/common.py b/Tools/autotest/common.py index 00318cb72b..a294f2f450 100644 --- a/Tools/autotest/common.py +++ b/Tools/autotest/common.py @@ -5397,6 +5397,8 @@ class AutoTest(ABC): if t2 - tstart > timeout: self.progress("Prearm bit never went true. Attempting arm to elicit reason from autopilot") self.arm_vehicle() + # statustexts are queued; give it a second to arrive: + self.delay_sim_time(5) raise AutoTestTimeoutException("Prearm bit never went true") if self.sensor_has_state(mavutil.mavlink.MAV_SYS_STATUS_PREARM_CHECK, True, True, True): break