Skip to main content
Pieter Conradie
Associate III
April 23, 2019
Solved

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

  • April 23, 2019
  • 1 reply
  • 1560 views

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

This topic has been closed for replies.
Best answer by Amel NASRI

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

1 reply

Amel NASRI
Amel NASRIBest answer
Technical Moderator
April 23, 2019

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 "Best Answer" on the reply which solved your issue or answered your question.