Commit Graph
1653 Commits
Author SHA1 Message Date
Henry Wurzburg 20d43a5efe Tools: add mount POI lock Aux Func/Switch 2026-01-19 18:29:05 -05:00
Peter Barker c060e7b68d Tools: skip building arm boards when testing new boards
compiler not available on CI machine
2026-01-14 09:43:22 +11:00
Peter Barker b1a9562d09 Tools: add boards dynamically for SITL (i.e. hwdefs) 2026-01-14 09:43:22 +11:00
Peter Barker 3801c7118a Tools: remove no-longer-required running_python3 variables
this is always true now-adays
2026-01-11 17:41:07 -06:00
Peter Barker 188049d73a Tools: use normal layout for our enable defines for piccolocan, rename to AP_ namespace 2026-01-11 17:32:48 -06:00
Randy Mackay 820efa1327 Tools: add battery bms to build server 2026-01-08 10:23:59 +09:00
Peter Barker a627d377fd Tools: stop showing strings command in extract_features.py 2026-01-06 11:40:32 +11:00
Willian Galvani 8b779a8f3b Tools: uploader: open serial port in exclusive mode 2026-01-05 18:53:15 +11:00
bhavyasree-A8 123aa83b53 Tools: clarify Feature() column in build_options.py 2025-12-31 10:29:32 +11:00
Peter Barker c6b5bb2ece extract_features.py: do not show commands by default
no command-line option at the moment and we don't want this stuff emitted by default anyway.
2025-12-28 19:16:16 -06:00
Peter Barker cfac833c21 Tools: emit progress to stderr not stdout
mixing the progress with stdout is causing problems for tools trying to consume stdout:

[update.py]: feature EF: Running (arm-none-eabi-nm --demangle --print-size /home/autotest/build/tmp/binaries.build/ZeroOneX6_Air/bin/blimp) in (.) (ZeroOneX6_Air,Blimp) not in build_options.py
[update.py]: feature EF: Running (strings /home/autotest/build/tmp/binaries.build/ZeroOneX6_Air/bin/blimp) in (.) (ZeroOneX6_Air,Blimp) not in build_options.py
2025-12-28 19:16:16 -06:00
James O'Shannessy b16db812b0 Tools: Improvements to building of signed bootloaders
Adds ability to pass --omit-ardupilot-keys to build_bootloaders.py

Adds ability to pass multiple public keys to the signing of the bootloader. This extends the functionality of the single key that was previously possible. All keys are prefixed with --signing-key and are appended to the args.signing_key array. All keys are checked for presense, and type before being used to sign the bootloader.

General tidy up of the argument parser, prints a proper description of the role of the file.
2025-12-27 12:12:56 -06:00
James O'Shannessy 92d6da4fa9 signing: Improvements to make_secure_bl and make_secure_fw
This fixes make_secure_bl writing to the incorrect file (sys.argv[1]). The resultant file was whatever argv[1] was passed in as, which could have been --omit-ardupilot-keys.

This fixes make_secure_fw not running at all because of a possible return outside of a function. Also improves argument passing so we can get ourselves a better help file.
2025-12-27 12:12:56 -06:00
Peter Barker ac5232a71a Tools: extract_features.py: use run_program from build_script_base.py 2025-12-21 14:10:01 +11:00
Peter Barker 7a454f2a08 Tools: size_compare_branches.py: make --all-vehicles include tracker
better fix would be to call it tracker throughout ArduPilot, but a rather larger and more disruptive fix
2025-12-17 19:28:02 +11:00
Peter BarkerandClaude Sonnet 4.5 953479d733 Tools: require README.md for new board hwdef directories
Ensures that all new boards added via PR include documentation by checking
for the presence of a README.md file in the hwdef directory. This helps
maintain code quality and provides essential information for users.

