From bf1e991308f7932a7eb7f31aa5722c167b109fff Mon Sep 17 00:00:00 2001 From: Jason Short Date: Tue, 8 Nov 2011 21:43:18 -0800 Subject: [PATCH] New mission test --- Tools/autotest/arducopter.py | 12 ++++++------ Tools/autotest/mission_ttt.txt | 11 +++++++++++ 2 files changed, 17 insertions(+), 6 deletions(-) create mode 100644 Tools/autotest/mission_ttt.txt diff --git a/Tools/autotest/arducopter.py b/Tools/autotest/arducopter.py index 46c092d9e8..ac7b565fb3 100644 --- a/Tools/autotest/arducopter.py +++ b/Tools/autotest/arducopter.py @@ -79,7 +79,7 @@ def wait_altitude(mav, alt_min, alt_max, timeout=30): return True print("Failed to attain altitude range") return False - + def arm_motors(mavproxy): '''arm motors''' @@ -98,7 +98,7 @@ def disarm_motors(mavproxy): mavproxy.expect('APM: DISARMING MOTORS') mavproxy.send('rc 4 1500\n') print("MOTORS DISARMED OK") - + def takeoff(mavproxy, mav): '''takeoff get to 30m altitude''' @@ -205,7 +205,7 @@ def fly_square(mavproxy, mav, side=50, timeout=120): return ok - + def land(mavproxy, mav, timeout=60): '''land the quad''' @@ -307,8 +307,8 @@ def fly_ArduCopter(): fly_square(mavproxy, mav) loiter(mavproxy, mav) land(mavproxy, mav) - fly_mission(mavproxy, mav, os.path.join(testdir, "mission1.txt")) - land(mavproxy, mav) + fly_mission(mavproxy, mav, os.path.join(testdir, "mission_ttt.txt")) + #land(mavproxy, mav) disarm_motors(mavproxy) except pexpect.TIMEOUT, e: failed = True @@ -327,4 +327,4 @@ def fly_ArduCopter(): if failed: print("FAILED: %s" % e) sys.exit(1) - + diff --git a/Tools/autotest/mission_ttt.txt b/Tools/autotest/mission_ttt.txt new file mode 100644 index 0000000000..9c06a0c869 --- /dev/null +++ b/Tools/autotest/mission_ttt.txt @@ -0,0 +1,11 @@ +QGC WPL 110 +#s fr ac cmd p1 p2 p3 p4 lat lon alt continue +0 1 3 0 0.000000 0.000000 0.000000 0.000000 -35.362881 149.165222 582.000000 1 +1 0 3 22 0.000000 0.000000 0.000000 0.000000 -35.362881 149.165222 20.000000 1 +2 0 3 115 360.0 10.0000 1.0 1.0 -35.362612, 149.164186 20.000000 1 +3 0 3 16 0.000000 0.000000 0.000000 0.000000 -35.362612, 149.164186 20.000000 1 +4 0 3 16 0.000000 0.000000 0.000000 0.000000 -35.363928, 149.165718 20.000000 1 +5 0 3 16 0.000000 0.000000 0.000000 0.000000 -35.363910, 149.162632 20.000000 1 +6 0 3 16 0.000000 0.000000 0.000000 0.000000 -35.365215, 149.164145 20.000000 1 +7 0 3 20 0.000000 0.000000 0.000000 0.000000 -35.363228 149.161896 30.000000 1 +8 0 3 21 0.000000 0.000000 0.000000 0.000000 -35.363228 149.161896 0.000000 1