From f96dca3311f8b6994cc38b8dcdba62f65826a532 Mon Sep 17 00:00:00 2001 From: Andrew Tridgell Date: Tue, 13 Dec 2011 13:50:06 +1100 Subject: [PATCH] autotest: example startup scripts for simulators --- Tools/autotest/sim_arducopter.sh | 18 ++++++++++++++++++ Tools/autotest/sim_arduplane.sh | 17 +++++++++++++++++ 2 files changed, 35 insertions(+) create mode 100755 Tools/autotest/sim_arducopter.sh create mode 100755 Tools/autotest/sim_arduplane.sh diff --git a/Tools/autotest/sim_arducopter.sh b/Tools/autotest/sim_arducopter.sh new file mode 100755 index 0000000000..c38c66f7ed --- /dev/null +++ b/Tools/autotest/sim_arducopter.sh @@ -0,0 +1,18 @@ +#!/bin/bash + +set -e +set -x + +autotest=$(dirname $(readlink -e $0)) +pushd $autotest/../../ArduCopter +make clean sitl + +tfile=$(tempfile) +echo r > $tfile +gnome-terminal -e "gdb -x $tfile --args /tmp/ArduCopter.build/ArduCopter.elf" +sleep 2 +rm -f $tfile +gnome-terminal -e '../Tools/autotest/pysim/sim_quad.py --home=-35.362938,149.165085,584,270' +sleep 2 +mavproxy.py --master tcp:127.0.0.1:5760 --sitl 127.0.0.1:5501 --out 127.0.0.1:14550 --out 127.0.0.1:14551 --quadcopter + diff --git a/Tools/autotest/sim_arduplane.sh b/Tools/autotest/sim_arduplane.sh new file mode 100755 index 0000000000..e2fd0e9c09 --- /dev/null +++ b/Tools/autotest/sim_arduplane.sh @@ -0,0 +1,17 @@ +#!/bin/bash + +set -e +set -x + +autotest=$(dirname $(readlink -e $0)) +pushd $autotest/../../ArduPlane +make clean sitl + +tfile=$(tempfile) +echo r > $tfile +gnome-terminal -e "gdb -x $tfile --args /tmp/ArduPlane.build/ArduPlane.elf" +sleep 2 +rm -f $tfile +gnome-terminal -e '../Tools/autotest/jsbsim/runsim.py --home=-35.362938,149.165085,584,270' +sleep 2 +mavproxy.py --master tcp:127.0.0.1:5760 --sitl 127.0.0.1:5501 --out 127.0.0.1:14550 --out 127.0.0.1:14551