cancel
Showing results for 
Search instead for 
Did you mean: 

STM32WB5MM not reaching deep sleep (STOP2/Standby) – still consuming 20 mA

dineDK2
Associate

Hello,

I am working on STM32WB5MM custom hardware and trying to implement deep sleep mode using RTC wakeup interrupt.

 

What I want to achieve:

  • MCU should stay active for ~30 seconds after reset.

  • Then enter deep sleep / STOP2 mode.

  • Wake up automatically every 30 seconds using RTC wakeup timer interrupt.

  • Expected current in STOP2 / Standby mode = < 1 mA (microamp level).

What is happening:

  • In normal running mode, MCU current ≈ 30 mA (okay).

  • When I put MCU into STOP2 mode, it still consumes ≈ 20 mA, instead of going down to microamps.

  • I am not sure if MCU is really entering STOP2/Standby or staying partially active.

  • while (1)
    {
    HAL_Delay(30000);

    HAL_RTCEx_DeactivateWakeUpTimer(&hrtc);
    HAL_RTCEx_SetWakeUpTimer_IT(&hrtc, 30, RTC_WAKEUPCLOCK_CK_SPRE_16BITS);

    HAL_SuspendTick();
    HAL_PWREx_EnterSTOP2Mode(PWR_STOPENTRY_WFI);

    SystemClock_Config();
    HAL_ResumeTick();

    HAL_RTCEx_DeactivateWakeUpTimer(&hrtc);

    if (wakeupFlag == 1)
    {
    wakeupFlag = 0;
    // Do something on wakeup
    }
    }

Question:

  1. Is this the correct way to put STM32WB5MM into deep sleep (STOP2) with RTC wakeup?

  2. Why is the current still ~20 mA instead of microamps?

  3. Do I need to disable any peripherals/clocks (e.g., HSI, HSE, GPIO, debug, etc.) before STOP2?

  4. Any hardware considerations for STM32WB5MM to achieve low-power STOP2?

0 REPLIES 0