Browse Source

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.
c415-sdk
Peter Barker 4 years ago committed by Peter Barker
parent
commit
79de738266
  1. 2
      Tools/autotest/common.py

2
Tools/autotest/common.py

@ -5397,6 +5397,8 @@ class AutoTest(ABC): @@ -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

Loading…
Cancel
Save