@maxgerhardt & @jcw Thank you for your suggestions.
Ultimately, this is an issue with the dev board’s USB 2.0 not working with the USB chip on the Macbook Air M2 (other macs have this problem too). Using a USB 3.0 hub solved the problem:
Nucleo Dev Board → USB 3.0 Hub → Macbook Air M2
See my ST Community post:
Prior to discovering the solution, I did update the OpenOCD to the latest release. As a newbie, it took me some time, with the help of Copilot, to get Platform IO to use the latest release I installed. Addtionally, as @jcw suggested, I installed stlink, after installing Homebrew.
In the end…here is what my platformio.ini looks like:
[env:nucleo_wl55jc]
platform = ststm32
board = nucleo_wl55jc
framework = arduino
debug_tool = stlink
upload_protocol = stlink
upload_command = /Users/vikingvoltage/Documents/PlatformIO/tools/xpack-openocd-0.12.0-6/bin/openocd -f interface/stlink.cfg -f target/stm32wlx.cfg -c "adapter speed 200" -c "program .pio/build/nucleo_wl55jc/firmware.elf verify reset exit"
openocd-0.12.0-6/bin/openocd
upload_port = dev/cu.usbmodem1103
monitor_port = /dev/cu.usbmodem1103
monitor_speed = 115200
lib_deps =
stm32duino/STM32duino Low Power@^1.4.0
jgromes/RadioLib@^7.1.2
Just to be informative for others, this is what the output looks like when uploading a program:
Advanced Memory Usage is available via "PlatformIO Home > Project Inspect"
RAM: [ ] 3.2% (used 2100 bytes from 65536 bytes)
Flash: [== ] 19.0% (used 49816 bytes from 262144 bytes)
Configuring upload protocol...
AVAILABLE: cmsis-dap, jlink, mbed, stlink
CURRENT: upload_protocol = stlink
Uploading .pio/build/nucleo_wl55jc/firmware.elf
xPack Open On-Chip Debugger 0.12.0+dev-01850-geb6f2745b-dirty (2025-02-07-12:10)
Licensed under GNU GPL v2
For bug reports, read
http://openocd.org/doc/doxygen/bugs.html
Info : auto-selecting first available session transport "dapdirect_swd". To override use 'transport select <transport>'.
none separate
Info : STLINK V3J15M7 (API v3) VID:PID 0483:374E
Info : Target voltage: 3.247619
Info : Unable to match requested speed 500 kHz, using 200 kHz
Info : Unable to match requested speed 500 kHz, using 200 kHz
Info : clock speed 200 kHz
Info : stlink_dap_op_connect(connect)
Info : SWD DPIDR 0x6ba02477
Info : [stm32wlx.cpu0] Cortex-M4 r0p1 processor detected
Info : [stm32wlx.cpu0] target has 6 breakpoints, 4 watchpoints
Info : [stm32wlx.cpu0] Examination succeed
Info : [stm32wlx.cpu0] starting gdb server on 3333
Info : Listening on port 3333 for gdb connections
Info : Unable to match requested speed 500 kHz, using 200 kHz
Info : Unable to match requested speed 500 kHz, using 200 kHz
[stm32wlx.cpu0] halted due to breakpoint, current mode: Thread
xPSR: 0x01000000 pc: 0x0800a22c msp: 0x20010000
** Programming Started **
Info : device idcode = 0x10036497 (STM32WLE/WL5x - Rev 'unknown' : 0x1003)
Info : RDP level 0 (0xAA)
Info : flash size = 256 KiB
Info : flash mode : single-bank
Info : Padding image section 1 at 0x0800c414 with 4 bytes (bank write end alignment)
Warn : Adding extra erase range, 0x0800c418 .. 0x0800c7ff
** Programming Finished **
** Verify Started **
** Verified OK **
** Resetting Target **
Info : Unable to match requested speed 500 kHz, using 200 kHz
Info : Unable to match requested speed 500 kHz, using 200 kHz
shutdown command invoked
--- Terminal on /dev/cu.usbmodem1103 | 115200 8-N-1
The "Info: Unable to match requested speed… " can be ignored. It is not an issue. I tried using -c ‘adapter speed 200’ in the .ini to set the speed to suppress these messages:
upload_command = /Users/vikingvoltage/Documents/PlatformIO/tools/xpack-openocd-0.12.0-6/bin/openocd -f interface/stlink.cfg -f target/stm32wlx.cfg -c "adapter speed 200" -c "program .pio/build/nucleo_wl55jc/firmware.elf verify reset exit" -c "adapter speed 200"
…but that will only suppress the first set of “Info: Unable to match requested speed…” My understanding, and experience so far, is that it is a non-issue.