autotest: add test for Guided WeatherVane behaviour

This commit is contained in:
Peter Barker 2024-05-23 22:21:08 +10:00 committed by Peter Barker
parent 1c5a026e3e
commit bdb84ed244
1 changed files with 15 additions and 0 deletions

View File

@ -11414,6 +11414,20 @@ class AutoTestCopter(vehicle_test_suite.TestSuite):
self.context_pop()
self.reboot_sitl(force=True)
def GuidedWeatherVane(self):
'''check Copter Guided mode weathervane option'''
self.set_parameters({
'SIM_WIND_SPD': 10,
'SIM_WIND_DIR': 90,
'WVANE_ENABLE': 1,
})
self.takeoff(20, mode='GUIDED')
self.guided_achieve_heading(0)
self.set_parameter("GUID_OPTIONS", 128)
self.wait_heading(90, timeout=60, minimum_duration=10)
self.do_RTL()
def tests2b(self): # this block currently around 9.5mins here
'''return list of all tests'''
ret = ([
@ -11502,6 +11516,7 @@ class AutoTestCopter(vehicle_test_suite.TestSuite):
self.EK3_OGN_HGT_MASK,
self.FarOrigin,
self.GuidedForceArm,
self.GuidedWeatherVane
])
return ret