2023-02-05 12:38 PM
I bought ST-LINK/V2 from a certified reseller, and I have WIO-5E mini with STM32WL5JC from [Seeed.com](https://Seeed.com) on the board. This WIO-5E was already programmed by another ST-LINK/V2. I connected WIO-5E to ST-LINK as required. I want to reprogam WIO-5MINI using this programator. But STM32Programmer answered:
What should I do so STM32Programmer will see STM32WL5CJ from the WIO-5E mini board?
2023-02-06 05:23 AM
How is this connected? Like before?
VCC 3.3V
GND
SWDIO
SWCLK
NRST
If NRST is connected then "connect under reset" will work without you needing to press a button.
2023-02-06 06:02 AM
I have only four wires: VCC 3,3V, SWDIO, SWCLK, and GND on ST-LINK/V2. They all are connected as required to the WIO-5E mini. I don't have NRST wire.
2023-02-06 06:09 AM
I can't.
What should I do to upgrade the firmware?
2023-02-06 09:44 AM
@Peter BENSCH
I upgraded the firmware with a stupid trick. I unplug the USB cable from ST-LINK, count for up to 6 sec, plug the USB into it, count again for up to 6 sec, and press on upgrade firmware button.
Firmware upgraded to the requested version.
But still can't connect to the WIO-5E mini. Still the same message:
Error: No STM32 target found!
I can connect to WIO-5E only when pressing and holding the reset button. When I release this button, I get:
18:30:50 : Error: Unable to get core ID
18:30:50 : Error: Unable to get core ID
18:30:50 : Error: Unable to get core ID
18:30:50 : Warning: Connection to device 0x497 is lost
18:30:51 : Disconnected from device.
Maybe this information will be helpful. Previously downloaded code into WIO-5E sill running, red diode blinks every one second. When I press the reset button, the diode stops blinking.
2023-02-07 12:44 AM
>I upgraded the firmware with a stupid trick
No. thats what you should do, to "start in update mode " .
> Previously downloaded code into WIO-5E sill running,
AAA, new info. It was working before ??
so just look, what you set in option bytes. there is something , that disables SWD , i suppose.
or in your program -> using the SWD+SWC pins for something, change their mode;
+ you set in Cube : SWD ?
2023-02-07 05:33 AM
@AScha.3 Here is my view:
It looks completely different from your's view.
But I can't understand the relation between the configuration of an application and trying to connect ST-LINK to WIO-5E mini (with STM32WL5JC chip on the board)
2023-02-07 06:26 AM
ok, (pic was from F072 cpu) , on your WL5x cpu the relevant pins can be set to different functions, if you want SWD debug connect, you must set PA13 + PA14 to SWD+SWC function. otherwise they will do, whatever is set to them.
if you just want flash/load program, maybe you should try bootloader mode and flash this way.
2023-02-07 06:45 AM
so - what you did ? already killed the firmware ?
2023-02-07 07:15 AM
Yes, the firmware was cleared, and the protecion level was set up to AA. After that, I might upload code (.hex) to WIO-5 min. In the beginning, I would ask the chip using AT commands. After clearing the firmware, it's obvious that I can't ask with AT command. But I might program this chip. I saw that WIO-5 contacts to Chirpstack gateway.
2023-02-07 10:54 AM
so...i hope, you know, what you are doing. :)
maybe, you have to set option bytes , or set swd on start of your program, to have it always available (to connect by STlink -> SWD ) and debug or load program.