I want to use a GPIO pin which is configured to be "Analog Mode" for ADC.

I am working on STM32L073 series microcontroller. The pins with ADC input channels are used already. So I need to choose another pin to use ADC.

I could not find any information about how to use the analog mode gpio pin for ADC.

Is there anyway to configure a GPIO pin other than the pins with ADC input channels for ADC?

  • \$\begingroup\$ Is your board already made? You could use an external ADC or swap pins so you can use the normal channel. Possibly also a relay or other switch if you don't need both functions at the same time. I don't know anything about this processor though, so maybe there's a special way to use any GPIO pin for the ADC... \$\endgroup\$
    – Justin
    Commented Jan 17, 2020 at 15:16

1 Answer 1


The pins with ADC input channels are used already.

The analog mode for a GPIO pad is just a multiplexer setting. You still need the internal wiring to the ADC, which is only available for pins specified with an ADC channel marked ADC_INxx as additional function in table 16 of the datasheet.


Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.