cancel
Showing results for 
Search instead for 
Did you mean: 

STM32G473 Unable to use PA15 as GPIO when debugging in SWD mode

KevLannen
Associate

I have a board with a CAN transceiver connected to a STM32G473RE using PA8 and PA15 for RX and TX. When I configure the GPIO for PA15 into AF11 to enable the CAN module, I lose connection with my STLink debugger. (I am using the STLink built into a Nucleo-F207 board)

For debug I am using SWD so the PA15 JTDI pin should not be needed. What steps need to be taken to release this pin so that it can be used for other functions?

To easily reproduce, I created a project in STM32Cube where I just enabled CAN on those two pins and generated the code.

1 ACCEPTED SOLUTION

Accepted Solutions
KevLannen
Associate

Hi JW,

Thanks for the suggestions, I double checked the PCB and did find a short between PA15 and the SWCLK. Clearing that short seems to have fixed by issue.

Thanks,

Kevin

View solution in original post

2 REPLIES 2

>When I configure the GPIO for PA15 into AF11

How exactly?

Make sure you don't change also PA14/PA13 bits in GPIO registers.

Check if there's no short in hardware.

JW

KevLannen
Associate

Hi JW,

Thanks for the suggestions, I double checked the PCB and did find a short between PA15 and the SWCLK. Clearing that short seems to have fixed by issue.

Thanks,

Kevin