px-fwlib 0.10.0
Cross-platform embedded library and documentation for 8/16/32-bit microcontrollers generated with Doxygen 1.9.2
Low Power STOP Mode Example

This demonstrates how to put the STM32 into STOP low power mode.


The following modules are used:

The STM32 is woken up from low power STOP mode while the 6/NO button is pressed. The LCD displays an incrementing counter value that tracks the number of times that the button has been pressed. The external peripherals (Serial FLASH, LCD and LCD backlight) and specific GPIO pins (SD Card detect, UART2, I2C and UART4) are put into the lowest power state to minimise power consumption.


  1. RM0376: Ultra-low-power STM32L0x2 advanced Arm-based 32-bit MCUs
  2. PM0223: STM32L0 Series and STM32G0 Series Cortex M0+ programming manual
  3. ES0293: STM32L072x8/B/Z device limitations

The reference documents can also be found here for off-line viewing:


For more information, see:

  • Digi-Key Low-Power Modes on the STM32L0 Series
  • [1] "6.3 Low-power modes", page 151
  • [1] "13 Extended interrupt and event controller (EXTI)", page 282
  • [2] "2.5 Power management", page 33
  • [3] "2.15 Flash memory wakeup issue when waking up from Stop or Sleep with Flash in power-down mode", page 11
  • [3] "2.1.6 Unexpected system reset when waking up from Stop mode with regulator in low-power mode", page 11
  • [3] "2.1.8 I2C and USART cannot wake up the device from Stop mode", page 12