AP_Periph boards are excluded from this requirement as they typically don't
need the same level of user-facing documentation.

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>
2025-12-16 08:54:23 +11:00
Randy Mackay b36fb7f133 Tools: param_check_all loses skywalker files from skip list 2025-12-10 10:27:32 -06:00
Randy Mackay 40b40492da Tools: param-check-all skip list shortened 2025-12-10 18:06:09 +11:00
Peter Barker 9aaa60bdb5 Tools: create and use a progress_prefix method 2025-12-09 11:55:49 +11:00
Peter Barker c6efa3dd1f Tools: add test_new_boards.py to test newly-added boards in PRs
Add a script that:
- Finds all newly-added hwdef files in the current branch (git status 'A')
- Extracts board names from hwdef directory paths
- Builds each new board and its bootloader if a bootloader hwdef was added
- Skips ESP32 boards (CI limitation)
- Uses BuildScriptBase for common build operations

The script is designed to run in CI to ensure new board definitions compile correctly.
2025-12-09 11:55:49 +11:00
Peter Barker 66d7ecfb73 Tools: extract BuildScriptBase from size_compare_branches.py
Create a base class for build scripts that provides common utilities extracted from size_compare_branches.py:
- run_program(): Execute commands with output handling
- run_waf(): Run waf with consistent build environment
- run_git(): Run git commands
- find_current_git_branch_or_sha1(): Get current branch/SHA
- find_git_branch_merge_base(): Find merge base

Refactor size_compare_branches.py to use the base class, reducing duplicated code.

Other scripts with similar patterns can be refactored in the future:
- build_binaries.py
- build_bootloaders.py
- build_iofirmware.py
- build_peripherals.py
- configure_all.py
2025-12-09 11:55:49 +11:00
Bob Long f98584f09f Tools: param_check: complain about legacy params
When generating metadata for the test, don't emit legacy parameters.
2025-12-05 10:20:59 +11:00
Bob Long 0186c0e9cc Tools: relax test_generate_metadata unit test
This section was simultaneously too strict and not strict enough. This
section mainly confirms that the vehicle argument is passed on.
2025-12-05 10:20:59 +11:00
Randy Mackay 5f9a8f7efe Tools: update build options for MAVLink Mount 2025-12-02 21:43:07 +11:00
Andy Piper d4fd350963 scripts: add LIS2MDL compass 2025-11-26 18:25:43 +11:00
Bob Long e1fb6c8f64 Tools: fix type hints in param_check
We changed the default to None, but forgot to update the type hints.
Also some drive-by whitespace cleanups.
2025-11-12 20:49:39 +11:00
Peter Barker ac254388c9 Tools: build_options.py: add AP_RANGEFINDER_AINSTEIN_LR_D1_ENABLED 2025-11-11 09:12:26 +00:00
Peter Barker cb633aeb19 Tools: various fixes to build_options.py and test_build_options.py
autotest: test_build_options.py: do not test AP_PERIPH_* defines on non-Periph builds

test_build_options.py:  AP_ROVER_AUTO_ARM_ONCE_ENABLED is only on Rover

test_build_options.py: create and use a blacklist

options on this blacklist really can't be tested when we're doing the
disable-everything step as they require one of two other options to
work, and we can't represent that in our dependencies

Tools: build_options.py: correct dependencies for CRSF Scripting

Tools: extract_features.py: correct extraction of AP_MAVLINK_FTP_ENABLED

Tools: test_build_options.py: exempt EK3_FEATURE_OPTFLOW_SRTM on some vehicles

AP_Terrain isn't instantiated so the symbol (and feature!) are missing

build_options.py: add missing dependency for Cortex generator

autotest: test_build_options.py: most vehicles do not have AP_ADSB_AVOIDANCE_ENABLED

autotest: test_build_options.py: fix for AP_SCRIPTING_BINDING_MOTORS_ENABLED

test_build_options.py: exempt AP_MOTORS_TRI_ENABLED except on Copter

