From 2e427475cf98fbefa0fb7aa39338ff6c6aec8314 Mon Sep 17 00:00:00 2001 From: Andrew Tridgell Date: Wed, 4 Jul 2018 19:11:10 +1000 Subject: [PATCH] Tools: added bootloader docs --- Tools/AP_Bootloader/README.md | 30 ++++++++++++++++++++++++++++++ 1 file changed, 30 insertions(+) create mode 100644 Tools/AP_Bootloader/README.md diff --git a/Tools/AP_Bootloader/README.md b/Tools/AP_Bootloader/README.md new file mode 100644 index 0000000000..d77fed08d3 --- /dev/null +++ b/Tools/AP_Bootloader/README.md @@ -0,0 +1,30 @@ +# ArduPilot Bootloader + +This is the bootloader used for STM32 boards for ArduPilot. To build +the bootloader do this: + +```bash + ./waf configure --board BOARDNAME --bootloader + ./waf bootloader +``` + +the bootloader will be in build/BOARDNAME/bin. If you have the +intelhex module installed it will build in both bin format and hex +format. Both are usually uploaded with DFU. The elf file will be in +build/BOARDNAME/AP_Bootloader for loading with gdb. + +The --bootloader option tells waf to get the hardware config from +the hwdef-bl.dat file for the board. It will look in +libraries/AP_HAL_CHibiOS/hwdef/BOARDNAME/hwdef-bl.dat + +The bootloader protocol is compatible with that used by the PX4 +project for boards like the Pixhawk. For compatibility purposes we +maintain a list of board IDs here: + + https://github.com/ArduPilot/Bootloader/blob/master/board_types.txt + +the board IDs in that file match the APJ_BOARD_ID in the hwdef.dat and +hwdef-bl.dat files + +The bootloader can load from USB or UARTs. The list of devices to load +from is given in the UART_ORDER option in hwdef-bl.dat