Skip to main content
KevLannen
Associate
February 24, 2021
Solved

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

  • February 24, 2021
  • 2 replies
  • 904 views

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.

This topic has been closed for replies.
Best answer by KevLannen

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

2 replies

waclawek.jan
Super User
February 25, 2021

>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
KevLannenAuthorBest answer
Associate
February 25, 2021

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