Plane only has this if quadplane is enabled...
2025-11-11 11:27:31 +11:00
MinderringandHenry Wurzburg 00e4078e68 Tools: add hwdef MicoAir743-Lite
Update libraries/AP_HAL_ChibiOS/hwdef/MicoAir743-Lite/README.md

Co-authored-by: Henry Wurzburg <hwurzburg@yahoo.com>
2025-11-09 13:33:26 +11:00
bnsgeyer dcaf309465 Tools: change label in builder options 2025-11-04 10:35:38 +11:00
Oliver Walters ba86948bd0 Tools: Add GENERATOR_CORTEX support 2025-11-04 09:47:24 +11:00
Thomas Watson b876809242 Tools: remove absolute path reference to rm command
On some systems (e.g. NixOS) it's not there.
2025-11-03 09:53:37 -06:00
Peter Barker 6b4eb8e7d7 Tools: get Linux and ESP32 board names dynamically for bootloader blacklist 2025-11-02 17:17:29 +11:00
Peter Barker f7f6a13dbd Tools: size_compare_branches.py: don't build bootloader for pocket2
... it's a linux board...
2025-11-02 17:17:29 +11:00
Peter Barker d2a361afa7 Tools: fix instances of flake8 B006 error
e.g.:

./Tools/autotest/vehicle_test_suite.py:8607:89: B006 Do not use mutable data structures for argument defaults.  They are created during function definition time. All calls to the function reuse this one instance of that data structure, persisting changes between them.
2025-10-28 20:19:01 -05:00
Erkan Vatan 871abcf15a Tools: add t3-gem-o1 board 2025-10-27 18:43:16 -05:00
Peter Barker 76a39dc4df Tools: fix flake8 B008 errors, methods-in-function-definitions
e.g.

./Tools/scripts/param_check_all.py:180:40: B008 Do not perform function calls in argument defaults.  The call is performed only once at function definition time. All calls to your function will reuse the result of that definition-time function call.  If this is intended, assign the function call to a module-level variable and use that variable as a default value.
2025-10-27 11:18:20 +11:00
Andy Piper d801b2cd6a scripts: add support for AP_CPU_IDLE_STATS_ENABLED as a feature 2025-10-16 06:20:54 +11:00
Andrew Tridgell 986c418dda Tools: tidy up old unused build
unused
2025-10-14 09:14:13 -05:00
Peter Barker 7a4ee4297b Tools: extract_features.py: correct extraction symbol for AP_Vehicle Lua bindings 2025-10-14 10:53:33 +09:00
Thomas Watson 254faad89c Tools: don't generate no-longer-used env.py 2025-10-06 08:02:36 +11:00
Peter Barker 26ac908b70 Tools: add define so user can omit AP_Vehicle bindings 2025-10-01 18:05:38 +10:00
Peter Barker 2e57f4d27f Tools: add define so user can omit AP_Motors bindings 2025-10-01 18:05:38 +10:00
Peter Barker 5edf3b15f2 Tools: add ability for sim-on-hardware to use Simulink 2025-10-01 17:30:40 +10:00
Tom Pittenger 454c2d6179 Tools/scripts: add EAHRS SBG to build_options 2025-09-12 18:19:52 -07:00
Thomas Watson 907f9b4b92 CI: fail fast on rover PPP install
Ensure that ppp install succeeded and the binary executes directly after
install, instead of failing deep in the test suite.
2025-09-06 11:40:36 +01:00
Peter Barker 89808ffdba Tools: don't catch elf_diff exceptions 2025-09-05 16:25:23 +01:00
Peter Barker b2606801ae Tools: put elf diff output in current directory
may not be able to write into the previous directory (eg. on Vagrant VMs which have the checkout at /vagrant)
2025-09-05 16:25:23 +01:00
Peter Barker 4b8be6e4db Tools: correct running of elf-diff tool
was getting "None" in the argument list
2025-09-05 16:25:23 +01:00
Christian Clauss b65fe267ac Tools: Fix typos discovered by codespell 2025-09-03 14:41:07 +01:00