autotest: make fly_proximity_avoidance_test_alt_no_avoid more reliable
This commit is contained in:
parent
c913d8134d
commit
b5f490aff4
@ -5031,9 +5031,8 @@ class AutoTestCopter(AutoTest):
|
|||||||
while True:
|
while True:
|
||||||
if self.armed():
|
if self.armed():
|
||||||
break
|
break
|
||||||
if self.get_sim_time() - tstart > 60:
|
if self.get_sim_time_cached() - tstart > 60:
|
||||||
raise AutoTestTimeoutException("Did not arm")
|
raise AutoTestTimeoutException("Did not arm")
|
||||||
self.delay_sim_time(0.1)
|
|
||||||
self.mav.mav.distance_sensor_send(
|
self.mav.mav.distance_sensor_send(
|
||||||
0, # time_boot_ms
|
0, # time_boot_ms
|
||||||
10, # min_distance cm
|
10, # min_distance cm
|
||||||
@ -5052,6 +5051,7 @@ class AutoTestCopter(AutoTest):
|
|||||||
0,
|
0,
|
||||||
0,
|
0,
|
||||||
0)
|
0)
|
||||||
|
self.wait_heartbeat()
|
||||||
self.takeoff(15, mode='LOITER')
|
self.takeoff(15, mode='LOITER')
|
||||||
self.progress("Poking vehicle; should avoid")
|
self.progress("Poking vehicle; should avoid")
|
||||||
def shove(a, b):
|
def shove(a, b):
|
||||||
|
Loading…
Reference in New Issue
Block a user