2022-12-05 03:13 AM
Hi,
I trying to debug on nucleo-WL55 with serial wire debug via SWO.
I have enable "Serial Wire Viewer (SWV)" in debug config, and add SWV ITM Data console (Config 0).
Even add this code :
int _write(int file, char *ptr, int len)
{
/* Implement your write code here, this is used by puts and printf for example */
int i=0;
for(i=0 ; i<len ; i++)
ITM_SendChar((*ptr++));
return len;
}
With this line : printf("HelloWorld");
Did you know why it doesn't work? Is that possible to have serial wire on WL-55 ? I have all jumper on JP8 as we receive the nucleo-WL55.
My config :
Thanks
2022-12-06 06:31 AM
Hello,
It is stilling not worked? so let's try to make those suggestions:
Could you please open SWV trace (just enable sampling PC) and check:
Wijeden,
2022-12-07 12:13 AM
Still nothing, Are we agree that we don't have to modify nucleo-WL to have serial wire ? And use it as we receive it ?
2022-12-08 02:27 AM
Hello @LEdou.1 ,
Let's try to make those suggestions:
Could you please open SWV trace (there just enable pc sampling)
Wijeden,
2022-12-08 06:28 AM
Hello,
It is stilling not worked? so let's try to make those suggestions:
Could you please open SWV trace (just enable sampling PC) and check:
Wijeden,
2022-12-15 06:22 AM
Still not working...
Nothing on SWV Data Trace and nothing on SWV ITM Data Console.
Like you said, I have add "ITM_SendChar((*ptr++));" and "#include "stm32wlxx.h"" on syscalls.c
I don't understand why it dosen't work. Did you have a exemple project, which work ?
2022-12-15 06:42 AM
Hi,
You could see this example in the screenshot bellow using CubeIDE 1.10.1 and NUCLEO-F429ZI.
Wijeden,
2022-12-16 08:17 AM
Hello,
I am pretty sure you have to look at the schematic of the nucleo, there is a solder bridge to set or to remove.
I don't have the board here to look but I am sure I did a hardware modification for the swo pin to be redirected to the STLink.
I just looked on the schematics, so it will depends on the hardware version you have, you can see the PB3/SWO pin has a DNF (Do Not Fit) solder bridge SB8 for SWO.
So, you must unsolder the SB31 that is set for ARD_PB3 and put it in place on SB8 for SWO.
Or, if not using the ARD_PB3 pin on Morpho connector, you can let the solder bridge SB31 and add one on the DNF (SB8) to have T_SWO connected.
SB numbers can vary on the hardware versions.
Rgds,
Laurent
2022-12-19 06:41 AM
Thanks @LaurentL ans @Wijeden RHIMI, my bad effectively, it was SB8 ! From de beginning I confused between SWDIO and SWO ... Sorry ! Tanks a lot again !