From 36b124c4ecb2bea70244142d2bc2883ca702886c Mon Sep 17 00:00:00 2001 From: Michal Demin Date: Fri, 2 Aug 2024 20:18:44 +0200 Subject: [PATCH] stlinkv3: improve flashing documentation --- src/platforms/stlinkv3/README.md | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/src/platforms/stlinkv3/README.md b/src/platforms/stlinkv3/README.md index 7258e8ad2c3..d35b77ff6c3 100644 --- a/src/platforms/stlinkv3/README.md +++ b/src/platforms/stlinkv3/README.md @@ -47,6 +47,13 @@ meson setup build --cross-file=cross-file/stlinkv3.ini meson compile -C build ``` +If you are building for bootloader you need to add option `-Dbmd_bootloader=true` +```sh +meson setup build --cross-file=cross-file/stlinkv3.ini -Dbmd_bootloader=true +meson compile -C build +``` + + ## Flashing Easiest is using the BMP bootloader. Load the BMP firmware easiest with scripts/stm32mem.py or dfu-utils. BMP bootloader must be flashed with SWD @@ -65,6 +72,9 @@ Revert to original ST firmware with `java -jar STLinkUpgrade.jar` Try to use old version that do not disable SWD access. Expect newer ST firmware even to be more restrictive. +If you did not build with bootloader option enabled flashing this firmware will "soft" brick stlink. While the stlink v3 is plugged into usb +use tweezers to short CN4 (2 pins next to the USB connector) this will force bootloader mode. On STLINK-V3MINIE version its TP1 and TP2 on the bottom. + ## What remains to be done? - Improve and document LED indication