Commit Graph

2680 Commits

Author SHA1 Message Date
Andrew Tridgell
4f7630e29c Tools: allow for double EKF build 2021-07-10 07:20:41 +10:00
Andrew Tridgell
b8e934ccf1 autotest: added --udp option to sim_vehicle.py
this makes running with high speedups easier
2021-07-09 19:19:24 +10:00
Peter Barker
aa27479e95 autotest: show output from Replay run 2021-07-08 16:20:12 +10:00
Peter Barker
743ed05367 autotest: detect ap-*.core as we do core.* files 2021-07-08 15:46:07 +10:00
Peter Barker
fd803ddafc autotest: remove stray diagnostic files before run 2021-07-08 15:46:07 +10:00
Andrew Tridgell
3a7075fc65 autotest: fixed config error loop test 2021-07-08 07:56:51 +10:00
bugobliterator
236eecc494 autotest: add option for running sim with ONVIF camera 2021-07-07 18:57:25 +10:00
Siddharth Purohit
2750b361aa autotest: move to using tool instead of tools program group 2021-07-07 17:31:09 +10:00
Peter Barker
70a161a583 autotest: create SITL debug binaries by default 2021-07-07 17:11:27 +10:00
Peter Barker
df02289493 autotest: add test for two consecutive drops with no reboot 2021-07-07 12:01:07 +10:00
Michelle Rossouw
8017e528c8 Tools: Add Blimp to param_parse.py 2021-07-06 14:56:02 +10:00
Peter Barker
c1a5ca6060 autotest: add test to ensure we get a log if arming is forced 2021-07-04 08:54:54 +10:00
Peter Barker
85f36f957d autotest: add force option to arm_vehicle 2021-07-04 08:54:54 +10:00
Andrew Tridgell
d81b758d77 autotest: support using geocoder for -L location
this allows for location names from OSM, for example:

  sim_vehicle.py -L '26 Carstensz St Griffith' --console --map
2021-06-29 15:41:26 +10:00
Peter Barker
99a0f5a86a autotest: disable quadplane ConfigErrorLoop test
failing on the autotest server (and locally).

