Commit Graph

254 Commits

Author SHA1 Message Date
Peter Barker fff4aa8bde autotest: increase allowed time for climb_before_turn to get home 2021-04-01 19:11:31 +11:00
Peter Barker 30ebe6cde9 autotest: augment test DO_AUX_FUNCTIION test for FAILED AND DENIED 2021-03-31 11:36:09 +11:00
Peter Barker b55094fef4 autotest: Test triggering Auxillary Functions via mavlink 2021-03-31 11:36:09 +11:00
Peter Barker 462ac255a3 autotest: start MAVProxy only as needed for testing 2021-03-19 09:46:45 +11:00
Stavros Korokithakis f6fc6d22da autotest: Fix the climb-before-turn test 2021-03-18 07:37:21 +11:00
Peter Barker 0c7f3d20a4 autotest: fix attitude test
autotest: add a get_messages_frame method

Attempts to get a set of messages as close as reasonable in time.
2021-03-16 14:19:44 +11:00
Stavros Korokithakis 29043d62e9 Add FLIGHT_OPTION to climb before RTL 2021-03-16 11:58:47 +11:00
Hwurzburg d15e01d390 Plane: fix DO_CHANGE_SPEED airspeed to impact only AUTO and GUIDED modes 2021-03-16 10:09:34 +11:00
Peter Barker eb702b0f82 Tools: add support for ATTITUDE_QUATERNION 2021-03-13 09:44:12 +11:00
Peter Barker f78d7c3b25 autotest: add option to not check current wp after set_current_wp
Sometimes a waypoint is set which we'll never emit as our current
waypoint (e.g. a JUMP)
2021-03-10 09:12:39 +11:00
Peter Barker 4a251bebbd autotest: fix fly_home_land_and_disarm; wp 7 is never current wp
This is never a current waypoint, so we can't wait for it
2021-03-10 09:12:39 +11:00
Peter Barker bdeadce95b autotest: improve deadreckoning test
autotest: use location_offset rather than coordinates in Deadreckoning test
2021-03-05 21:34:58 +11:00
Peter Barker 425ab1358a autotest: tidy streamrate handling
Stop setting MAVProxy stream rates; these are neither here-nor-there now as MAVProxy will only modify its own connection's streamrates now

Stop doing the set-streamrate dance to work around MAVProxy's
set_streamrate algorithms.

Remove useless and misleading set of streamrate in Plane test; we reset
streamrates on the reboot immediately following this set.  Considering
the streamrate was never eset this was a good thing.
2021-03-05 21:34:58 +11:00
James O'Shannessy bcc0da9c47 AutoTest: Adds additional autotests to capture mode change while breached
AutoTest: Adds test for fence breach switching to guided mode when no fence return point is present. In upstream, this results in a vehicle fly-away.
2021-03-05 14:52:46 +11:00
James O'Shannessy dac5996d93 AutoTest: Fix autotest conflicts after rebase on upstream 2021-03-05 14:52:46 +11:00
James O'Shannessy fa7be629e5 AutoTest: Make fence tests flake8 compliant 2021-03-05 14:52:46 +11:00
James O'Shannessy 2353b55452 AutoTest: Address race conditions in changes to fence tests 2021-03-05 14:52:46 +11:00
James O'Shannessy 76a2a76b54 AutotTest: Adds autotests for Plane to test RetRally flag added to AC_Fence 2021-03-05 14:52:46 +11:00
James O'Shannessy 8545715837 AutoTest: Add Static Fence Tests for unallowed arming when breaching geofence 2021-03-05 14:52:46 +11:00
James O'Shannessy 6f7ba3b037 AutoTest: Ensure fence is disabled at end of throttle_failsafe_fence test 2021-03-05 14:52:46 +11:00
James O'Shannessy bbd606b8b5 AutoTest: Corrections to autotests 2021-03-05 14:52:46 +11:00
James O'Shannessy 47e76a1807 AutoTest: Move fence enable/disable to common location 2021-03-05 14:52:46 +11:00
James O'Shannessy 215901be30 Autotest: Correct the logic for fence based autotest functions
Adds corrections to enabling fence using aux function.
Correctly test fences statically. Only uploaded fences can be checked using a fence file, so we check those first. Then we add steps to check tin can, max and minm all set the fence as present, as expected.
Plane will support MAV_PROTOCOL_CAPABILITY_MISSION_FENCE, so we assert that it does support it.
To test ceiling and floor, leverage some existing functions for takeoff, change altitude and land. Check for respective breach.
Add a floor breach check to copter.
2021-03-05 14:52:46 +11:00
James O'Shannessy 1a3e168ced Autotest: Fence is present, but test looking for not present
Autotest: Remove ties to mavlink FENCE_ACTION

