cancel
Showing results for 
Search instead for 
Did you mean: 

Help to use PA15 as GPIO Output on NUCLEO-L476RG

DZado.2
Associate II

Hi,

 I am a newbie with STM32. I need help.

I want to configure that PA15 pin (which by default is used as JTDI), as a GPIO output.

I've added the following two lines to the beginning of the generated code of MX_GPIO_Init():

LL_GPIO_SetAFPin_8_15(GPIOA,LL_GPIO_PIN_15,LL_GPIO_AF_5);

LL_GPIO_SetPinMode(GPIOA,LL_GPIO_PIN_15,LL_GPIO_MODE_OUTPUT);

But it does not work. I connected a LED and tried to change the state of the pin high and low,

but it did not work.

I appreciate if someone help me to figure out what I am missing.

Thanks

10 REPLIES 10
DZado.2
Associate II

Thanks a lot Karl and gbm.

You solved my issue.

Happy new year