AT-1474.6: RC values bad: (ch=1 want=1500 got=0)
AT-1474.6: AP: Config error: Baro: unable to initialise driver
AT-1474.6: AP: Config Error: fix problem then reboot
AT-1474.6: RC values bad: (ch=1 want=1500 got=0)
AT-1474.6: RC values bad: (ch=1 want=1500 got=0)
AT-1474.6: RC values bad: (ch=1 want=1500 got=0)
2021-06-27 11:09:39 +10:00
Randy Mackay
5ec75578ab Tools: add copter gps_glitch_loiter_test2
checks for twitches in Loiter after GPS glitch
2021-06-25 16:52:57 +09:00
Andrew Tridgell
220107b2a6 Tools: added boat circuit for Rabi 2021-06-25 15:33:55 +10:00
Andrew Tridgell
396094a82c Tools: added a mission around Rabi, close to -180 degrees lon 2021-06-25 15:33:55 +10:00
Andrew Tridgell
75ae2548a7 Tools: added some locations close to the date line 2021-06-25 15:33:55 +10:00
Andrew Tridgell
3204ce4bf1 Tools: added --postype-single for sim_vehicle.py 2021-06-24 21:34:30 +10:00
Peter Barker
4c173e01ef autotest: increase number of parameter retries
sets were failing just after we uploaded very large numbers of
parameters.  I'm guessing the parameter queue in ArduPilot is still
full.
2021-06-24 17:58:31 +10:00
Peter Barker
4bb91d1ec1 autotest: shift where we print which attempt we are doing 2021-06-24 17:58:31 +10:00
Randy Mackay
f3c96b438b Tools: autotest of vibration failsafe 2021-06-24 08:34:56 +10:00
Peter Barker
b58e7bedaa autotest: correct placement of not-alive-after-test message
This was misplaced with bad conflict resolution
2021-06-24 08:34:06 +10:00
Peter Barker
d6f619fb1a autotest: emit 'attempt 1/3' when retrying set_parameter
Also reterm things in terms of attempts rather than retries
2021-06-24 08:30:03 +10:00
Peter Barker
99c7d3aabc autotest: ensure no stray message listeners after test 2021-06-23 21:55:32 +10:00
Peter Barker
6a8ca9e45b autotest: timeout in wallclock time in config error loop test
SYSTEM_TIME is not sent in config error loop
2021-06-23 21:55:32 +10:00
Peter Barker
b6d5569244 Tools: param_metadata: disallow @Values and @Bitmask at same time 2021-06-23 18:37:34 +10:00
Peter Barker
7842f55a3b Tools: add rc channel option to disable all airspeed sensors 2021-06-23 15:13:13 +10:00
Peter Barker
d82a229584 autotest: revert to subprocess.check_call
.run is only Python3
2021-06-22 20:24:07 +10:00
Peter Barker
8395bf617f autotest: disable autotesting of tri frame as it is still busted 2021-06-21 21:17:10 +10:00
Peter Barker
697fbb0db0 autotest: verify roll/pitch are not adversely affected by yaw inputs 2021-06-21 21:17:10 +10:00
Peter Barker
4c20bc2d9d autotest: ensure reasonable yawrate on takeoff in FlyEachFrame 2021-06-21 21:17:10 +10:00
Peter Barker
d3f90bde7f autotest: add FlyEachFrame test for Plane 2021-06-21 14:13:18 +10:00
Pierre Kancir
39c96f63c8 Tools: autotest.py: total flake8 compliance. 2021-06-18 16:03:51 +10:00
Pierre Kancir
7ddb4d681d Tools: autotest: correct exception handling on unit test run. 2021-06-18 16:03:51 +10:00
Peter Barker
723d2dee00 autotest: improve diagnostics around touchdown/takeoff expected tests
Also looks at last result as we don't appear to have a consistent number
in our tests
2021-06-18 09:03:34 +09:00
Peter Barker
210818cd6e autotest: let arming failure messages get spit out 2021-06-17 21:01:23 +10:00
Peter Barker
47a778d033 Tools: remove HIL support 2021-06-15 09:47:31 +10:00
Peter Barker
61fda691f2 autotest: add trivial test for smart battery logging 2021-06-15 09:46:26 +10:00
Peter Barker
cea0d7c971 autotest: move autotest tlog files into buildlogs directory 2021-06-11 22:14:11 +10:00
Peter Barker
e77512ba08 autotest: add method to create simple relative-to-home mission 2021-06-11 16:59:51 +10:00
Peter Barker
14b2af84ab autotest: break out a home_relative_loc_ne for getting a home-rel loc 2021-06-11 16:59:51 +10:00
Peter Barker
96e14d470a autotest: retry SITL connect many times while running under GDB
Allows for easier debugging under gdb when checking startup code
2021-06-11 11:15:58 +10:00
Peter Barker
0b517cfc57 autotest: start GDB in tui mode by default 2021-06-10 20:52:48 +10:00
Peter Barker
fd792bebf8 autotest: wipe SITL state after temperature cal test
ArduPilot internals are fiddling state that the autotest suite is
unaware of, so wipe the eeprom after the test
2021-06-09 14:14:06 +10:00
Peter Barker
79de738266 autotest: wait for a few seconds for arm-failure messages to appear
If prearms never come true then we try to arm the vehicle so it tells us
what is wrong.  Since we no longer push statustexts hard, we have to
wait for the reasons to come out at normal clocked rates.
2021-06-09 14:13:54 +10:00
Peter Barker
6af6d2fc2a autotest: add a progress message for looking for a message in a log 2021-06-09 14:13:31 +10:00
Peter Barker
6944ef6af1 autotest: fly each working Helicopter frame 2021-06-09 12:15:42 +10:00
Randy Mackay
058d4299ad Tools: update SITL tri and hexa gains 2021-06-08 19:11:32 +10:00
Andrew Tridgell
3be7f1ae23 autotest: removed tri from doesn't fly list 2021-06-08 19:11:32 +10:00
Andrew Tridgell
0876cb9cd6 autotest: fixed defaults for tricopter 2021-06-08 19:11:32 +10:00
arsh
45f1d03bda autotest:Copter test fix for some frames
removed some lines