Autotest: Add ArduPlane autotest to test ceiling and floor

Adds a test to ensure the vehicle reverts to RTL when breaching a ceiling or floor.

Autotest: Progress the test once we reach takeoff complete and fence enable

Autotest: Use RC_OPTION for Aux Switch functionality

Autotest: Enable fence last
2021-03-05 14:52:46 +11:00
Peter Barker a235246628 autotest: correct units in new AHRS2 test 2021-03-03 18:41:14 +11:00
Peter Barker b3ee5d5f59 autotest: increase verbosity in AHRS2 test 2021-03-03 16:29:33 +11:00
Peter Barker 317181922c autotest: ensure we're getting vaguely sane data in AHRS2 message 2021-03-02 20:48:36 +11:00
Peter Barker cc83562add autotest: tidy fence handling 2021-03-02 16:54:06 +11:00
Peter Barker 10007e2e42 autotest: load missions natively rather than using MAVProxy 2021-03-02 14:24:36 +11:00
Peter Barker 9120882e9e autotest: print name of open dataflash log when test exception caught
The stack trace is already extremely useful... but mapping back to the
relevant dataflash log is a bit of a pain.

Adding more stuff to this method in the future might be good, too.
2021-02-21 21:35:35 +11:00
Peter Barker d4aef2dba8 autotest: stop using MAVProxy to change mode 2021-02-20 00:03:24 +11:00
Peter Barker c13d229877 autotest: use self.set_current_waypoint rather than "wp set" to set current wp 2021-02-19 12:25:40 +11:00
Peter Barker dcc04ccd09 autotest: stop using MAVProxy to change modes 2021-02-18 17:38:52 +11:00
Peter Barker 628a3843b2 autotest: flake8 compliance for arduplane.py 2021-02-18 10:43:05 +11:00
Peter Barker a292fe1b8b autotest: use wait_statustext rather than mavproxy.expect
This is important when running under Valgrind as the text can be
significantly delayed.  wait_statustext times out in simulation time,
whereas mavproxy.expect has a flat 60s timeout
2021-02-17 18:16:04 +11:00
Peter Barker c00a82868e autotest: make DLVR sole airspeed sensor in test
The test wasn't actually *using* the DLVR...
2021-02-17 14:23:07 +11:00
Peter Barker ca49f62b6d autotest: add test for Plane's RTL_CLIMB_MIN parameter 2021-02-13 19:34:52 +11:00
Peter Barker d60fa86026 autotest: use set_map_from_rc more 2021-02-13 19:34:52 +11:00
Andrew Tridgell 3add045924 autotest: fixed accel/gyro threshold consistency for tempcal 2021-01-21 13:09:21 +11:00
Andrew Tridgell fe7d933976 autotest: use delay_sim_time() in tempcal test 2021-01-21 13:09:21 +11:00
Andrew Tridgell 58b9cd2c6e autotest: added assert_reach_imu_temperature() abstraction 2021-01-21 13:09:21 +11:00
Andrew Tridgell 4c315b57ca autotest: run gyro/accel cal at non-reference temperature 2021-01-21 13:09:21 +11:00
Andrew Tridgell 2cf7e7945c autotest: make tempcal debug output clearer 2021-01-21 13:09:21 +11:00
Andrew Tridgell 84dda13b42 autotest: use new learn param setup 2021-01-21 13:09:21 +11:00
Andrew Tridgell 30385fb8cb autotest: use set_parameters() in IMU temp cal test 2021-01-21 13:09:21 +11:00
Andrew Tridgell 327db46c15 autotest: added automatic testing of IMU Temperature calibration 2021-01-21 13:09:21 +11:00
Andrew Tridgell c396d15890 Revert "autotest: ensure defaults files don't set already-default-values"
This reverts commit 3d431cd4f1.

It breaks MissionPlanner SITL. We can re-apply once MissionPlanner
copes with external_model.
2021-01-20 08:54:43 +11:00
Peter Barker 3d431cd4f1 autotest: ensure defaults files don't set already-default-values
autotest: mark some vehicles as having external physics models

autotest: add default_params_filename to some vehicle info
2021-01-19 10:34:00 +11:00
Peter Barker 6becd90df0 autotest: increase timeout on DO_CHANGE_SPEED test 2021-01-18 19:08:46 +11:00
Peter Barker 5848ff7512 autotest: eliminate race condition in plane fence static test 2021-01-18 16:32:21 +11:00