Anyone has experience with STM HID Bootloader? I am stuck with this issue:

TWIMC:

This is a minimal working solution for me:

platformio.ini:

[env:bluepill_f103c8]
platform = ststm32
board = bluepill_f103c8
framework = arduino
upload_protocol = hid
build_flags =
  -D PIO_FRAMEWORK_ARDUINO_ENABLE_CDC

Getting HID bootloader (stm32_binaries.zip)

Installing via stlink

cd stm32_binaries/F103/low_and_medium_density
st-flash write hid_generic_pc13.bin 0x8000000

Make sure that the tool is there

pio pkg install -g -t "platformio/tool-stm32duino"

Make sure that hid-flash is there, then upload as usual

pio run -t upload

PS The Docs somehow doesn’t mention the HID bootloader, which cost me my pound of flesh. Or, at least, an ounce.

1 Like