Whitespace messages removal
2021-06-08 16:50:37 +10:00
Peter Barker
0bd9610687 autotest: add trivial test for BodyFrameOdom 2021-06-04 15:09:51 +10:00
Randy Mackay
e8947dfb47 Tools: reduce copter autotest rate yaw P and I gains
affects quad, hexa, octa, octa-quad, deca, tri, y6, dodeca-hexa
2021-06-03 12:20:43 +09:00
yaapu
b14dcf1df5 Tools:autotest: updated FRSky SPort test to use new 2 byte data IDs 2021-06-02 17:33:15 +10:00
Pierre Kancir
cf350a52e9 Tools: Autotest: add --coverage option 2021-06-02 14:42:59 +10:00
Peter Barker
2439587c5a autotest: add tests for ground effect compensation active in EKF 2021-06-02 11:13:16 +09:00
Peter Barker
8925c2830b autotest: check fence upload/download when creating from locs 2021-06-01 15:54:59 +10:00
Peter Barker
c1a20ceab4 autotest: add test to catch bug with opticalflow if no rangefinder 2021-06-01 11:31:42 +10:00
Randy Mackay
26ea80fc62 Tools: update default params for copter-optflow.parm 2021-06-01 09:57:16 +10:00
Pierre Kancir
7e389afbec Tools: allow to build examples and tests with debug 2021-05-26 18:46:03 +10:00
Pierre Kancir
58358d9f97 Tools: correct arguments passing on autotest.py 2021-05-26 18:46:03 +10:00
Leonard Hall
1326dbe2ee AutoTest: Sub: Add appropriate pid parameters for highly damped system 2021-05-24 20:13:37 +10:00
Leonard Hall
41c437b768 AutoTest: Copter: fly_poshold_takeoff increase acceptable range 2021-05-24 20:13:37 +10:00
Pierre Kancir
458b6084fa Tools: don't make report test failure on coverage 2021-05-20 14:54:47 +10:00
Peter Barker
c7a9fb3c9c autotest: retry dynamic notches 8 times before failing
This test is flapping.

This is a poor - but serviceable - workaround.
2021-05-18 11:13:10 +10:00
Peter Barker
0a06a9e446 param_metadata: reinstance @Values/@Bitmask magic for excluding params from vehicle output 2021-05-17 10:18:35 +10:00
Peter Barker
eb2b1b3231 Tools: param_meteadata: correct @Values{Plane} etc handling 2021-05-17 10:18:35 +10:00
Peter Barker
3eb164fb6a autotest: move script helper functions from rover to common 2021-05-14 13:21:36 +10:00
Peter Barker
3d562046da autotest: add accuracy option to guided_achieve_heading 2021-05-14 13:21:36 +10:00
Peter Barker
c18c4ad6ec Tools: param_metadata: remove use of dirname when creating Vehicle
So a Vehicle object takes a truename - i.e. Copter, not ArduCopter, but
can also take a "reference", which is used for e.g. constructing RST
tags.
2021-05-13 21:09:45 +10:00
Peter Barker
3ea9307419 Tools: param_metadata: flake8 cleanliness 2021-05-13 21:09:45 +10:00
Peter Barker
1123de112c Tools: param_metadata: tidy finding of Vehicle parameter file 2021-05-13 21:09:45 +10:00
Peter Barker
97e57932c4 Tools: param_metadata: remove more multi-vehicle support
This script hasn't supported emitting multiple vehicles for a very long
time, but this was enforced using a check and we kept a list of vehicles
around for no very good reason.
2021-05-13 21:09:45 +10:00
Andy Piper
2df7b5453e autotest: add test for ESC telemetry driven notches. 2021-05-12 17:01:11 +10:00
Peter Barker
d2f78c69be autotest: add a simple test for SMART_RTL 2021-05-12 13:01:50 +10:00
Peter Barker
9965f1a31d autotest: add some helpers for local-position movement 2021-05-12 13:01:50 +10:00
Peter Barker
7ab094f3a1 autotest: tidy fly_guided_move_local 2021-05-12 13:01:50 +10:00
Peter Barker
1d6efbd56f autotest: fix loiter_to_ne
Co-Authored-By: leonardthall@gmail.com
2021-05-11 14:51:28 +10:00
Peter Barker
04aed49572 autotest: adjust GyroFFT threshold to make it pass
From Andy:

