I’m struggling to get up and running with my NUCLEO WB15CC. The WB15CC isn’t available in PlatformIO, but I believe the pinout is the same as the NUCLEO WB55RG, which is available. I’m getting an OpenOCD upload error which I will post below.
Could it be this issue? I can’t figure out how to access the board configuration .json file on Mac to check if it is the updated file described here or the old version. I did set up platformIO recently so would think it would be the most updated version.
Just trying to run the blinky example.
Thanks in advance!
Verbose mode can be enabled via `-v, --verbose` option
PLATFORM: ST STM32 (15.4.1+sha.76958b4) > P-Nucleo WB55RG
HARDWARE: STM32WB55RG 64MHz, 192KB RAM, 512KB Flash
DEBUG: Current (stlink) On-board (stlink) External (blackmagic, cmsis-dap, jlink)
- framework-arduinoststm32 @ 4.20200.220530 (2.2.0)
- framework-cmsis @ 2.50700.210515 (5.7.0)
- tool-dfuutil @ 1.11.0
- tool-openocd @ 2.1100.211028 (11.0)
- tool-stm32duino @ 1.0.1
- toolchain-gccarmnoneeabi @ 1.90201.191206 (9.2.1)
LDF: Library Dependency Finder -> https://bit.ly/configure-pio-ldf
LDF Modes: Finder ~ chain, Compatibility ~ soft
Found 12 compatible libraries
Building in release mode
Checking size .pio/build/nucleo_wb55rg_p/firmware.elf
Advanced Memory Usage is available via "PlatformIO Home > Project Inspect"
RAM: [ ] 0.5% (used 908 bytes from 196608 bytes)
Flash: [ ] 2.9% (used 15088 bytes from 524288 bytes)
Configuring upload protocol...
AVAILABLE: blackmagic, cmsis-dap, jlink, stlink
CURRENT: upload_protocol = stlink
xPack OpenOCD x86_64 Open On-Chip Debugger 0.11.0+dev (2021-10-17-00:18)
Licensed under GNU GPL v2
For bug reports, read
srst_only separate srst_nogate srst_open_drain connect_deassert_srst
target halted due to debug-request, current mode: Thread
xPSR: 0x01000000 pc: 0x080044d8 msp: 0x20030000
** Programming Started **
Warn : Adding extra erase range, 0x08003c48 .. 0x08003fff
Error: block write failed
Error: error writing to flash at address 0x08000000 at offset 0x00000000
embedded:startup.tcl:1070: Error: ** Programming Failed **
in procedure 'program'
in procedure 'program_error' called at file "embedded:startup.tcl", line 1135
at file "embedded:startup.tcl", line 1070
*** [upload] Error 1
You’re right, the upload was successful when using the mbed protocol.
The code still does not seem to be running. The pin names for WB15CC and WB55RG seem to be identical for both boards, ruling out pin mapping issues?
Here is my Arduino code I’m trying to run, just in case I’m missing something painfully obvious. Appreciate the help!
#define LED1 PB_5
// initialize LED digital pin as an output.
// turn the LED on (HIGH is the voltage level)
// wait for a second
// turn the LED off by making the voltage LOW
// wait for a second
Hm, the Arudino STM32 core seems buggy with regards to WB15xx support. THere are compiler errors in the timer.c and analog.cpp files referencing interrupts and struct subfields that this series does not have. Furthermore it doesn’t have the right linkerscript for it. I’ll have to do some digging.
Currently I have a board/genericSTM32WB15CC.json file of
C:\Users\XXXX.platformio\packages\framework-arduinoststm32\cores\arduino\stm32/timer.h:51:19: error: ‘TIM1_UP_TIM16_IRQn’ undeclared (first use in this function); did you mean ‘TIM1_UP_IRQn’?
51 | #define TIM1_IRQn TIM1_UP_TIM16_IRQn
C:\Users\XXXX.platformio\packages\framework-arduinoststm32\libraries\SrcWrapper\src\stm32\analog.cpp:878:18: error: ‘struct ADC_InitTypeDef’ has no member named ‘NbrOfDiscConversion’; did you mean ‘NbrOfConversion’?