cancel
Showing results for 
Search instead for 
Did you mean: 

STM32g031 deep sleep

NFahi.1
Associate II

Hello all!

I am trying to play with the deep sleep mode of the stm32g031f8p6.

Now i am using this: 

To sleep:

 SystemClock_Decrease();

  HAL_PWREx_ControlVoltageScaling(PWR_REGULATOR_VOLTAGE_SCALE2);

  HAL_PWREx_EnableLowPowerRunMode();

To wake up:

HAL_PWREx_DisableLowPowerRunMode();

SystemClock_Config();

But this is not enough. This is consuming now 400uA. Is there another sleep mode, or another procedure to reduce the power consumption?

thank you so much!

best regards!

3 REPLIES 3
Mohamed Aymen HZAMI
ST Employee

Hello @NFahi.1​,

You can take a look at the datasheet here section "5.3.5 Supply current characteristics" in order to define which mode you need to use with the needed power consumption.

Best Regards,

Mohamed Aymen.

Uwe Bonnes
Principal II

Only with a WFE() or WFI(0 you really enter the sleep mode.

Mohamed Aymen HZAMI
ST Employee

Hello @Niko Fabian​,

Did you tried my proposal ? Does it work?

Thanks and Best Regards,

Mohamed Aymen.