Can you make this 0. The test should then pass. I'm not terribly happy about it but its better than disabling the test and I can't tell whether there is actually a problem or not.
2021-05-07 18:30:08 +10:00
Peter Barker
0a235ce094 autotest: remove retry loop from within GyroFFT
This effectively removes an infinite loop from the GyroFFT test.
2021-05-07 18:30:08 +10:00
Peter Barker
765889b827 autotest: don't send statustext during exception
During an exception we don't want to be trying to print these
2021-05-07 14:21:44 +10:00
Peter Barker
f78cf73726 autotest: don't fail completely if ArduPilot process dies 2021-05-07 12:22:11 +10:00
Peter Barker
b04dfda9fb autotest: enable deca and dodeca frames in FlyEachFrame test 2021-05-06 16:26:28 +10:00
Peter Barker
cf4acaa2aa autotest: re-enable quadplane QAutoTune test 2021-05-05 23:43:59 +10:00
James O'Shannessy
bc38d8a78c AutoTest: Fix autotest from failing due to state from earlier test
Autotest was failing because there was an expectation that the plane would fly relatively north from the takeoff point.
This assumption may not be true. We work around it by using a tin can instead of an exclusion polygon so that we breach no matter the direction we fly.
2021-05-05 10:59:10 +10:00
James O'Shannessy
0e656c1504 AutoTest: Ensure Plane uses home as Fence Return Point if one is not present and no exclusion fence is present 2021-05-05 10:59:10 +10:00
Peter Barker
9a13b5c9b6 autotest: add test for auxfunc triggering via script 2021-05-05 07:13:18 +10:00
Iampete1
aa72b7da46 Tools: autotest: Plane: add loiter terrain following test 2021-05-02 18:51:27 +10:00
Peter Barker
57abaf0dec autotest: remove retry loop from within GyroFFTHarmonic 2021-05-01 21:30:28 +10:00
Peter Barker
4928ec18af autotest: remove retry loop from within fly_dynamic_notches
We retried externally to the test - may as well do so within
2021-05-01 21:30:28 +10:00
Peter Barker
8fdfdebe55 autotest: pass sitl_commandline_customised up the context stack
We're running tests on the Callisto frame when we shouldn't in Copter as
the information was lost in nested Contexts.

We can only reset the SITL commandline at an actual Test level - if a
defaults file has been used then it is unclear as to what the state of
any parameter is in storage as we move between contexts
2021-05-01 17:22:36 +10:00
Peter Barker
117a44b589 autotest: remove corefiles at start of run
These lead to false-positive failures in the test suite
2021-05-01 17:22:36 +10:00
Peter Barker
2cd0099bbc autotest: exclude decarotor from fly-each-frame-test 2021-05-01 13:25:13 +10:00
Peter Barker
76678ffaf3 autotest: fix octa-cwx in SITL 2021-05-01 13:25:13 +10:00
Peter Barker
5172e767df autotest: fix octa-dji in SITL 2021-05-01 13:25:13 +10:00
Peter Barker
c7c4c17c68 autotest: improve change_mode debug 2021-05-01 13:25:13 +10:00
Peter Barker
63ba484087 autotest: add test which flies each frame we can 2021-05-01 13:25:13 +10:00
jbarrozo
3b1f5f0b15 autotest: added Boquig 2021-04-29 13:35:22 +10:00
Peter Barker
e4c405b77b autotest: add a test for Spline missions showing terrain requirement 2021-04-28 18:40:26 +10:00
Iampete1
3bea2fd89b Tools: autotest: defualts: setup direct acutated wing servo 2021-04-28 08:22:47 +01:00
Iampete1
0628aa9e29 Tools: autotest: add sailboat autotest 2021-04-28 15:16:35 +10:00
Peter Barker
fc426e01c2 autotest: stop using start_test for things that aren't actually tests
start_test should only be used for top-level tests, not parts of
top-level tests
2021-04-28 13:53:46 +10:00
Peter Barker
6af0f460af autotest: add duplicate-logmessage-field sanity check 2021-04-27 16:38:40 +10:00
Peter Barker
30e8160aa1 autotest: sort logs before moving
Makes it easier to find last log in output.

