Skip to main content
TAkha
Visitor II
August 29, 2019
Question

I was able to enter Low Power without going through low power run? How?

  • August 29, 2019
  • 0 replies
  • 349 views

I have the system clock set as 120Mhz. I used the HAL driver code, HAL_PWR_EnterSLEEPMode, to enter Low power sleep mode. However, when it checks if it's in run mode, it doesn't recognise its actually in run mode.

  /* If in run mode, first move to low-power run mode.

    The system clock frequency must be below 2 MHz at this point. */

  if (HAL_IS_BIT_SET(PWR->SR2, PWR_SR2_REGLPF) == RESET)

  {

    HAL_PWREx_EnableLowPowerRunMode(); // this never execute.

  }

When it wakes up, the clock speed is still in 120Mhz?

Can anyone help explain me this behaviour? I am using STM32L4R5QII6P processor.

This topic has been closed for replies.