Pixhawk 4 Boot0 pin for DFU mode

Hey there, we purchased a Pixhawk 4 from Holybro a couple of weeks ago and I have been having some trouble uploading firmware using OpenOCD. Initially, it was working fine but I think I experienced some hardware issues (faulty cables) while uploading to the board and now it is frozen (Green and blue FMU lights are frozen), and it appears that the bootloader may be corrupted because it is not being recognized as a USB device anymore and QGC doesn’t detect it. After a hardware reset it doesn’t appear to execute the bootloader code. I can’t chat to it using OpenOCD to see what the xPSR register looks like either. My solution is to boot it into DFU mode and run a tool like ST-Link Utility or dfu-util to re-flash the PX4 bootloader and px4_fmu-v5_default firmware to bring it back to its default state. However, I cannot seem to find the boot0 pin on the Pixhawk 4. I can see some test points on the PCB around the STM32F765 but am unsure if these are what I’m looking for. It seemed to be available on previous versions of the Pixhawk so I’m convinced it should be on this one too. Does anyone know where I can find the boot0 pin?

Good day, it’s not necessary find the boot 0pin.
If you have a pc running Windows and an stlink programmer you can reflash the bootloader with stlink utility… you can do it with the debug port located on your fc. The points near the main MCU are the vias for the rails.
Just in case you need more info you can write me

Thanks for your reply Dave. I have tried to use stlink utility by connecting an ST-Link V2 probe (clone) to the SWD port on the side of the device but it just says that it cannot connect to the device. As I said, the pixhawk appears to be in a hung state where the green and blue fmu lights are frozen solid. I have a feeling that the CPU is in a hard fault. If you have any suggestions about how I can get it to connect to st-link utility so that I can erase and flash I would be incredibly grateful. Please let me know if you would like any screenshots or videos of anything to give you some more information.

So I managed to fix the Pixhawk. The reason ST-Link Utility was unable to connect to it was because somehow the SWD pins had become disabled when the flash programming failed. As such, no interface could connect to it (gdb, OpenOCD, St-Link Utility). But when you hold down the reset button, the pins default to their SWD configuration. Upon releasing the reset button again, they will return to however they have been configured in the code (essentially disabling their SWD functinoality). So I had to click the mass erase button in ST-Link while holding down the FMU reset button and then when I released the reset button, ST-Link performed a mass erase and I could flash the PX4 bootloader and install the firmware again.

hope you have been able reflash the bootloader…just erase the sd card first and after this install the firmware.
just in case im here…
happy fly

Thanks Dave,

Yep, I’ve re-flashed the bootloader. Why do I need to erase the SD card before flashing the firmware?

after every bootloader refresh i prefer erase sd so all systems is clean