Also removing pointless lamdaing of some functions
2021-04-21 13:16:24 +10:00
Pierre Kancir
927a875133 Tools: param_parse: fix vehicle specific parameter with multiple fields 2021-04-21 11:30:54 +10:00
Peter Barker
0ee0228883 autotest: fix flapping fly-home-land-and-disarm
One of the tests just happened to be within acceptance radius of
waypoint 8 - so when we set that as a waypoint we never saw it actually
be our waypoint so the set_waypoint failed
2021-04-20 23:04:24 +10:00
Peter Barker
8643322f06 autotest: correct string we expect from MAVProxy
Was APM: now AP:
2021-04-20 14:08:12 +10:00
Peter Barker
c12d1938c2 autotest: add a test for button change for changing modes 2021-04-19 14:27:45 +10:00
Andrew Tridgell
be161744db autotest: adjust default plane tune 2021-04-15 06:57:16 +10:00
Andrew Tridgell
0be24c4946 Tools: convert old param files to new plane PID params 2021-04-15 06:57:16 +10:00
Andrew Tridgell
0d9d952aea autotest: added SpringValley2 2021-04-15 06:57:16 +10:00
Peter Barker
31c889f583 autotest: accept Copter/Plane/Sub for sim_vehicle.py 2021-04-12 13:35:16 +10:00
Andrew Tridgell
affff0fc84 Tools: test mission from Leonards S-curve talk 2021-04-11 19:16:09 +10:00
Peter Barker
27b6637c2d Tools: param_parse.py: add support for generation for AP_Periph 2021-04-11 11:31:41 +10:00
Peter Barker
b107740542 Tools: param_parse: add --sitl to emit only SIM_ parameters 2021-04-10 11:28:22 +10:00
Randy Mackay
0b9753b12f Tools: autotest add vehicle info for rover-vectored 2021-04-08 08:47:07 +09:00
Randy Mackay
d00e63d14b Tools: add default params for rover-vectored
Co-authored-by: srmainwaring <rhys.mainwaring@me.com>
2021-04-08 08:47:07 +09:00
Peter Barker
b369e86c0c Tools: param_parse: remove references to APM in parameter generation 2021-04-07 17:08:25 +10:00
Peter Barker
229b25d916 Tools: param_parse: add *args and **kwargs to emitters 2021-04-07 17:08:25 +10:00
Peter Barker
5a927d84c8 Tools: param_parse: rejig selection of emitters 2021-04-07 17:08:25 +10:00
Peter Barker
5ef5fc9d84 Tools: param_parse: stop generating old .wiki format 2021-04-07 17:08:25 +10:00
Peter Barker
c3414a5767 Tools: param_parse: move init of variable lower 2021-04-07 17:08:25 +10:00
Peter Barker
4c6b07e950 Tools: param_parse: remove support for Parameters.pde 2021-04-07 17:08:25 +10:00
Peter Barker
c350268918 autotest: correct compilation of Replay in autotest suite 2021-04-05 16:39:36 +10:00
Peter Barker
ea4bbcf6ee autotest: add test for copter position reset 2021-04-05 00:02:42 +10:00
Randy Mackay
ab2e429f32 Tools: Copter.fly_square descends more quickly 2021-04-03 12:07:59 +09:00
Randy Mackay
f341429977 Tools: Copter.RTLSpeed gets increased speed tolerance 2021-04-03 12:07:59 +09:00
Randy Mackay
c04f686ce7 Tools: extend copter NavDelay test by 80sec
s-curves slows missions slightly
2021-04-03 12:07:59 +09:00
Peter Barker
f0094bac40 autotest: remove copied-in duplicate of pymavlink rotmat 2021-04-03 13:26:06 +11:00
Peter Barker
dfa342a79f autotest: correct rc-values-good debug 2021-04-03 08:59:14 +11:00
Peter Barker
7d9daccdf7 autotest: fix mavproxy switch test
The order in which we fix the environment means that we need to be
listening on the correct port for rc values - so just fix it in the test
2021-04-03 08:58:52 +11:00
Peter Barker
d384ba6585 autotest: increase time permitted for Copter to turn east
Sometimes they turn almost 360 which takes a while
2021-04-02 21:29:43 +11:00
Peter Barker
2c6bdd200c autotest: fix make_safe_filename for Valgrind
Valgrind treats this as a format string so the % is bad
2021-04-02 20:51:18 +11:00
Peter Barker
18ded114ae Tools: param_metadata; stop prettifying XML before emitting
indent is not available on our documentation server:

