cancel
Showing results for 
Search instead for 
Did you mean: 

Debug losing connection with Stm32WB55 target

GYV
Visitor

Code is written using stm32CubeMX. Connecting with stmlink V3 Minie. 
Executing step by step, it appears that debug fails (lose connection) when executing debug_init. In fact debug_init creates the problem when programming pa13.
When removing the initialization of PA13 and PA14 in debug init, things seems to work but I have no idea of potential side effect. 
An recommendation?

2 REPLIES 2
TDK
Super User

Please include the IOC that generates the problematic code.

If you feel a post has answered your question, please click "Accept as Solution".
Andrew Neil
Super User

Welcome to the forum.

Please see How to write your question to maximize your chances to find a solution for best results.

In particular, please give details of your setup.

 


@GYV wrote:

debug fails (lose connection) when executing debug_init. In fact debug_init creates the problem when programming pa13.


Please show that code. See: How to insert source code

 

PA13 & PA14 carry the SWD signals (ie, the signals the debugger uses to communicate) - so messing with them will break the debugger connection!

AndrewNeil_0-1770136701144.png

https://www.st.com/resource/en/datasheet/stm32wb55rg.pdf#page=65

via: https://www.st.com/en/microcontrollers-microprocessors/stm32wb55rg.html#documentation

 

A complex system that works is invariably found to have evolved from a simple system that worked.
A complex system designed from scratch never works and cannot be patched up to make it work.