AnsweredAssumed Answered

Reset ULP bit after stop (STM32L1)

Question asked by Mark Ruys on May 14, 2018
Latest reply on Jun 19, 2018 by Mark Ruys

After I upgraded my application from mbed 5.4.7 to 5.7.7, my comparator is unreliable after a STOP. Basically, this is how the MCU is put into sleep (from xdot_low_power.c):

while ( ! LL_PWR_IsActiveFlag_VREFINTRDY() ) {};

I assume this has to do with V_REFINT being unstable after resuming the sleep condition.


All works good again when I add a call to HAL_PWREx_DisableUltraLowPower() after wake up. Although now I'm happy to have the comparator to work stable again after a stop, disabling the ULP bit in the PWR_CR register doesn't make sense to me when I read the datasheets. What am I missing here?


MCU is a STM32L151 (part of a Multitech xDot).