Link fixes galore (#25151)

This commit is contained in:
Hamish Willee
2025-07-03 14:53:12 +10:00
committed by GitHub
parent dd0d00aedc
commit 375f421c61
107 changed files with 836 additions and 972 deletions
+22 -20
View File
@@ -1,20 +1,20 @@
# STM32 Bootloader
The code for the PX4 bootloader is available from the Github [Bootloader](https://github.com/px4/bootloader) repository.
The code for the PX4 bootloader is available from the Github [Bootloader](https://github.com/PX4/PX4-Bootloader) repository.
## Supported Boards
* FMUv2 (Pixhawk 1, STM32F4)
* FMUv3 (Pixhawk 2, STM32F4)
* FMUv4 (Pixracer 3 and Pixhawk 3 Pro, STM32F4)
* FMUv5 (Pixhawk 4, STM32F7)
* TAPv1 (TBA, STM32F4)
* ASCv1 (TBA, STM32F4)
- FMUv2 (Pixhawk 1, STM32F4)
- FMUv3 (Pixhawk 2, STM32F4)
- FMUv4 (Pixracer 3 and Pixhawk 3 Pro, STM32F4)
- FMUv5 (Pixhawk 4, STM32F7)
- TAPv1 (TBA, STM32F4)
- ASCv1 (TBA, STM32F4)
## Building the Bootloader
```sh
git clone https://github.com/PX4/Bootloader.git
git clone https://github.com/PX4/PX4-Bootloader.git
cd Bootloader
git submodule init
git submodule update
@@ -26,25 +26,26 @@ After this step a range of elf files for all supported boards are present in the
## Flashing the Bootloader
:::warning
The right power sequence is critical for some boards to allow JTAG / SWD access. Follow these steps exactly as described.
The right power sequence is critical for some boards to allow JTAG / SWD access. Follow these steps exactly as described.
:::
The instructions below are valid for a Blackmagic / Dronecode probe.
The instructions below are valid for a Blackmagic / Zubax BugFace BF1 probe.
Other JTAG probes will need different but similar steps.
Developers attempting to flash the bootloader should have the required knowledge.
If you do not know how to do this you probably should reconsider if you really need to change anything about the bootloader.
The sequence is
1. Disconnect the JTAG cable
1. Connect the USB power cable
1. Connect the JTAG cable
### Black Magic / Dronecode Probe
### Black Magic / Zubax BugFace BF1 Probe
#### Using the right serial port
* On LINUX: `/dev/serial/by-id/usb-Black_Sphere_XXX-if00`
* On MAC OS: Make sure to use the cu.xxx port, not the tty.xxx port: `tar ext /dev/tty.usbmodemDDEasdf`
- On LINUX: `/dev/serial/by-id/usb-Black_Sphere_XXX-if00`
- On MAC OS: Make sure to use the cu.xxx port, not the tty.xxx port: `tar ext /dev/tty.usbmodemDDEasdf`
```sh
arm-none-eabi-gdb
@@ -77,11 +78,10 @@ JLinkGDBServer -select USB=0 -device STM32F427VI -if SWD-DP -speed 20000
The `--device`/SoC for common targets is:
* **FMUv2, FMUv3, FMUv4, aerofc-v1, mindpx-v2:** STM32F427VI
* **px4_fmu-v4pro:** STM32F469II
* **px4_fmu-v5:** STM32F765II
* **crazyflie:** STM32F405RG
- **FMUv2, FMUv3, FMUv4, aerofc-v1, mindpx-v2:** STM32F427VI
- **px4_fmu-v4pro:** STM32F469II
- **px4_fmu-v5:** STM32F765II
- **crazyflie:** STM32F405RG
#### Connect GDB
@@ -93,15 +93,16 @@ arm-none-eabi-gdb
### Troubleshooting
If any of the commands above are not found, you are either not using a Blackmagic probe or its software is outdated.
If any of the commands above are not found, you are either not using a Blackmagic probe or its software is outdated.
Upgrade the on-probe software first.
If this error message occurs:
```
Error erasing flash with vFlashErase packet
```
Disconnect the target (while leaving JTAG connected) and run
Disconnect the target (while leaving JTAG connected) and run
```sh
mon tpwr disable
@@ -109,4 +110,5 @@ swdp_scan
attach 1
load tapv1_bl.elf
```
This will disable target powering and attempt another flash cycle.