[build_parameters.py]
Traceback (most recent call last):
  File "./param_parse.py", line 422, in <module>
    do_emit(XmlEmit())
  File "./param_parse.py", line 415, in do_emit
    emit.close()
  File "/home/wiki/build_wiki/ardupilot/Tools/autotest/param_metadata/xmlemit.py
", line 24, in close
    etree.indent(self.paramfile)
AttributeError: module 'lxml.etree' has no attribute 'indent'
2021-04-02 14:39:39 +11:00
Peter Barker
cee348d082 Tools: make and declare bisect-helper.py flake8-compliant 2021-04-01 19:11:50 +11:00
Peter Barker
ee79895a4e Tools: make and declare examples.py flake8-compliant 2021-04-01 19:11:50 +11:00
Peter Barker
fff4aa8bde autotest: increase allowed time for climb_before_turn to get home 2021-04-01 19:11:31 +11:00
Peter Barker
f988064e48 Tools: add a tool to help determine best speedup for autotest 2021-04-01 11:27:17 +11:00
Peter Barker
d2c00f7b26 autotest: ensure RC thread is killed after each run_test
Every run_test starts a thread.  del is not being called.  So clean it
up in the caller
2021-04-01 11:00:54 +11:00
Peter Barker
500679ec5b autotest: correct creation of default parameters
Simulation won't start if nothing is connected to 5760 - so just connect
mavproxy there
2021-03-31 23:29:47 +11:00
Peter Barker
ba972b6b46 autotest: fix --map option 2021-03-31 16:30:25 +11:00
Peter Barker
d621fe0cde autotest: correct sub gripper mission
Ordinarily not run because gripper is disabled
2021-03-31 13:43:31 +11:00
Peter Barker
e8f96efe72 autotest: wait for stats initialisation before rebooting
If the RTC time we reset parameters (STAT_RESET) is zero then we reset all parameters.

In SITL we only set that time if we see a GPS due to the AP_RTC RTC_TYPES parameter default bitmask value of 1

So if you reboot SITL fast enough while STAT_RESET is zero you can see that STAT_BOOTCNT does not increase. Easily reproducible in SITL; start with -w and type reboot in several times before SITL sees the GPS come up and you can see STAT_BOOTCNT doesn't increase.

Fix is to ensure STAT_RESET is non-zero before rebooting.
2021-03-31 13:33:39 +11:00
Michelle Rossouw
cd18e16ffb autotest: added blimp simulator type 2021-03-31 12:27:07 +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
b2f47ba367 autotest: add test for auxilliary functions in missions 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
ef4ebbf126 autotest: add a do-nothing --autotest-server option
This option is currently ignored, but if given allows the script to
continue normally.

This allows us to change the autotest server to pass the option in - and
then we can change autotest.py so that unless the option is given we
spit out a help message rather than completely stuff up the user's
development environment
2021-03-26 22:52:35 +11:00