cancel
Showing results for 
Search instead for 
Did you mean: 

STM32F103 standby High Impedance problem

GunkutA
Senior

Hello I need to use standby mode for my MCU which is STM32F103. In datasheets it says that when MCU is in the standby mode, pins are left in the High Impedance. However, I need these pins to be High ( these are output pins). Is it possible to achieve that? Or should I go with sleep mode or maybe low power consumption mode?

Edit : And are there any coding examples for STM32F1xx to show how to enter Low Power Sleep Mode? Such as this one:

https://www.digikey.com/eewiki/display/microcontroller/Low-Power+Modes+on+the+STM32L0+Series#:~:text=The%20STM32L0%20devices%20implement%20five,%2C%20and%20wake%2Dup%20sources.

1 ACCEPTED SOLUTION

Accepted Solutions
TDK
Guru

>  However, I need these pins to be High ( these are output pins). Is it possible to achieve that?

No, they can't be high while in standby mode.

There are some families where pins can be configured as pullups while in low-power modes, but the STM32F1 is not one of them.

>  And are there any coding examples for STM32F1xx to show how to enter Low Power Sleep Mode?

https://github.com/STMicroelectronics/STM32CubeF1/tree/master/Projects/STM32F103RB-Nucleo/Examples/PWR/PWR_STANDBY

If you feel a post has answered your question, please click "Accept as Solution".

View solution in original post

4 REPLIES 4
TDK
Guru

>  However, I need these pins to be High ( these are output pins). Is it possible to achieve that?

No, they can't be high while in standby mode.

There are some families where pins can be configured as pullups while in low-power modes, but the STM32F1 is not one of them.

>  And are there any coding examples for STM32F1xx to show how to enter Low Power Sleep Mode?

https://github.com/STMicroelectronics/STM32CubeF1/tree/master/Projects/STM32F103RB-Nucleo/Examples/PWR/PWR_STANDBY

If you feel a post has answered your question, please click "Accept as Solution".

Thank you for your answer. So it looks like it is my best bet to use Low Power Sleep Mode. It says before I put MCU into LPSleep, I need to set system clock to 131 khz. But I cannot do it in run time. And from the link I couldn't find any example about LPSleep mode. May you share any example related to LPSleep if there is any? And how can I change the system clock to 131 khz while run time, before putting MCU to LPSleep mode?

TDK
Guru

> May you share any example related to LPSleep if there is any?

https://github.com/STMicroelectronics/STM32CubeF1/blob/441b2cbdc25aa50437a59c4bffe22b88e78942c9/Projects/STM32VL-Discovery/Examples/PWR/PWR_SLEEP

If you feel a post has answered your question, please click "Accept as Solution".
MM..1
Chief III

I mean you need STOP mode