cancel
Showing results for 
Search instead for 
Did you mean: 

Why is PA4 by default input when all other pins (except SWCLK and SWDIO) are analog?

Pieter Conradie
Associate III

On the STM32L072 series, the reset state of all the pins are "Analog mode", except for PA4, PA13 (SWDIO) and PA14 (SWCLK).

When I put the STM32 into STOP mode, PA4 (configured as an input) causes the current consumption to increase by ~10uA. When I configure it as analog, the current consumption goes down to an acceptable 1.7uA (with 32 kHz crystal running).

I would like to know why PA4 is configured as an input after reset. One of it's alternative functions are "DAC_OUT1"... could this be the reason?

Thanks in advance,

Pieter

0690X000008AnVfQAK.png

1 ACCEPTED SOLUTION

Accepted Solutions
Amel NASRI
ST Employee

Hi @Pieter Conradie​ ,

In the footnote of the pinout table, we mention that PA4 is a "spacial" pin:

"PA4 offers a reduced touch sensing sensitivity. It is thus recommended to use it as sampling capacitor I/O."

That is why it has this reset value in GPIOA_MODER register.

-Amel

To give better visibility on the answered topics, please click on Accept as Solution on the reply which solved your issue or answered your question.

View solution in original post

1 REPLY 1
Amel NASRI
ST Employee

Hi @Pieter Conradie​ ,

In the footnote of the pinout table, we mention that PA4 is a "spacial" pin:

"PA4 offers a reduced touch sensing sensitivity. It is thus recommended to use it as sampling capacitor I/O."

That is why it has this reset value in GPIOA_MODER register.

-Amel

To give better visibility on the answered topics, please click on Accept as Solution on the reply which solved your issue or answered your question.