Page 1 of 1

standby or deepsleep mode for stm32f103

Posted: 29 Sep 2023 14:26
by zezo2060
hi
can you plz support to provide a working example for standby or deepsleep mode for stm32f103 with wakeup??

thank you

Re: standby or deepsleep mode for stm32f103

Posted: 06 Oct 2023 11:19
by IvanJeremic
Hi,

I will see if i can find the same MCU and write an example, since we don't have that.

But basically you need to use ASM mode:
https://download.mikroe.com/documents/c ... ration.htm

Below is a manual that will help you with the coding:
https://www.st.com/resource/en/programm ... ronics.pdf

Regards,

Ivan.

Re: standby or deepsleep mode for stm32f103

Posted: 06 Oct 2023 17:55
by Thomas.Pahl@t-online.de
with stm32f407 i do the following:

Code: Select all

SLEEPDEEP_Bit = 1
asm
       wfi
end asm
if your chip has a similar mechanism i do not know.

recovery from standby is not so simple since the 407 starts with internal RC-oscillator and a call to the startup sequence is necessary.