From e567cca230c7228210442e20d97c4482270259c4 Mon Sep 17 00:00:00 2001 From: Peter Barker Date: Thu, 18 Mar 2021 10:26:07 +1100 Subject: [PATCH] autotest: drain mav before receiving system_time in get_sim_time --- Tools/autotest/common.py | 1 + 1 file changed, 1 insertion(+) diff --git a/Tools/autotest/common.py b/Tools/autotest/common.py index b2cba09b3b..43fed46194 100644 --- a/Tools/autotest/common.py +++ b/Tools/autotest/common.py @@ -2673,6 +2673,7 @@ class AutoTest(ABC): ################################################# def get_sim_time(self, timeout=60): """Get SITL time in seconds.""" + self.drain_mav() m = self.mav.recv_match(type='SYSTEM_TIME', blocking=True, timeout=timeout) if m is None: raise AutoTestTimeoutException("Did not get SYSTEM_TIME message after %f seconds" % timeout)