9. Power control (PWR)

The power control (PWR) chapter provides an overview of the different power domains, and the power supply configuration.

It describes the power supply supervisor features and the control of the \(V_{DDCORE}\) and \(V_{DDCPU}\) supply domains according to the operating modes. In the PWR section, the Cortex®-A7 is called MPU.

9.1 PWR main features

9.2 PWR block diagram

Figure 27. Power control block diagram

Figure 27. Power control block diagram

The diagram illustrates the Power Control (PWR) block and its interactions with external power sources and other system components. The PWR block is a central unit containing several sub-modules: a Register interface, POR/PDR, Backup domain, VBAT charging, PWR control, WAKEUP, PVD & AVD, BOR, VBAT thresholds, TEMP thresholds, and Power managment. External power inputs include VDDSD1, VDDSD2, VDD3V3_USBHS, VDDA1V1_REG, VDD, VDDA1V8_REG, VDDCPU, VDDCORE, VBAT, VSS, VDDA, VSSA, WKUP[6:1], and PVD_IN. These inputs feed into various detectors (3V3 USB Detector, VDDSD2 Detector, VDDSD1 Detector), regulators (1V1 Regulator, 1V8 Regulator), and the internal PWR components. The PWR block communicates with the RCC (via rcc_pwr_sec), MPU (via hclk4, pwrwake_mpu, pwrwake_sys, and a GIC interface), and EXTI (via wakeup events). Status signals like vddcore_ok, vddcpu_ok, nrst_por, vcore_rdy, vcpu_rdy, por_vsw, nrst_bor, sys_ds_exit, and mpu_ds_exit are exchanged between the PWR block and other system components. The PWR block also features a Register interface with multiple control and status registers (reg18en, reg18rdy, reg11en, reg11rdy, usb33den, usb33rdy, vddsd1den, vddsd1rdy, vddsd2den, vddsd2rdy) connected to the AHB bus.

Figure 27. Power control block diagram

MSv65228V3

9.2.1 Pin overview

Table 29. PWR pin overview
Pin nameI/ODescription
VDDPMain IO and VDD domain supply input
VDD_PLLPPLLs supply input, must be connected to VDD(not used by PWR)
VBATPBackup battery supply input
VDDCOREPCore domain supply
VDDCPUPMPU domain supply
VDDAPAnalog domain supply
VDDA1V8_REGP1V8 regulator supply output
VDDA1V1_REGP1V1 regulator supply output
VDD3V3_USBHSPUSB HS PHY 3V3 supply input, must be connected to VDD3V3_USBHS (not used by PWR)
VDDSD1PSDMMC1 SDCard GPIO power supply (can be connected to VDD or provided by dedicated supply to avoid external driver need in Ultra High Speed I (UHS-I) mode(1))
VDDSD2PSDMMC2 SDCard GPIO power supply (can be connected to VDD or provided by dedicated supply to avoid external driver need in Ultra High Speed I (UHS-I) mode(1))
VDDQ_DDRPDDR PHY supply input (not used by PWR)
VSSPMain ground
VSSAPAnalog ground
VSS_USBHSPUSB HS PHY ground (not used by PWR)
AHBI/OAHB register interface
PWR_ON(2)OCore and MPU supplies enable output (STPMICx regulator used)
Core supply enable output (non STPMICx regulators are used)
PWR_CPU_ONOMPU supply enable output (non STPMICx regulators are used)
PWR_LPOCore and MPU supplies Low-power Stop mode selection output (non STPMICx regulators are used)
PDR_ONIVDD Power On Reset enable (must always be connected to VDD)
NRSTIOApplication pad reset input/output
BYPASS_REG1V8I1V8 regulator bypass (must be set to 1 when VDD = 1.8 V)
WKUP[6:1]IWakeup inputs
PVD_INIPVD external input
hclk4IPWR AHB bus clock input from RCC
pvdoOProgrammable voltage detector output
avdoOAnalog voltage detector output
nrst_porOVDD Power-on reset
nrst_borOVDD Brownout reset

Table 29. PWR pin overview (continued)

Pin nameI/ODescription
vddcore_okOVDDCORE ready
vddcpu_okOVDDCPU ready (can only be asserted when vddcore_ok is asserted)
sys_ds_exitISystem wakeup request from EXTI (sys_wakeup)
mpu_ds_exitIMPU wakeup request from EXTI (c1_wakeup)
mpu_cstandbyOMPU CStandby mode indication
pwrwake_mpuOClock wakeup request for MPU
mpu_int_wkupOWakeup interrupt to MPU
async_wkup[6:1]OAsynchronous wakeup to EXTI
rcc_pwr_secIPWR block secure state (from PWRSEC register bit in RCC)
  1. 1. GPIO's in the VDDSD1 and VDDSD2 power domains can be used for other functions than SDMMC (For more details refer to section "Pinouts, pin description and alternate functions" in the datasheet.
  2. 2. When STPMICx regulator is used, only PWR_ON signal is needed to indicate a change in Power mode to the STPMICx regulator.

9.3 PWR power supplies

The power supplies \(V_{DD}\), \(V_{DDCORE}\), \(V_{DDCPU}\), \(V_{DDA}\), \(V_{BAT}\), \(V_{DD1V8\_REG}\), \(V_{DD1V1\_REG}\), \(V_{DD3V3\_USBHS}\), \(V_{DDSD1}\), \(V_{DDSD2}\) and \(V_{DDQ\_DDR}\) are all independent. The device includes integrated regulators for specific functions:

Note: Depending on the operating power supply range, some peripheral may be used with limited functionality and performance. For more details refer to section “General operating conditions” in the datasheet.

Note: An external DDR memory is to be supplied from an external regulator which is NOT controlled by the PWR. When the system enters low-power modes it is up to the firmware to control the DDR memory supply directly through the external regulator. When the system enters Standby mode the PWR_ON pin may be used by the external DDR memory regulator to power down the DDR memory supply.


a. GPIO's in the \(V_{DDSD1}\) and \(V_{DDSD2}\) power domains can be used for other functions than SDMMC (For more details refer to section “Pinouts, pin description and alternate functions” in the datasheet.

Figure 28. Power supply overview

Figure 28. Power supply overview block diagram illustrating power domains (Core domain, MPU domain, VSW domain, VDD domain, Analog domain) and supply connections.

The diagram illustrates the power supply architecture of the RM0475 microcontroller, organized into several functional domains and power rails. At the top, external power rails are shown: VDDQ_DDR, VDD, VDDA1V1_REG, VDD3V3_USBHS, VSS_USBHS, VDDA1V8_REG, VDD, VDDSD1, and VDDSD2. These connect to various internal blocks. The Core domain (dashed box) includes System logic, Peripherals, and RAM, powered by VDDCPU and VDDCORE. The MPU domain (dashed box) contains the MPU and RAM, powered by VDDCPU. The VSW domain (dashed box) includes a Backup regulator, Backup RAM, and LSE, RTC, WUT, Tamper, backup registers, Reset, powered by VSW and VBAT. The VDD domain (dashed box) contains HSI, CSI, HSE, LSI, WKUP, IWDG, and PLLs, powered by VDD. The Analog domain (dashed box) includes REF_BUF and ADC, powered by VDDA. IO ports are distributed across the system, with specific IOs connected to the Core domain, VDD domain, and Backup domain. Regulators (1V1, 1V8, Backup) and power switches are used to manage power distribution between domains. The diagram also shows connections to external components like DDR PHY, USB HS PHY, and SDMMC IOs.

Figure 28. Power supply overview block diagram illustrating power domains (Core domain, MPU domain, VSW domain, VDD domain, Analog domain) and supply connections.

MSv65229V3

9.3.1 CORE and MPU power domains

VDDCORE and VDDCPU are provided from external regulators.

VDDCORE supplies all the digital circuitries except:

VDDCPU supplies the MPU domain.

Following a VDD power-on reset, the external regulators supplying VDDCORE and VDDCPU are enabled via PWR_ON and PWR_CPU_ON signals.

The external regulators may operate in different modes (Main, Low-power, Off) depending on the system operating modes (Run, Stop, LP-Stop, LPLV-Stop, LPLV-Stop2 and Standby) refer to Chapter 9.5.1: Operating modes.

9.3.2 Power supply system startup sequence

The system startup sequence is shown in Figure 29.

  1. 1. From power-on the POR monitors the \(V_{DD}\) supply. Once the supply is above the POR threshold level, the external voltage regulators providing the \(V_{DDCORE}\) and \(V_{DDCPU}\) supplies are enabled via the PWR_ON and PWR_CPU_ON signal after an internal \(t_{RSTTEMPO}\) delay. As long as the \(V_{DDCORE}\) is below the \(V_{TH\_VDDCORE}\) threshold, the system is kept in reset (refer to the datasheet for \(t_{RSTTEMPO}\) and \(V_{TH\_VDDCORE}\) values).
  2. 2. Once the \(V_{DDCORE}\) supply is above the \(V_{TH\_VDDCORE}\) threshold level, a delay \(t_{VDDCORE\_TEMPO}\) is inserted to wait that \(V_{DDCORE}\) has reached minimum operating value (refer to the datasheet for \(t_{VDDCORE\_TEMPO}\) and \(V_{DDCORE}\) minimum operating values).
  3. 3. The system is taken out of reset, where after the HSI oscillator is enabled. Once the \(V_{DDCPU}\) supply is above the \(V_{TH\_VDDCPU}\) threshold level, a delay \(t_{VDDCPU\_TEMPO}\) is inserted to wait that \(V_{DDCPU}\) has reached minimum operating value (refer to the datasheet for \(t_{VDDCPU\_TEMPO}\) and \(V_{DDCPU}\) minimum operating values).
  4. 4. Once the HSI oscillator is stable, the hardware initializes the system. A programmable EADLY[2:0] delay is used to make sure all bootable external interfaces are correctly supplied before the boot ROM starts accessing them. See Section 10: Reset and clock control (RCC) for details on EADLY[2:0] programming.
  5. 5. The Run mode is entered once vddcpu_ok signal is raised and hardware initialization is completed.

Figure 29. Device startup supply sequence

Timing diagram for device startup supply sequence showing VDD, nrst_por, PWR_CPU_ON, PWR_ON, PWR_LP, VDDCPU, vddcpu_ok, VDDCORE, vddcore_ok, and HSI signals over time. It includes POR threshold, t_RSTTEMPO, t_VDDCPU_TEMPO, t_VDDCORE_TEMPO, and EADLY[2:0] delay. The HSI signal shows states: Power down or VBAT mode, POR Reset, Wait HSI oscillator, HW system Init, and Run.

The diagram illustrates the device startup supply sequence. It shows the timing relationships between various signals and voltage levels during startup. Key events include the Power-on Reset (POR) threshold crossing, the assertion of \(\overline{\text{NRST\_POR}}\), and the sequential ramping of \(V_{\text{DDCPU}}\) and \(V_{\text{DDCORE}}\) to their respective thresholds. The vddcpu\_ok and vddcore\_ok signals indicate when each voltage domain is ready. The HSI signal transitions through several states: Power down or VBAT mode, POR Reset, Wait HSI oscillator, HW system Init, and finally Run. A timing parameter \(t_{\text{EADLY}[2:0]}\) delay is shown before the system enters the Run state. The diagram is labeled MSv65230V2.

Timing diagram for device startup supply sequence showing VDD, nrst_por, PWR_CPU_ON, PWR_ON, PWR_LP, VDDCPU, vddcpu_ok, VDDCORE, vddcore_ok, and HSI signals over time. It includes POR threshold, t_RSTTEMPO, t_VDDCPU_TEMPO, t_VDDCORE_TEMPO, and EADLY[2:0] delay. The HSI signal shows states: Power down or VBAT mode, POR Reset, Wait HSI oscillator, HW system Init, and Run.

9.3.3 VSW domain

To retain the content of the VSW domain (RTC, backup registers and backup RAM) when \(V_{\text{DD}}\) is turned off, VBAT pin can be connected to an optional standby voltage supplied from a battery or an another source.

Switching to the \(V_{\text{BAT}}\) supply (VBAT mode) is controlled by the power-down reset (PDR) embedded in the reset block, monitoring the \(V_{\text{DD}}\) supply.

Note: In order to retain the content of the VSW domain when \(V_{\text{DD}}\) is turned off, the power-down reset (PDR) must be enabled by the PDR\_ON pin (level high). Refer to Section 9.4.1: Power-on reset (POR)/power-down reset (PDR).

Warning: During \(t_{\text{RSTTEMPO}}\) (temporization at \(V_{\text{DD}}\) startup) or after a PDR is detected, the power switch between \(V_{\text{BAT}}\) and \(V_{\text{DD}}\) remains connected to \(V_{\text{BAT}}\).
During the startup phase, if \(V_{\text{DD}}\) is established in less than \(t_{\text{RSTTEMPO}}\) (refer to the datasheet for the value of \(t_{\text{RSTTEMPO}}\)) and \(V_{\text{DD}} > V_{\text{BAT}} + 0.6 \text{ V}\), a current may be injected into \(V_{\text{BAT}}\) through an internal diode connected between \(V_{\text{DD}}\) and the

power switch (VBAT).

If the power supply/battery connected to the VBAT pin cannot support this current injection, it is strongly recommended to connect an external low-drop diode between this power supply and the VBAT pin.

When the VDD supply is present, the VSW domain is supplied from VDD. This allows to save VBAT power supply battery life time.

If no external backup battery is used in the application, it is recommended to connect VBAT externally to VDD.

Whenever the VDD supply is present and above the PDR threshold, the backup domain IOs are supplied by VDD and some functions are available according Table 30:

Table 30. VSW domain functions when VDD is present

Pin nameGPIO(1)LSERTCTAMPER_OUT(2)TAMPER_IN(2)WAKEUP
PC14, PC15XX----
PC13X-x(3)XXx (WKUP3)
PI2
PI3
X--XXx (WKUP5)
x (WKUP2)
PI0X--XX-
PI1X-x(4)XXx (WKUP4)
PA6, PB2, PC0,
PC3, PE14,
PF10, PG8
X---X-
  1. 1. If VDDCORE is present.
  2. 2. When configured by the RTC as tamper pins.
  3. 3. See Table 403: RTC pin PC13 configuration.
  4. 4. See Table 404: PI1 configuration.

Note: Due to the fact that the VSW switch only supports a limited amount of current, the use of PC13 to PC15, and PI0 to PI3 as GPIOs is restricted. See Datasheet for details.

When the VDD supply is absent and a supply is present on VBAT, the backup domain IOs are supplied by VBAT, the following functions are available in VBAT mode:

Table 31. VSW domain functions when VBAT is present

Pin nameGPIOLSERTCTAMPER_OUT(1)TAMPER_IN(2)WAKEUP
PC14, PC15-X----
PC13--x(2)XX-
PI0, PI2, PI3---XX-
Table 31. VSW domain functions when VBAT is present (continued)
Pin nameGPIOLSERTCTAMPER_OUT
(1)
TAMPER_IN
(2)
WAKEUP
PI1--x(3)xx-
PA6, PB2, PC0,
PC3, PE14,
PF10, PG8
----x-
  1. 1. When configured by the RTC as tamper pins.
  2. 2. See Table 403: RTC pin PC13 configuration.
  3. 3. See Table 404: PI1 configuration.

VSW domain access

After a system reset the RTC registers and RTC backup registers are protected against possible unwanted write accesses. To enable access to the VSW domain, proceed as follows:

Set the DBP bit in the PWR control register 1 (PWR_CR1) to enable access to the VSW domain.

For more detail on RTC and backup registers access see Section 10: Reset and clock control (RCC)

Backup RAM

The backup domain includes 8 Kbytes of backup RAM accessible in 32-bit, 16-bit or 8-bit data mode.

When the backup regulator is enabled by BREN register bit in PWR control register 2 (PWR_CR2), the backup RAM content is retained even in Standby and/or VBAT mode (it can be considered as an internal EEPROM when VBAT is always present). The backup regulator can be ON or OFF depending whether the application needs the backup RAM function in Standby or VBAT modes.

When enabling the backup regulator, the readiness of the backup supply must be checked with the BRRDY register bit in PWR control register 2 (PWR_CR2), before entering Standby or VBAT mode.

On tamper event the content of the backup RAM may be erased depending on ERCFG0 register bit in Section 46: Real-time clock (RTC) TAMP erase configuration register (TAMP_ERCFGR).

If ERCFG0 bit is de-asserted, then the backup RAM is not erased and access are not blocked in case of tamper detection.

Otherwise access are blocked and content will be erased on first write access to backup RAM (so after next POR and first write access to backup RAM if system was in VBAT mode).

Figure 30. Backup domain Block diagram of Backup domain showing connections between VBAT, VDD, VDDCORE, VSW domain, Backup Regulator, Backup domain, Backup Interface, Backup RAM, RTC, LSE, and Backup IO's.

MSv65237V2

Block diagram of Backup domain showing connections between VBAT, VDD, VDDCORE, VSW domain, Backup Regulator, Backup domain, Backup Interface, Backup RAM, RTC, LSE, and Backup IO's.

9.3.4 VBAT battery charging

When VDD is present, it is possible to charge an external battery on VBAT through an internal resistance between the 2 supplies.

The VBAT charging is done either through a 5 kOhm resistor, or through a 1.5 kOhm resistor depending on the VBRS bit value in PWR control register 3 (PWR_CR3).

The battery charging is enabled/disabled by the VBE bit in PWR control register 3 (PWR_CR3). It is automatically disabled when entering VBAT mode.

9.3.5 Analog supply

Separate analog VDDA supply

The analog supply domain has separate VDDA and VSSA pads to allow the supply to be filtered and shielded from noise on the PCB. This improves the ADC conversion accuracy.

Analog reference voltage VREF

To improve accuracy on low voltage signals, the ADC has a separate reference voltage VREF+ pin. The user may connect an external reference voltage on VREF+. VREF+ determines the highest input voltage, represented by the full scale digital value. The lower voltage reference VREF- is connected to VSSA.

When enabled by the voltage reference buffer ENVR bit in Section 28.5.1: VREFBUF control and status register (VREFBUF_CSR), VREF+ is provided from the internal voltage reference buffer. The internal voltage reference buffer can also provide a reference voltage

to external components through the same VREF+ pin, see Section 28: Voltage reference buffer (VREFBUF).

9.3.6 1V8 regulator

The 1V8 regulator is supplied from the VDD supply and generates the VDDA1V8_REG supply. The USB HS PHY is directly connected to this supply.

The use of the integrated 1V8 regulator has to be enabled by the BYPASS_REG1V8 pin (level low) and the REG18EN register bit in PWR control register 3 (PWR_CR3), the VDDA1V8_REG is provided from the 1V8 regulator. Before using VDDA1V8_REG, its availability must be checked with the REG18RDY register bit in PWR control register 3 (PWR_CR3).

When the 1V8 regulator is disabled (bypass) by the BYPASS_REG1V8 pin (level high) or the REG18EN register bit, the VDDA1V8_REG can be provided from an external supply.

When VDD = 1.8 V is used, the 1V8 regulator must be bypassed (BYPASS_REG1V8 = 1).

For more information on the 1V8 regulator see Section 9.3: PWR power supplies.

9.3.7 1V1 regulator

The 1V1 regulator is supplied from the VDD supply and generates the VDDA1V1_REG supply. The USB HS PHY is directly connected to this supply.

The 1V1 regulator is enabled by the REG11EN register bit in PWR control register 3 (PWR_CR3). Before using the supply from the 1V1 regulator, its availability must be checked with the REG11RDY register bit in PWR control register 3 (PWR_CR3).

For more information on the 1V1 regulator see Section 9.3: PWR power supplies.

9.4 PWR power supply supervision

Power supply level monitoring is available on the following supplies:

9.4.1 Power-on reset (POR)/power-down reset (PDR)

The system has an integrated POR/PDR circuitry that allows proper startup operation.

The system remains in Reset mode when \(V_{DD}\) is below a specified \(V_{POR}\) threshold, without the need for an external reset circuit. Once the \(V_{DD}\) supply level is above the \(V_{POR}\) threshold, the system is taken out of reset. For more details concerning the power-on/power-down reset threshold, refer to the electrical characteristics in the datasheet.

The POR/PDR also generates an application reset (NRST).

PDR_ON is reserved for STMicroelectronics production tests and must always be connected to \(V_{DD}\) in an application.

When low power modes LPLV-Stop, LPLV-Stop2 are used, PDR_ON should be kept high.

Figure 31. Power-on reset/power-down reset waveform

Figure 31: Power-on reset/power-down reset waveform. The graph shows the supply voltage V_DD rising and falling over time T. The rising edge crosses the V_POR threshold, and the falling edge crosses the V_PDR threshold. The difference between V_POR and V_PDR is labeled as hysteresis. A delay T_RSTTEMPO is shown from the point where V_DD crosses V_POR until the nrst_por signal transitions from low to high.

The figure is a timing diagram showing the relationship between the supply voltage \(V_{DD}\) and the power-on reset signal nrst_por over time T. The \(V_{DD}\) waveform is a trapezoid. The rising edge of \(V_{DD}\) crosses a threshold \(V_{POR}\), and the falling edge crosses a lower threshold \(V_{PDR}\). The vertical distance between \(V_{POR}\) and \(V_{PDR}\) is labeled 'hysteresis'. The nrst_por signal is low until \(V_{DD}\) reaches \(V_{POR}\), then it goes high after a delay \(T_{RSTTEMPO}\). The signal remains high until \(V_{DD}\) falls below \(V_{PDR}\), at which point it returns to low. The diagram is labeled 'MSv46514V2' in the bottom right corner.

Figure 31: Power-on reset/power-down reset waveform. The graph shows the supply voltage V_DD rising and falling over time T. The rising edge crosses the V_POR threshold, and the falling edge crosses the V_PDR threshold. The difference between V_POR and V_PDR is labeled as hysteresis. A delay T_RSTTEMPO is shown from the point where V_DD crosses V_POR until the nrst_por signal transitions from low to high.
  1. 1. For the thresholds and hysteresis values, refer to the datasheet.

9.4.2 Brownout reset (BOR)

During power-on, the brownout reset (BOR) keeps the system under reset until the \(V_{DD}\) supply voltage reaches the specified \(V_{BOR}\) threshold.

The \(V_{BOR}\) threshold is configured through the system OTP bits. By default, BOR is off. Several programmable \(V_{BOR}\) thresholds can be programmed.

The BOR generates a NRST reset and an application reset (app_rst).

When the BOR is enabled and the \(V_{DD}\) supply voltage drops below the selected \(V_{BOR}\) threshold, an application reset (app_rst) is generated.

The BOR can be disabled by programming the system OTP bits. The power down is then monitored by the PDR (see Section 9.4.1)

Refer to Datasheet for more information on the BOR thresholds and hysteresis levels.

Figure 32. BOR thresholds

Figure 32: BOR thresholds diagram. The graph shows the relationship between supply voltage (V_DD) and temperature (T). A trapezoidal curve represents the BOR threshold, with V_BOR_rise and V_BOR_fall indicating the rise and fall thresholds. The vertical distance between these two thresholds is labeled 'hysteresis'. Below the graph, a signal labeled 'nrst_bor' is shown as a low-level pulse that occurs when the supply voltage is between the rise and fall thresholds.

The diagram illustrates the Brown-Out Reset (BOR) thresholds. The vertical axis represents the supply voltage \(V_{DD}\), and the horizontal axis represents temperature T. A trapezoidal curve defines the BOR threshold. The rising edge of the curve is at \(V_{BOR\_rise}\), and the falling edge is at \(V_{BOR\_fall}\). The vertical distance between these two levels is labeled 'hysteresis'. Below the graph, a signal labeled 'nrst_bor' is shown as a low-level pulse that occurs when the supply voltage is between the rise and fall thresholds.

Figure 32: BOR thresholds diagram. The graph shows the relationship between supply voltage (V_DD) and temperature (T). A trapezoidal curve represents the BOR threshold, with V_BOR_rise and V_BOR_fall indicating the rise and fall thresholds. The vertical distance between these two thresholds is labeled 'hysteresis'. Below the graph, a signal labeled 'nrst_bor' is shown as a low-level pulse that occurs when the supply voltage is between the rise and fall thresholds.
  1. 1. For the thresholds and hysteresis values, refer to the datasheet.

9.4.3 \(V_{DDCORE}\) OK and \(V_{DDCPU}\) OK reset

The system has an integrated circuitry that allows proper startup operation of the \(V_{DDCORE}\) domain.

The \(V_{DDCORE}\) domain remains in Reset mode when \(V_{DDCORE}\) is below the operation threshold vddcore_ok. Once the \(V_{DDCORE}\) supply level is above the operation threshold vddcore_ok, the \(V_{DDCORE}\) domain is taken out of reset. For more details concerning the vddcore_ok reset threshold, refer to the electrical characteristics of the datasheet.

While \(V_{DDCPU}\) is below the operation threshold vddcpu_ok the system is prevented from going to RUN mode.

When the detectors are enabled, the \(V_{DDCORE}\) is automatically put in Reset during Standby mode when the \(V_{DDCORE}\) supplies level is below the operation threshold. Run mode is only entered once \(V_{DDCORE}\) and \(V_{DDCPU}\) supplies are above their operation threshold levels. See Figure 33. Refer to Section 9.6.11: System Standby mode for detailed description of the exit sequence.

When low power modes LPLV-Stop, LPLV-Stop2 are used, PDR_ON should be kept high.

Figure 33. Automatic domain Reset in Standby

Timing diagram for automatic domain reset in standby mode. It shows the sequence of events from Run to Standby, POR Reset, Wait HSI oscillator, HW system Init, and back to Run. Key signals include PWR_CPU_ON, PWR_ON, PWR_LP, VDDCPU, vddcpu_ok, VDDCORE, vddcore_ok, and hclk4. It highlights the minimum standby duration, wake-up event, and various timing parameters like t_VDDCPU_TEMPO and t_VDDCORE_TEMPO.

The diagram illustrates the automatic domain reset sequence in standby mode. It shows the following signals and their transitions:

Key timing parameters and events include:

Operating modes are indicated by the blue boxes: Run, Standby, POR Reset, Wait HSI oscillator, HW system Init, and Run.

Timing diagram for automatic domain reset in standby mode. It shows the sequence of events from Run to Standby, POR Reset, Wait HSI oscillator, HW system Init, and back to Run. Key signals include PWR_CPU_ON, PWR_ON, PWR_LP, VDDCPU, vddcpu_ok, VDDCORE, vddcore_ok, and hclk4. It highlights the minimum standby duration, wake-up event, and various timing parameters like t_VDDCPU_TEMPO and t_VDDCORE_TEMPO.

MSv65235V2

9.4.4 Programmable voltage detector (PVD)

The PVD can be used to monitor the \(V_{DD}\) power supply by comparing it to a threshold selected by the PLS[2:0] bits in the PWR control register 1 (PWR_CR1).

The PVD can also be used to monitor a voltage level on the PVD_IN pin. In this case, the voltage level on PVD_IN is compared to the internal VREFINT level.

The PVD is enabled by setting the PVDEN bit in PWR control register 1 (PWR_CR1).

The PVD is not available in Standby mode.

A PVDO flag is available, in the PWR control status register 1 (PWR_CSR1), to indicate whether \(V_{DD}\) or voltage level on PVD_IN is higher or lower than the PVD threshold. This event is internally connected to the EXTI and can generate an interrupt if enabled through the EXTI registers. The PVDO output interrupt can be generated when \(V_{DD}\) or voltage level on PVD_IN drops below the PVD threshold and/or when \(V_{DD}\) or voltage level on PVD_IN rises above the PVD threshold depending on EXTI rising/falling edge configuration. As an example, the service routine could perform emergency shutdown tasks.

Figure 34. PVD thresholds

Figure 34. PVD thresholds. This diagram illustrates the PVD (Programmable Voltage Detector) thresholds and their relationship to the VDD or PVD_IN supply voltage over time (T). The top graph shows the VDD or PVD_IN voltage ramping up and then down. Two horizontal dashed lines represent the PVDrise and PVDfall thresholds, with the vertical distance between them labeled as 'hysteresis'. The bottom graph shows the PVDO (PVD Output) signal, which is low until the supply voltage rises above the PVDrise threshold, then transitions high, and returns low when the supply voltage falls below the PVDfall threshold. The PVDEN (PVD Enable) signal is shown as a low-to-high transition labeled 'SW enable' and a high-to-low transition labeled 'PDR reset'.
Figure 34. PVD thresholds. This diagram illustrates the PVD (Programmable Voltage Detector) thresholds and their relationship to the VDD or PVD_IN supply voltage over time (T). The top graph shows the VDD or PVD_IN voltage ramping up and then down. Two horizontal dashed lines represent the PVDrise and PVDfall thresholds, with the vertical distance between them labeled as 'hysteresis'. The bottom graph shows the PVDO (PVD Output) signal, which is low until the supply voltage rises above the PVDrise threshold, then transitions high, and returns low when the supply voltage falls below the PVDfall threshold. The PVDEN (PVD Enable) signal is shown as a low-to-high transition labeled 'SW enable' and a high-to-low transition labeled 'PDR reset'.

MSv46517V1

  1. 1. For the thresholds and hysteresis values, refer to the datasheet.

9.4.5 Analog voltage detector (AVD)

The AVD can be used to monitor the \(V_{DDA}\) supply by comparing it to a threshold selected by the ALS[1:0] bits in the PWR control register 1 (PWR_CR1).

The AVD is enabled by setting the AVDEN bit in PWR control register 1 (PWR_CR1).

The AVD is not available in Standby mode.

An AVDO flag is available, in the PWR control status register 1 (PWR_CSR1), to indicate whether \(V_{DDA}\) is higher or lower than the AVD threshold. This event is internally connected to the EXTI and can generate an interrupt if enabled through the EXTI registers. The AVDO interrupt can be generated when \(V_{DDA}\) drops below the AVD threshold and/or when \(V_{DDA}\) rises above the AVD threshold depending on EXTI rising/falling edge configuration. As an example, the service routine could indicate when the \(V_{DDA}\) supply drops below a minimum level.

Figure 35. AVD thresholds

Figure 35: AVD thresholds diagram. The top part shows a graph of V_DDA vs. Temperature (T) with a trapezoidal curve. The rising edge is labeled AVDrise, the falling edge is labeled AVDfall, and the vertical distance between the two is labeled hysteresis. The bottom part shows two digital signals: AVDO and AVDEN. AVDO is a pulse that occurs when the V_DDA curve crosses the AVDrise threshold and ends when it crosses the AVDfall threshold. AVDEN is a pulse that starts at 'SW enable' and ends at 'SW disable'.
Figure 35: AVD thresholds diagram. The top part shows a graph of V_DDA vs. Temperature (T) with a trapezoidal curve. The rising edge is labeled AVDrise, the falling edge is labeled AVDfall, and the vertical distance between the two is labeled hysteresis. The bottom part shows two digital signals: AVDO and AVDEN. AVDO is a pulse that occurs when the V_DDA curve crosses the AVDrise threshold and ends when it crosses the AVDfall threshold. AVDEN is a pulse that starts at 'SW enable' and ends at 'SW disable'.

1. For the thresholds and hysteresis values, refer to the datasheet.

9.4.6 Battery voltage thresholds

The battery voltage \(V_{BAT}\) supply can be monitored by comparing it with two threshold levels. VBATH flag and VBATL flag are available, in the PWR control register 2 (PWR_CR2), to indicate whether \(V_{BAT}\) is higher or lower than the respective threshold. The VBAT supply monitor can be enabled/disabled with MONEN bit in PWR control register 2 (PWR_CR2). When enabled, the battery voltage thresholds increases power consumption. As an example, the levels could be used to trigger a routine to perform emergency saving tasks.

The battery voltage thresholds, when enabled, are also available in Standby and VBAT modes.

The VBATL and VBATH flags are OR'ed together and available on tamper signal (see Section 46: Real-time clock (RTC)).

Figure 36. VBAT thresholds

Figure 36. VBAT thresholds. A graph showing VBAT vs Temperature (T) with thresholds VBATHigh and VBATLow, and corresponding digital signals VBATH and VBATL.

The figure is a graph with two parts. The top part shows a trapezoidal curve representing the relationship between battery voltage (VBAT) on the vertical axis and temperature (T) on the horizontal axis. The curve rises linearly, then stays constant at a high level, and finally falls linearly. Two horizontal dashed lines are drawn across the curve, labeled VBATHigh (the upper one) and VBATLow (the lower one). Vertical dashed lines extend from the points where these horizontal lines intersect the rising and falling slopes of the curve down to the bottom part of the graph. The bottom part of the graph shows two digital signals, VBATH and VBATL, as step functions. VBATH is a high-level signal that transitions to a low level between the two vertical dashed lines and then returns to high. VBATL is a low-level signal that transitions to a high level between the two vertical dashed lines and then returns to low. This indicates that VBATH is high when VBAT is above VBATHigh, and VBATL is high when VBAT is below VBATLow.

MSv46519V1

Figure 36. VBAT thresholds. A graph showing VBAT vs Temperature (T) with thresholds VBATHigh and VBATLow, and corresponding digital signals VBATH and VBATL.

1. For the thresholds and hysteresis values, refer to the datasheet.

9.4.7 Temperature thresholds

The temperature can be monitored by comparing it with two threshold levels. TEMPH flag and TEMPL flag are available, in the PWR control register 2 (PWR_CR2), to indicate if the device temperature is higher or lower than the threshold. The temperature monitor can be enabled/disabled with MONEN bit in PWR control register 2 (PWR_CR2). When enabled, the temperature thresholds increases power consumption. As an example the levels could be used to trigger a routine to perform temperature control tasks.

The temperature thresholds, when enabled, are also available in Standby and VBAT modes.

The TEMPL and TEMPH flags are OR'ed together and available on tamper signal (see Section 46: Real-time clock (RTC)).

Figure 37. Temperature thresholds

Figure 37. Temperature thresholds timing diagram showing Temperature profile versus time T, with thresholds TEMPhigh and TEMPlow, and corresponding digital output signals TEMPH and TEMPL.

The timing diagram shows Temperature on the vertical axis versus time T on the horizontal axis. A temperature curve rises, plateaus, and falls. Threshold levels TEMPhigh and TEMPlow are marked with horizontal dashed lines. Below the temperature curve, the logic state outputs TEMPH and TEMPL are shown aligned with vertical dashed lines marking transitions as temperature crosses TEMPhigh and TEMPlow.

Figure 37. Temperature thresholds timing diagram showing Temperature profile versus time T, with thresholds TEMPhigh and TEMPlow, and corresponding digital output signals TEMPH and TEMPL.
  1. 1. For the thresholds and hysteresis value, refer to the datasheet.

RM0475 Power control (PWR)

RM0475 Rev 5 451/3742

9.5 PWR power management

The power management controls the \(V_{DDCORE}\) and \(V_{DDCPU}\) supplies in accordance with the system operation modes (see Section 9.5.1: Operating modes).

9.5.1 Operating modes

Several system operating modes are available to tune the system according to the performance needs, i.e. when the MPU does not need to execute code and is waiting for an external event. It is up to the user to select the operating mode that gives the best compromise between low-power consumption, short startup time and available wakeup sources.

The operating modes control the power consumption and how the clock is distributed to the different parts of the system. The following operating modes for the different system parts are defined:


a. PDDS bit in the PWR MPU control register (PWR_MPUCR).

The LPDS bit in PWR control register 1 (PWR_CR1) selects LP-Stop. The LVDS bit in PWR control register 1 (PWR_CR1) selects normal voltage.

The various sub-system clocks are stalled.

The MPU sub-system is in CStop and the PDDS(a) bit selects Stop.

The regulators supply the VDDCORE and VDDCPU domains to retain the content of registers and internal memories. The external regulators are allowed to enter Low-power mode. The Low-power mode signaling on PWR_LP is enabled with the LPDS register bit in PWR control register 1 (PWR_CR1). The PWR_ON is kept set high or is cleared low following PWR_LP toggling as selected in LPCFG in PWR control register 1 (PWR_CR1), PWR_CPU_ON is kept high and PWR_LP is cleared low.

The LPDS and LVDS bits in PWR control register 1 (PWR_CR1) select LPLV-Stop.

The various sub-system clocks are stalled.

The MPU sub-system is in CStop and the PDDS(a) bit selects Stop.

The regulators supply the VDDCORE and VDDCPU domains to retain the content of registers and internal memories. The external regulators are allowed to enter Low-power low-voltage mode. The Low-power mode signaling on PWR_LP is enabled with the LPDS register bit in PWR control register 1 (PWR_CR1). PWR_ON is kept set high or is cleared low following PWR_LP toggling as selected in LPCFG in PWR control register 1 (PWR_CR1), PWR_CPU_ON is kept high and PWR_LP is cleared low. The Low-power low-voltage mode is enabled by the LVDS bit in PWR control register 1 (PWR_CR1). The VDDCORE and VDDCPU supply level may be lowered during LPLV-Stop mode.

The LPDS and LVDS bits in PWR control register 1 (PWR_CR1) select LPLV-Stop.

The MPU power supply VDDCPU is powered down.

The MPU sub-system is in CStandby with STOP2 = 1 and the PDDS(a) bit selects Stop.

The regulators supply the VDDCORE domain to retain the content of registers and internal memories except those in VDDCPU domain and switch off the VDDCPU domain. The VDDCORE external regulators are allowed to enter Low-power low-voltage mode while VDDCPU external regulator is switched off. The Low-power mode signaling on PWR_LP is enabled with the LPDS register bit in PWR control register 1 (PWR_CR1). The PWR_ON is kept set high or is cleared low following PWR_LP toggling as selected in LPCFG in PWR control register 1 (PWR_CR1), PWR_CPU_ON is cleared low and PWR_LP is cleared low. The Low-power low-voltage mode is enabled by the LVDS bit in PWR control register 1 (PWR_CR1). The VDDCORE supply level is lowered during LPLV-Stop2 mode and the VDDCPU supply is switched off.

The system is powered down.

The MPU sub-system is in CStandby with STOP2 = x and the PDDS(a) bit selects Standby.

The PWR_ON, PWR_CPU_ON signals are set low and PWR_LP is set low, the external regulators are switched off and the VDDCORE and VDDCPU domains are powered down. The content of the registers and memories are lost except for the

backup domain and the Standby circuitry.

In Run mode power consumption can be reduced by:

MPU Run Overdrive mode

The MPU can be set in Run Overdrive mode by increasing \(V_{DDCPU}\) above maximum allowed voltage in regular mode, allowing higher frequency operation (see datasheet for maximum MPU frequency in Run Overdrive mode).

When Overdrive mode is needed, the MPU_RAM_LOWSPEED bit in PWR_CR1 register must be reset after the \(V_{DDCPU}\) supply has reached the Run Overdrive mode voltage range and prior to increasing the MPU frequency into the overdrive frequency range.

It must be set after decreasing the MPU frequency into the standard frequency range and prior to decreasing the MPU voltage below the Run Overdrive mode voltage range.


Warning: When \(V_{DDCPU} < \text{Min } V_{DDCPU}\) (Run Overdrive mode) and MPU_RAM_LOWSPEED = 0 the Run functionality is not guaranteed.


MPU Low-power mode summary

The MPU subsystem supports the following Low-power modes:

Table 32. MPU Low-power mode summary

MPUL2 cacheEntry(1)WakeupMPU clockBus matrix clocks
CRunL2Run-see Table 35ONON
CSleepSTPREQ_P0 = 0
WFE
OFF
L2StopSTPREQ_P0 = 0
WFI
ON/OFF(2)
CStopSTPREQ_P0 = 1
PDDS = 0
STOP2 = 0
LPDS = 0 or 1
WFI
OFF/ON
CStandbySTPREQ_P0 = 1
PDDS = 0
STOP2 = 1
LPDS = 1
WFI
STPREQ_P0 = 1
PDDS = 1
STOP2 = x
WFI

1. For STPREQ_P0 register bit functionality refer to the RCC (Stop request from MPU processor).

2. The peripherals having a PERxLPEN bit operate accordingly.

System Low-power modes summary

The system Low-power modes are derived from the MPU Low-power modes.

Table 33. PWR system mode summary

MPU CRunMPU CSleep
STPREQ_P0 = 0
MPU CStop
STPREQ_P0 = 1
STOP2 = 0
PDDS = 0
MPU CStandby
STPREQ_P0 = 1
STOP2 = 1
PDDS = 0
MPU CStandby
STPREQ_P0 = 1
STOP2 = x
PDDS = 1
RunRunStop
LP-Stop
LPLV-Stop
LPLV-Stop2Standby
Clock MPU On
Power MPU On
Power Core On
Clock MPU Off(1)
Power MPU On
Power Core On
Clock MPU Off
Power MPU On(2)
Power Core On
Clock MPU Off
Power MPU Off
Power Core On(3)
Clock MPU Off
Power MPU Off
Power Core Off
  1. 1. Matrix bus clocks On or Off
  2. 2. \(V_{DDCORE}\) and \(V_{DDCPU}\) can be reduced in LPLV-Stop
  3. 3. \(V_{DDCORE}\) is reduced in LPLV-Stop2

Table 34. System Low-power mode summary

SystemMPUDDR(1)WakeupSys-oscillators(2)hclk4PWR_LPPWR_ONPWR_CPU_ON
LPCFG = 0LPCFG = 1
RunCRun or CSleepActive / Auto refreshSee Table 35ONON1111
(3)
Stop
(LPDS = 0)
CStop
(STPREQ_P0 = 1,
STOP2 = 0,
PDDS = 0)
Self refreshON/OFF(4)OFF1111
(3)
LP-Stop,
LPLV-Stop
(LPDS = 1)
0(5)0(5)0(5)0
LPLV-Stop2
(LPDS = 1)
CStandby
(STPREQ_P0 = 1,
STOP2 = 1,
PDDS = 0)
Off / Self refreshOFFOFF0(6)0(6)0(6)0
Standby
(LPDS = x)
CStandby
(STPREQ_P0 = 1,
STOP2 = x,
PDDS = 1)
Off / Self refresh0(6)0(6)0(6)0
  1. 1. The DDR operation state is only presented for information. i.e. The DDR may be Off when MPU is in CRun, e.g. when executing from boot ROM or it may be in self refresh when the system is in any of its operation modes.
  2. 2. The sys-oscillators: HSI/HSE/CSI oscillators configured ON in RCC.
  3. 3. PDDS bit selects the Stop mode (PPDS bit in registers PWR MPU control register (PWR_MPUCR)).
  4. 4. When the system oscillator HSI, CSI or HSE is used, the state is controlled by respective xxxKERON, else the system oscillator is OFF (see Section 10: Reset and clock control (RCC)).
  1. 5. Settings in PWR control register 3 (PWR_CR3) bits POPL have no impact on the LP-Stop and LPLV-Stop mode PWR_ON, PWR_CPU_ON and PWR_LP pulse time.
  2. 6. A guaranteed minimum PWR_ON, PWR_CPU_ON and PWR_LP pulse time can be defined in PWR control register 3 (PWR_CR3) bits POPL.
Table 35. Functionalities depending on system operating mode(1)
PeripheralRunStop and LP-StopLPLV-Stop
LPLV-Stop2
StandbyVBAT
-Wakeup capability-Wakeup capability-Wakeup capability
MPUY(2)R-R(3)----
DBGOOOR----
ROM memoryYR-R-R-R
SYSRAMY(2)R-R----
SRAMx (x = 1:3)Y(4)R-R----
BKPSRAMO(2)R-R-O(5)-R
DDRCTRLOR-R----
QUADSPIOR-R----
FMCOR-R----
Backup RegistersYR-R-R-R
Brown-out reset (BOR)YYYYYYY-
Programmable Voltage Detector (PVD)OOOOO---
Analog Voltage monitor (AVD)OOOOO---
VBATH/VBATL monitoringOOOOOOOO
TEMPH/TEMPL monitoringOOOOOOOO
MDMAOR-R----
DMAx (x=1,2,3)OR-R----
DMAMUXOR-R----
High Speed Internal (HSI)OO-O----
High Speed External (HSE)OO-O----
Low Speed Internal (LSI)OO-O-O--
Low Speed External (LSE)OO-O-O-O
Multi-Speed Internal (CSI)OO------
HSE CSS Clock Security SystemOOO-----
LSE CSS Clock Security SystemOOOOOOOO
RTC / Auto wakeupOOOOOOOO
Number of Tamper pins1212O12O12O12
USBH, OTGOROR----
SDMMCx (x=1:2)OR-R----
Table 35. Functionalities depending on system operating mode(1) (continued)
PeripheralRunStop and LP-StopLPLV-Stop
LPLV-Stop2
StandbyVBAT
-Wakeup capability-Wakeup capability-Wakeup capability
FDCANx (x=1:2)OR-R----
ETHx (x= 1:2)OROR----
USARTx (x = 1:8)OO(6)O(6)RO(6)---
I2Cx (x = 1:5)OO(7)O(7)RO(7)---
SPIx (x=1:5)OO(8)O(8)RO(8)---
SAIx (x = 1:2)OR-R----
DFSDMOR-R----
DCMIPPOR-R----
HDPOR-R----
LTDCOR-R----
SPDIFRXOR-R----
ADC1-2OR-R----
VREFBUFOO------
DTSORORO---
STGENOR-R----
TIMx (x = 1:17)OR-R----
LPTIMx (x = 1:5)OOORO(9)---
IWDGx (x=1,2)OOOOOOO-
SysTick timerOR-R(3)----
RNGx (x = 1)OR-R----
CRYPx(10) (x = 1)OR-R----
HASHx (x = 1)OR-R----
CRCx (x = 1)OR-R----
GPIOsORO(11)RO(11)-6 pins
(12)
-
  1. 1. Legend: Y = Yes (Enable). O = Optional (Disable by default. Can be enabled by software). R = data/state retained. - = Not available; highlighted in gray for wakeup mode.
  2. 2. The SRAM clock can be gated on or off. When MPU in CSleep mode, MPU is not clocked, SRAM is disabled by default but can be enabled by software.
  3. 3. Not in LPLV-Stop2 mode.
  1. 4. When MPU is in CSleep mode, the SRAM clock can be gated on or off. It is disabled by default but can be enabled by software.
  2. 5. The BKPSRAM content can optionally be retained when enabled.
  3. 6. UART reception is functional in Stop mode, and generates a wakeup interrupt on Start, address match or received frame event.
  4. 7. I2C address detection is functional in Stop mode, and generates a wakeup interrupt in case of address match.
  5. 8. SPI transmission and reception is functional in Stop mode, and generates a wakeup interrupt in case of FIFO thresholds, end of transfer, errors, ....
  6. 9. Only with LSE or LSI as kernel clock source.
  7. 10. Not present on all the product part numbers, see the related datasheet for more information.
  8. 11. All GPIOs can wakeup the system through EXTI interface.
  9. 12. The I/Os with wakeup from Standby capability is only available from a limited number of pins (PA3, PC13, PI1, PI2, PI3, PF8).

9.5.2 System operating modes and external regulator modes

The power control handles the VDDCORE and VDDCPU supplies for system Run, Stop, LP-Stop, LPLV-Stop, LPLV-Stop2 and Standby modes. The system operating mode depends on the MPU sub-system modes (CRun, CSleep, CStop, CStandby).

Figure 38. Power states and external regulator control

Figure 38. Power states and external regulator control. State diagram showing Standby (POWER DOWN: PWR_ON = 0, PWR_LP = 0, PWR_CPU_ON = 0), Run (MAIN: PWR_ON = 1, PWR_LP = 1, PWR_CPU_ON = 1) entered via reset, Stop/LP-Stop/LPLV-Stop box containing MAIN (PWR_ON = 1, PWR_LP = 1, PWR_CPU_ON = 1) and LOW POWER (PWR_ON = 1 when LPCFG = 0, PWR_ON = 0 when LPCFG = 1, PWR_LP = 0, PWR_CPU_ON = 1), and LPLV-Stop2 containing LOW POWER (PWR_ON = 1 when LPCFG = 0, PWR_ON = 0 when LPCFG = 1, PWR_LP = 0, PWR_CPU_ON = 0). State transitions and wakeups are color coded for Stop mode, LPLV-Stop2 mode, and Standby mode.

MSv65240V1

Figure 38. Power states and external regulator control. State diagram showing Standby (POWER DOWN: PWR_ON = 0, PWR_LP = 0, PWR_CPU_ON = 0), Run (MAIN: PWR_ON = 1, PWR_LP = 1, PWR_CPU_ON = 1) entered via reset, Stop/LP-Stop/LPLV-Stop box containing MAIN (PWR_ON = 1, PWR_LP = 1, PWR_CPU_ON = 1) and LOW POWER (PWR_ON = 1 when LPCFG = 0, PWR_ON = 0 when LPCFG = 1, PWR_LP = 0, PWR_CPU_ON = 1), and LPLV-Stop2 containing LOW POWER (PWR_ON = 1 when LPCFG = 0, PWR_ON = 0 when LPCFG = 1, PWR_LP = 0, PWR_CPU_ON = 0). State transitions and wakeups are color coded for Stop mode, LPLV-Stop2 mode, and Standby mode.

The system mode selection between Stop, LP-Stop, LPLV-Stop or LPLV-Stop2 or Standby is controlled by the PDDS bit and the STOP2 bit in PWR MPU control register (PWR_MPUCR).

Table 36. PDDS low-power mode control

STOP2PDDSSystem operation mode
00Stop, LP-Stop, LPLV-Stop (with MPU in CStop)
10LPLV-Stop2 (with MPU in CStandby)
x1Standby (with MPU in CStandby)

Flags setup on exit from Low Power modes:

The flags provided to determine from which mode the system exits are shown in Table 35. The MPU flags can be read from PWR MPU control register (PWR_MPUCR). The MPU has a reset bit CSSF to clear it's wakeup flags. The MPU CSSF register bit is located in the same register as the MPU flags.

Note: From when the PDDS register bit has been selected and the MPU has issued a WFI or WFE instruction to request System Standby mode to when actual Standby mode is reached (PWR_ON = 0), about 50 HSI clock cycles are needed. If a wake up event occurs during this time, the SBF and SBFMPU flags won't be set on exit from Standby.

Table 37. Low-power mode exit flags

System modeMPU modeSBFSBFMPUSTOPFComment
RunCRUN / CSleep000System contents retained
Stop
LP-Stop
LPLV-Stop
CStop001System contents retained, system clock stopped.
LPLV-Stop2CStandby011MPU sub-system content lost
StandbyCStandby110System contents lost
VBAT(1)n.a.000System contents lost

1. Exit from VBAT mode may be derived from the retained registers in the VSW domain, which are not reset.

9.5.3 System wakeup

From an application reset (NRST, IWDG, ...) or a wakeup from Standby, the system wakes up the MPU. From this point the boot ROM manages the startup.

9.6 PWR low-power operating modes

Several Low-power operating modes are available to save power when the MPU does not need to execute code (i.e. when waiting for an external event). It is up to the user to select the mode that gives the best compromise between low-power consumption, short startup time and available wakeup sources.

9.6.1 Slowing down the CPU clocks and/or the bus matrix clocks

In Run mode, the speed of the MPU and/or the bus matrix clocks can be reduced, for more details refer to Section 10: Reset and clock control (RCC).

9.6.2 Controlling peripheral clocks

In Run mode, the bus clock for individual peripherals can be stopped by the RCC PERxEN register bits at any time to reduce power consumption.

To reduce power consumption in CSleep mode the individual peripheral clocks can be disabled by the RCC PERxLPEN register bit. For the peripherals still receiving a clock in CSleep mode, their clock can be slowed down before entering CSleep mode.

9.6.3 Entering low-power modes

MPU sub-system Low-power modes are entered by the MPU when executing the WFI (Wait For Interrupt) instruction for CSleep, CStop and CStandby modes, or the WFE (Wait for Event) instruction for CSleep mode.

The system may enter Stop, LP-Stop, LPLV-Stop, LPLV-Stop2 or Standby when all EXTI wakeup sources are cleared and the MPU is in CStop or CStandby.

9.6.4 Exiting low-power modes using WFI or WFE

If the WFI instruction was used to enter low-power mode, any peripheral interrupt acknowledged by the GIC can wake up the system.

If the WFE instruction is used to enter low-power mode, the MPU exits from low-power mode as soon as an event occurs. The wakeup event can be generated by:

When waking up from LPLV-Stop2 or Standby the GIC is reset and it is necessary to re-enable the interrupt in order for the software to handle it.

9.6.5 MPU CSleep mode

In CSleep mode the MPU clock is stopped. The peripheral clocks operate according to the PERxLPEN bits.

Entering MPU CSleep mode

CSleep mode is entered according to Section 9.6.3: Entering low-power modes.

Refer to Table 38, for details on how to enter CSleep mode.

Exiting MPU CSleep mode

CSleep mode is exited according to Section 9.6.4: Exiting low-power modes using WFI or WFE.

Refer to Table 38 for more details on how to exit from CSleep mode.

Table 38. MPU CSleep

MPU CSleep modeDescription
Mode entryWFI (Wait for Interrupt) while:
WFE (Wait for Event) while:
  • – MPU GIC interrupts and events cleared.

Table 38. MPU CSleep (continued)

MPU CSleep modeDescription
Mode exitIf WFI was used for entry:
– Any Interrupt enabled in GIC: Refer to Section 18.1: GIC Interrupts
If WFE was used for entry:
– Any Interrupt even when disabled in GIC: refer to Section 18.1: GIC Interrupts or any event: refer to Section 9.6.4: Exiting low-power modes using WFI or WFE
Wakeup latencyNone

9.6.6 MPU CStop mode

In CStop mode the MPU clock and peripheral clocks are stopped.

In CStop mode, peripherals having a kernel clock request are still able to request their kernel clock, by selecting a clock in the RCC which is able to run in CStop mode.

Entering MPU CStop mode

CStop mode is entered according to Section 9.6.3: Entering low-power modes,

Refer to Table 39 for MPU for details on how to enter CStop mode.

Exiting MPU CStop mode

The CStop mode is exited according to Section 9.6.4: Exiting low-power modes using WFI or WFE.

Refer to Table 39 for more details on how to exit from CStop mode.

Table 39. MPU CStop

MPU CStop modeDescription
Mode entryWFI (Wait for Interrupt)
– STPREQ_P0 = 1 and PDDS = 0 and STOP2 = 0
– MPU GIC interrupts and events cleared.
– All MPU EXTI Wakeup sources are cleared.
Mode exitEXTI Interrupt enabled in GIC: Refer to Section 18.1: GIC Interrupts, for the peripherals which are not stopped.
Wakeup latencyEXTI and RCC wakeup synchronization (see Section 10: Reset and clock control (RCC)).

9.6.7 System Stop mode

The system enters to Stop mode when the MPU is in CStop mode and the EXTI wakeup sources are inactive, and the MPU PDDS bit in PWR MPU control register (PWR_MPUCR) requests Stop. In Stop mode, the bus matrix clocks are stalled. The oscillators can be

stopped, for detailed oscillators status in Stop mode, see Section 10.4.2: Oscillators description and Section 10.4.7: Clock generation in Stop and Standby modes. For more information on the other clocks refer to Section 10: Reset and clock control (RCC).

In Stop mode, the peripherals using the LSI or the LSE clock and peripherals having a kernel clock request selecting a clock source in the RCC which is able to run in Stop mode, are still able to operate.

In system Stop mode, the following features can be selected to be kept active by programming individual control bits:

Entering System Stop mode

Stop mode is entered according to Section 9.6.3: Entering low-power modes, when the PDDS bit in PWR MPU control register (PWR_MPUCR) requests Stop.

Refer to Table 40 for details on how to enter Stop mode.

If an access to a bus matrix is ongoing, Stop mode entry is delayed until the bus matrix access is finished.

Exiting System Stop mode

Stop mode is exited according to Section 9.6.4: Exiting low-power modes using WFI or WFE.

Refer to Table 40 for more details on how to exit Stop mode.

When exiting Stop mode the RCC restores the MPU and AXI bus matrix clocks. Refer to RCC section Leaving Stop, LP-Stop, LPLV-Stop or LPLV-Stop2 mode.

The STOPF status flag in PWR MPU control register (PWR_MPUCR) registers indicate that the system has exited Stop mode

Table 40. System Stop

Stop modeDescription
Mode entry
  • – When the MPU is in CStop mode and there is no active EXTI wakeup source.
  • – The PDDS bit selects Stop and STOP2 = 0
  • – LPDS selects Stop
Mode exit
  • – On an EXTI wakeup.
Wakeup latencySee Figure 39: Device low-power Stop supply sequence.

I/O states in System Stop mode

In Stop mode, all I/O pins keep their configuration.

Power supply Stop sequence

The system Stop mode sequence is shown in Figure 39. Stop mode is entered when selected by the LPDS register bit in PWR control register 1 (PWR_CR1).

  1. 1. When entering Stop mode, the hclk4 is stopped. The oscillators can be stopped in order to reduce the power consumption. For detailed oscillators status in Stop mode, see Section 10.4.2: Oscillators description and Section 10.4.7: Clock generation in Stop and Standby modes.
    In Stop mode both the PWR_ON, PWR_CPU_ON are kept high and PWR_LP is kept high. The external regulators remain in main mode.
  2. 2. On a wakeup event, the clock restore process is performed. See RCC: The clock restore sequence description for more details.
  3. 3. Once the oscillator is stable, the system enters Run mode.

Figure 39. Device low-power Stop supply sequence

Timing diagram for device low-power Stop supply sequence showing signals PWR_ON (H), PWR_CPU_ON (H), PWR_LP (H), VDDCPU, VDDCORE, vddcore_ok (H), vddcpu_ok (H), Operating mode, and hclk4 across four phases: Run, Stop, Wait HSI oscillator, and Run.

The diagram illustrates the power supply sequence for entering and exiting Stop mode. It shows the following signals over time:

Numbered markers (1), (2), and (3) are placed below the hclk4 signal line, corresponding to the transitions between the Stop, Wait, and final Run phases.

MSv65231V1

Timing diagram for device low-power Stop supply sequence showing signals PWR_ON (H), PWR_CPU_ON (H), PWR_LP (H), VDDCPU, VDDCORE, vddcore_ok (H), vddcpu_ok (H), Operating mode, and hclk4 across four phases: Run, Stop, Wait HSI oscillator, and Run.

9.6.8 System LP-Stop modes

LP-Stop mode is handled in the same way as Stop mode, when LP-Stop mode is selected by the LPDS register bit in PWR control register 1 (PWR_CR1). See Section 9.6.7: System Stop mode.

Refer to Table 41 for more details on how to enter and exit LP-Stop mode.

Table 41. System LP-Stop

LP-Stop modeDescription
Mode entry
  • – When the MPU is in CStop mode and there is no active EXTI wakeup source.
  • – The PDDS bit selects Stop and STOP2 = 0
  • – LPDS selects LP-Stop
Mode exit
  • – On an EXTI wakeup.
Wakeup latencySee Figure 40: Device low-power LP-Stop supply sequence.

The LVDS bit in PWR control register 1 (PWR_CR1) selects whether the \(V_{DDCORE}\) supply level during LP-Stop mode is kept at the Run mode level, or is lowered (LP-Stop with low voltage mode).

Power supply LP-Stop sequence

The system LP-Stop mode sequence is shown in Figure 40. The LP-Stop mode is entered when selected by the LPDS register bit in PWR control register 1 (PWR_CR1).

  1. 1. When entering LP-Stop mode the hclk4 is stopped. The oscillators can be stopped in order to reduce the power consumption. For detailed oscillators status in Stop mode, see Section 10.4.2: Oscillators description and Section 10.4.7: Clock generation in Stop and Standby modes.
    In LP-Stop mode the PWR_ON is either kept high or is cleared low following the PWR_LP toggling as selected with the LPCFG register bit in PWR control register 1 (PWR_CR1). The PWR_CPU_ON is kept high and the PWR_LP is cleared low, signaling LP-Stop. After, the external regulator may enter Low-power mode.
  2. 2. On a wakeup event the external regulators are taken out of Low-power mode via PWR_LP, and the clock restore process is performed. See RCC: The clock restore sequence description for more details.
  3. 3. Once the oscillator is stable, the PWRLP_TEMPO optional delay is timed out to allow the external regulators to switch to main mode. By default after reset this delay is minimum. (see Section 10.8.6: RCC low-power Stop modes delay control register (RCC_PWRLPDLYCR)).
  4. 4. After the delay timeout the system enters into Run mode.

Figure 40. Device low-power LP-Stop supply sequence

Timing diagram for Device low-power LP-Stop supply sequence. The diagram shows the following signals over time: PWR_CPU_ON (H) is high throughout. PWR_ON is high, then transitions to low during the LP-Stop phase, and returns to high. PWR_LP is low during the LP-Stop phase and high otherwise. VDDCPU and VDDCORE are high throughout. vddcore_ok (H) and vddcpu_ok (H) are high throughout. The operating mode transitions are: Run (1), LP-Stop (2), Wait for HSI oscillator (3), Wait for external reguator (4), and Run (5). The hclk4 signal is active during the Run phases and inactive during the LP-Stop and Wait phases. A PWRLP_TEMPO signal is shown during the Wait for external reguator phase.

MSv65232V3

Timing diagram for Device low-power LP-Stop supply sequence. The diagram shows the following signals over time: PWR_CPU_ON (H) is high throughout. PWR_ON is high, then transitions to low during the LP-Stop phase, and returns to high. PWR_LP is low during the LP-Stop phase and high otherwise. VDDCPU and VDDCORE are high throughout. vddcore_ok (H) and vddcpu_ok (H) are high throughout. The operating mode transitions are: Run (1), LP-Stop (2), Wait for HSI oscillator (3), Wait for external reguator (4), and Run (5). The hclk4 signal is active during the Run phases and inactive during the LP-Stop and Wait phases. A PWRLP_TEMPO signal is shown during the Wait for external reguator phase.

9.6.9 System LPLV-Stop modes

Refer to Table 42 for more details on how to enter and exit LPLV-Stop mode.

Table 42. System LPLV-Stop

LPLV-Stop modeDescription
Mode entry
  • – When the MPU is in CStop mode and there is no active EXTI wakeup source.
  • – The PDDS bit selects Stop and STOP2 = 0.
  • – LPDS selects low power stop.
  • – LVDS selects LPLV-Stop.
Mode exit
  • – On an EXTI wakeup.
Wakeup latencySee Figure 41: Device low-power LPLV-Stop supply sequence.

In LPLV-Stop mode, the DDR retention must be enabled by DDRRETEN in PWR control register 3 (PWR_CR3).

Power supply LPLV-Stop sequence

The system LPLV-Stop mode sequence is shown in Figure 41. LPLV-Stop mode is entered when selected by the LPDS and LVDS bits in PWR control register 1 (PWR_CR1).

  1. 1. When entering LPLV-Stop mode the hclk4 is stopped. The oscillators can be stopped in order to reduce the power consumption. For detailed oscillators status in Stop mode, see Section 10.4.2: Oscillators description and Section 10.4.7: Clock generation in Stop and Standby modes.

In LPLV-Stop mode PWR_ON is either kept high or is cleared low following PWR_LP toggling as selected with the LPCFG register bit in PWR control register 1 (PWR_CR1).

  1. PWR_CPU_ON is kept high and PWR_LP is cleared low, signaling LPLV-Stop. After this the external regulators may enter Low-power low-voltage mode and lower the \(V_{DDCORE}\) and \(V_{DDCPU}\) supplies.
  2. On a wakeup event the external regulators are taken out of Low-power low-voltage mode by PWR_LP rising and a delay \(t_{SEL\_VDDCORETEMPO}\) is started to wait for \(V_{DDCORE}\) and \(V_{DDCPU}\) to reach the Run mode operating supply level.
  3. After this delay the HSI is enabled and the clock restore process is performed. See RCC: The clock restore sequence description for more details.
  4. Once the oscillator is stable, the PWRLP_TEMPO optional delay is timed out to allow the external regulators to switch to main mode. By default after reset this delay is minimum. (see Section 10.8.6: RCC low-power Stop modes delay control register (RCC_PWRLPDLYCR)).
  5. After the delay timeout the system enters into Run mode.

Figure 41. Device low-power LPLV-Stop supply sequence

Timing diagram for LPLV-Stop supply sequence showing signals PWR_CPU_ON, PWR_ON, PWR_LP, VDDCORE/VDDCPU, vddcore_ok/vddcpu_ok, Operating mode, and hclk4.

The diagram illustrates the sequence of events for entering and exiting LPLV-Stop mode. It shows the following signals and their transitions:

Key timing parameters shown are \(t_{SEL\_VDDCORETEMPO}\) (the delay after PWR_LP rises until vddcore_ok/vddcpu_ok go high) and PWRLP_TEMPO (the optional delay after the HSI oscillator is stable before restoring the clock).

MSv65233V3

Timing diagram for LPLV-Stop supply sequence showing signals PWR_CPU_ON, PWR_ON, PWR_LP, VDDCORE/VDDCPU, vddcore_ok/vddcpu_ok, Operating mode, and hclk4.

9.6.10 System LPLV-Stop2 mode

LPLV-Stop2 mode is handled in the same way as LPLV-Stop mode.

Refer to Table 43 for more details on how to enter and exit LPLV-Stop2 mode.

Table 43. System LPLV-Stop2

LPLV-Stop2 modeDescription
Mode entry
  • – When the MPU is in CStop mode and there is no active EXTI wakeup source.
  • – The PDDS bit selects Stop and STOP2 = 1.
  • – LPDS selects low power stop.
  • – LVDS selects LPLV-Stop.
Mode exit
  • – On an EXTI wakeup.
Wakeup latencySee Figure 42: Device LPLV-Stop2 mode power control.

In LPLV-Stop2 mode, the DDR retention must be enabled by DDRRETEN in PWR control register 3 (PWR_CR3).

The wakeup from LPLV-Stop2 generates an MPU reset. The GIC is reset and the interrupt needs to be re-enabled if the software needs to handle it

Power supply LPLV-Stop2 sequence

The system LPLV-Stop2 mode sequence is shown in Figure 42. The LPLV-Stop2 mode is entered when selected by the PDDS bit in PWR MPU control register (PWR_MPUCR) register and STOP2 bit in PWR control register 1 (PWR_CR1) register.

  1. 1. When entering LPLV-Stop2 mode, hclk4 is stopped. The oscillators are also stopped.
    In LPLV-Stop2 mode PWR_ON is either kept high or is cleared low following PWR_LP toggling as selected with the LPCFG register bit in PWR control register 1 (PWR_CR1). PWR_CPU_ON is cleared and PWR_LP is cleared low, signaling LPLV-Stop2. After this, the VDDCPU external regulator may enter power off mode and switch off VDDCPU supply while the VDDCORE external regulator may enter Low-power low-voltage mode and lower the VDDCORE supply.
  2. 2. On a wakeup event, the external regulators are requested, by the PWR_ON and PWR_CPU_ON signals rising, to switch on the VDDCPU supply and raise VDDCORE supply voltage. A delay tSEL_VDDCORETEMPO is started to wait for VDDCORE to reach the Run mode operating supply level.
  3. 3. After this delay the HSI is enabled and the clock restore process is performed. See RCC: The clock restore sequence description for more details.
  4. 4. Once the oscillator is stable, the PWRLP_TEMPO optional delay is timed out to allow the external regulators to switch to main mode. By default after reset this delay is minimum. (see Section 10.8.6: RCC low-power Stop modes delay control register (RCC_PWRLPDLYCR)).
  5. 5. Once the VDDCPU supply is above the vddcpu_ok threshold the tVDDCPU_TEMPO is started to allow enough time for VDDCPU to reach its minimum Run mode value. When both PWRLP_TEMPO and tVDDCPU_TEMPO are elapsed the Run mode is started.

Note: During LPLV-Stop2 the content of the SYSRAM is maintained, hence it is not needed to reload its content. On wakeup from LPLV-Stop2, the program uses the BSEC_SCRATCH register value as branch address to the SYSRAM. So this register has to be configured before entering LPLV-Stop2 mode.

Note: In case the VDDCPU stays above VTH_VDDCPU during LPLV-Stop2 (very short LPLV-Stop2 duration) a longer PWRLP_TEMPO is recommended (typically 2 ms, PWRLP_DLY[21:0] = 0x20000).

This allows enough time for the regulator to complete setup and provide sufficient current drive before the Run mode starts again.

Figure 42. Device LPLV-Stop2 mode power control

Timing diagram for Device LPLV-Stop2 mode power control. The diagram shows the following signals over time: PWR_CPU_ON (transitions low to high), PWR_ON (transitions low to high), PWR_LP (transitions low to high), VDDCPU (rises from a low level to a 'min run value' above VTH_VDDCPU), vddcpu_ok (transitions low to high), VDDCORE (rises from a low level), vddcore_ok (H) (transitions low to high), Operating mode (transitions from Run to LPLV-Stop2, then through wait states (1) Run, (2) LPLV-Stop2, (3) Wait for VDDCORE timeout, (4) Wait for HSI oscillator, (5) Wait for external regulator, and back to Run), and hclk4 (clock signal). Key timing parameters include tVDDCPU_TEMPO (time for VDDCPU to reach min run value), tSEL_VDDCORETEMPO (time for VDDCORE to reach a level), and PWRLP_TEMPO (time for the external regulator to stabilize).

MSv65234V3

Timing diagram for Device LPLV-Stop2 mode power control. The diagram shows the following signals over time: PWR_CPU_ON (transitions low to high), PWR_ON (transitions low to high), PWR_LP (transitions low to high), VDDCPU (rises from a low level to a 'min run value' above VTH_VDDCPU), vddcpu_ok (transitions low to high), VDDCORE (rises from a low level), vddcore_ok (H) (transitions low to high), Operating mode (transitions from Run to LPLV-Stop2, then through wait states (1) Run, (2) LPLV-Stop2, (3) Wait for VDDCORE timeout, (4) Wait for HSI oscillator, (5) Wait for external regulator, and back to Run), and hclk4 (clock signal). Key timing parameters include tVDDCPU_TEMPO (time for VDDCPU to reach min run value), tSEL_VDDCORETEMPO (time for VDDCORE to reach a level), and PWRLP_TEMPO (time for the external regulator to stabilize).

9.6.11 System Standby mode

Standby mode offers the lowest power consumption. It is based on the MPU sub-system CStandby mode, as for the System LPLV-Stop2 mode, but with the VDDCORE and VDDCPU supply regulators powered off.

The system enters Standby mode only when the MPU is in CStandby mode and the PDDS bit in PWR MPU control register (PWR_MPUCR) requests Standby. When the system enters Standby mode the PWR_ON, PWR_CPU_ON pins are set low and the PWR_LP pin is cleared low. It is expected that the External Voltage regulators providing the VDDCORE and VDDCPU supplies are disabled, and the VDDCORE and VDDCPU domains are consequently powered off. The PLLs, HSI, CSI oscillator and the HSE oscillator are also switched off, SRAM and register contents are lost except for the VDD, VSW, backup domain (i.e. RTC registers, RTC backup register, LSE, backup RAM), and Standby circuitry (see Section 9.3.2: Power supply system startup sequence).

In system Standby mode, the following features can be selected by programming individual control bits:

Entering Standby mode

Standby mode is entered according to Section 9.6.3: Entering low-power modes, when the PDDS bit in PWR MPU control register (PWR_MPUCR) requests Standby.

Refer to Table 44 for more details on how to enter Standby mode.

Exiting Standby mode

Standby mode is exited according to Section 9.6.4: Exiting low-power modes using WFI or WFE.

Refer to Table 44 for more details on how to exit Standby mode.

The system exits Standby mode when an application reset (NRST, IWDG, ...), a WKUP pin event, a RTC alarm, a tamper event, or a time stamp event is detected. All registers are reset after wakeup from Standby except for the power control and status registers PWR control register 2 (PWR_CR2), PWR control register 3 (PWR_CR3), the SBF bit in PWR MPU control register (PWR_MPUCR), PWR wakeup flag register (PWR_WKUPFR), and PWR MPU wakeup enable register (PWR_MPUIWKUPENR).

After waking up from Standby mode, program execution restarts in the same way as after a Power On reset (boot option sampling, boot vector reset fetched, etc.). The MPU starts up booting and the boot ROM manages the startup.

The exit from Standby/CStandby status flags can be retrieved thanks to the STDBYRSTF and CSTDBYRSTF bits in RCC reset status set register (RCC_MP_RSTSSETR). Those bits are set by the boot ROM code from the SBF/SBFMPU bits in PWR MPU control register (PWR_MPUCR). The SBF/SBFMPU bits are dedicated to the boot ROM usage and should not be used elsewhere.

Table 44. Standby

Standby modeDescription
Mode entry
  • – The MPU sub-system is in CStandby and there is no active EXTI wakeup source.
  • – PDDS bit selects Standby.
  • – All WKUPF bits in Power Control/Status register (PWR_WKUPFR) are cleared.
  • – All RTC wakeup events are cleared.
Mode exit
  • – WKUP pins, RTC alarm (Alarm A and Alarm B), RTC wakeup, tamper event, time stamp event, application reset (such as NRST, IWDG(1)) or system reset.
Wakeup latencySee Figure 43: Device Standby mode power control.
  1. 1. The IWDG1 and IWDG2 when configured to generate an Application reset and when configured to generate a system debug wakeup event, reset in both cases the system.

I/O states in Standby mode

In Standby mode, all I/O pins are high impedance no pull except for:

Power supply Standby sequence

The system Standby mode sequence is shown in Figure 43. Standby mode is entered when selected by the PDDS register bit in PWR MPU control register (PWR_MPUCR).

  1. 1. When entering Standby mode, the PWR_ON and PWR_CPU_ON signals request the \(V_{DDCORE}\) and \(V_{DDCPU}\) supplies to be powered off and hclk4 is stopped. The oscillators are also stopped. The PWR_LP signal is cleared low.
    If needed, a guaranteed minimum PWR_ON and PWR_CPU_ON Standby pulse low time can be defined in PWR control register 3 (PWR_CR3) bits POPL.
  2. 2. On a wakeup event, the external regulators are requested, via the PWR_ON and PWR_CPU_ON signals, to switch on the \(V_{DDCORE}\) and \(V_{DDCPU}\) supplies.
    When a wakeup event occurs before the guaranteed minimum PWR_ON pulse low time, the external regulators are only requested to switch on \(V_{DDCORE}\) and \(V_{DDCPU}\) after the minimum Standby PWR_ON and PWR_CPU_ON pulse low time.
    As long as the \(V_{DDCORE}\) supply is below the \(V_{TH\_VDDCORE}\) threshold the system is kept in Reset
  3. 3. Once the \(V_{DDCORE}\) supply is above the \(V_{TH\_VDDCORE}\) threshold level, a delay \(t_{VDDCORE\_TEMPO}\) is inserted to wait that \(V_{DDCORE}\) has reached minimum operating value (refer to the datasheet for the value of \(t_{VDDCORE\_TEMPO}\) and \(V_{DDCORE}\) minimum operating value).
  4. 4. The system is taken out of reset, where after the HSI oscillator is enabled.
  5. 5. Once the HSI oscillator is stable, the hardware initializes the system.
  6. 6. Once the \(V_{DDCPU}\) supply is above the \(V_{TH\_VDDCPU}\) threshold level, a delay \(t_{VDDCPU\_TEMPO}\) is inserted to wait that \(V_{DDCPU}\) has reached minimum operating value

(refer to the datasheet for the value of \(t_{VDDCPU\_TEMPO}\) and \(V_{DDCPU}\) minimum operating value).

When both the HSI oscillator is stable and the \(V_{DDCPU}\) supply is above the vddcpu_ok threshold, a programmable EADLY[2:0] delay is used in the boot ROM to make sure all bootable external interfaces are correctly supplied before the boot ROM starts accessing them. See Section 10: Reset and clock control (RCC) for details on EADLY[2:0] programming.

Figure 43. Device Standby mode power control

Timing diagram for Device Standby mode power control showing signals PWR_CPU_ON, PWR_ON, PWR_LP, VDDCPU, vddcpu_ok, VDDCORE, vddcore_ok, Operating mode, and hclk4. It details the sequence from Run to Standby, POR Reset, Wait HSI oscillator, HW system Init, and back to Run, including timing parameters like tVDDCPU_TEMPO, tVDDCORE_TEMPO, and EADLY[2:0] delay.

The diagram illustrates the power control sequence for Device Standby mode. It shows the following signals and their transitions:

MSv65235V2

Timing diagram for Device Standby mode power control showing signals PWR_CPU_ON, PWR_ON, PWR_LP, VDDCPU, vddcpu_ok, VDDCORE, vddcore_ok, Operating mode, and hclk4. It details the sequence from Run to Standby, POR Reset, Wait HSI oscillator, HW system Init, and back to Run, including timing parameters like tVDDCPU_TEMPO, tVDDCORE_TEMPO, and EADLY[2:0] delay.

9.6.12 System VBAT mode

In VBAT mode the \(V_{DD}\), \(V_{DDCORE}\) and \(V_{DDCPU}\) supply regulators are powered off and VSW backup domain (i.e. RTC registers, RTC backup register, LSE, backup RAM) is powered with VBAT pin.

I/O states in VBAT mode

In VBAT mode, all I/O pins are powered down except for RTC and tamper pins

Power supply VBAT sequence.

The system VBAT mode sequence is shown in Figure 44.

  1. 1. The device can be set in VBAT mode by powering down the \(V_{DD}\) supply. The \(V_{DDCORE}\) and \(V_{DDCPU}\) supplies must be powered off before \(V_{DD}\) (PWR_ON and PWR_CPU_ON low level). When system is in Standby mode this is already the case.
  2. 2. When powering down \(V_{DD}\), the device enters VBAT mode. The PWR_ON, PWR_CPU_ON and PWR_LP signals become HiZ.
  3. 3. To exit VBAT mode, the \(V_{DD}\) supply must be reestablished, the POR monitors the \(V_{DD}\) supply. Once the supply is above the POR threshold level the External Voltage regulators providing the \(V_{DDCORE}\) and \(V_{DDCPU}\) supplies are enabled via the PWR_ON and PWR_CPU_ON pins:
    As long as \(V_{DDCORE}\) is below the vddcore_ok threshold the system is kept in reset.
  4. 4. Once the \(V_{DDCORE}\) supply is above the vddcore_ok threshold level, the system is taken out of reset after the HSI oscillator is enabled.
  5. 5. Once the HSI oscillator is stable, the hardware initializes the system.
  6. 6. When both the HSI oscillator is stable and the \(V_{DDCPU}\) supply is above the vddcpu_ok threshold, a programmable EADLY[2:0] delay is used in the boot ROM to make sure all bootable external interfaces are correctly supplied before the boot ROM starts accessing them. See Section 10: Reset and clock control (RCC) for details on EADLY[2:0] programming.
  7. 7. Run mode is entered at the end of EADLY[2:0] delay.

Figure 44. Device VBAT mode power control

Timing diagram for Device VBAT mode power control showing the sequence of events from Operating mode to Run mode.

The diagram illustrates the power control sequence for a device entering and exiting VBAT mode. It shows the following signals and states over time:

The diagram is labeled MSv65236V2.

Timing diagram for Device VBAT mode power control showing the sequence of events from Operating mode to Run mode.

9.6.13 Debug Stop

When the system enters low-power mode Stop, operation depends on the DBG_STOP configuration in the DBGMCU module.

When debug in Stop mode is enabled, when entering Stop, LP-Stop, LPLV-Stop and LPLV-Stop2 modes the PWR does not signal low-power mode on the PWR_ON, PWR_CPU_ON and PWR_LP signals. This keeps the \(V_{DDCORE}\) and \(V_{DDCPU}\) domains supplied from the regulator in main mode.

When exiting Stop, LP-Stop, LPLV-Stop or LPLV-Stop2 modes the MPU and system logic is enabled as from normal Stop mode, the STOPF flag is set and when the MPU has entered CStandby mode the SBFMPU flag is set as well.

9.6.14 Debug Standby

When the system enters low-power mode Standby, operation depends on the DBG_STBY configuration in the DBG module.

When debug in Standby mode is enabled, when entering Standby mode the PWR keeps PWR_ON and PWR_CPU_ON active, allowing the \(V_{DDCORE}\) and \(V_{DDCPU}\) domains to remain supplied. In Standby mode the \(V_{DDCORE}\) and \(V_{DDCPU}\) domains are not reset, allowing the CPU and bus clocks to remain active.

When exiting Standby mode a reset is generated, which resets the \(V_{DDCORE}\) and \(V_{DDCPU}\) logic excluding the debug logic. Waking up from debug Standby mode the MPU and system logic is reset as from normal Standby mode and the SBF and SBFMPU flags are set.

9.7 PWR WKUP pins

The WKUP polarity must only be changed in WKUPP when the wakeup interrupt is disabled, in WKUPEN.

To avoid false interrupts, the WKUPF flag must be cleared with WKUPC, before enabling the wakeup interrupt in WKUPEN.

see:

9.8 PWR_ON, PWR_CPU_ON and PWR_LP pins

The PWR_ON pin may signal pwr_on or pwr_onlp depending the selection in LPCFG register bit in PWR control register 1 (PWR_CR1).

The PWR_LP pin signals pwr_onlp

Figure 45. PWR_ON and PWR_LP pins multiplexing

Block diagram showing the multiplexing of PWR_ON and PWR_LP pins. PWR_ON and PWR_LP pins are connected to a multiplexer. The multiplexer output is connected to an AND gate and a Minimum pulse width block. The AND gate output is connected to pwr_onlp and pwr_lp(1). The Minimum pulse width block output is connected to pwr_on(2) and POPL. The LPCFG pin controls the multiplexer selection.

The diagram illustrates the multiplexing logic for PWR_ON and PWR_LP pins. The PWR_ON pin is connected to a multiplexer (with inputs 0 and 1). The PWR_LP pin is connected to the same multiplexer. The output of the multiplexer is connected to an AND gate and a Minimum pulse width block. The AND gate output is connected to pwr_onlp and pwr_lp(1). The Minimum pulse width block output is connected to pwr_on(2) and POPL. The LPCFG pin controls the multiplexer selection.

Block diagram showing the multiplexing of PWR_ON and PWR_LP pins. PWR_ON and PWR_LP pins are connected to a multiplexer. The multiplexer output is connected to an AND gate and a Minimum pulse width block. The AND gate output is connected to pwr_onlp and pwr_lp(1). The Minimum pulse width block output is connected to pwr_on(2) and POPL. The LPCFG pin controls the multiplexer selection.
  1. 1. pwr_lp signal is cleared low when system entering Low Power Stop mode. See LPDS bit in PWR control register 1 (PWR_CR1).
  2. 2. pwr_on signal is cleared low when system requests external VDDCORE supply regulator to switch off VDDCORE.

PWR_ON pin

When LPCFG selects pwr_on signaling, the PWR_ON pad is only low in Standby mode.

When LPCFG selects pwr_onlp signaling on PWR_ON, the definition (Standby, LP-Stop, LPLV-Stop or LPLV-Stop2) of the signal being low must be communicated to the external power management device prior to entering low-power mode. The PWR_ON pad is low in Standby, LP-Stop, LPLV-Stop and LPLV-Stop2 modes.

PWR_CPU_ON pin

The PWR_CPU_ON pin is cleared low when the system is entering LPLV-Stop2 or Standby mode, requesting that the external VDDCPU supply regulator be switched off.

9.9 PWR interrupts

The PWR provides the following interrupts:

Other status flags associated with Stop and Standby modes and monitoring functions are also available, see Table 45:

Table 45. PWR status flags

Status FlagDescriptionInterruptClear through
STOPFExit from System Stop, LP-Stop, LPLV-Stop or LPLV-Stop2 modesWakeup from Stop mode eventsCSSF
SBF(1)Exit from System Standby modeWakeup from Standby events.CSSF

Table 45. PWR status flags (continued)

Status FlagDescriptionInterruptClear through
SBFMPU(1)MPU exit CStandby mode (System LPLV-Stop2 or System Standby mode)Wakeup from CStandby, events.CSSF
WKUPF[6:1]Wakeup flagsMPU wakeup from Standby and Stop events.WKUPC[6:1]
PVDOProgrammable voltage detectorInterrupt via EXTIn.a.
AVDOAnalog voltage detectorInterrupt via EXTIn.a.
VBATL, VBATHVBAT supply monitoringWakeup from Standby and Stop via RTC tamper interruptn.a.
TEMPL, TEMPHTemperature monitoringWakeup from Standby and Stop via RTC tamper interruptn.a.
BRRDYBackup regulator readyNo associated interruptn.a.
USB33RDYUSB HS 3V3 supply readyNo associated interruptn.a.
REG18RDYRegulator 1V8 supply readyNo associated interruptn.a.
REG11RDYRegulator 1V1 supply readyNo associated interruptn.a.

9.10 PWR TrustZone security

The PWR is able to prevent registers from being modified by non-secure accesses. The TrustZone security is activated by the RCC PWRSEC register bit in Section 10.8.1: RCC secure configuration register (RCC_SECCFGR). At PWR level the security consists in preventing a non-secure write access from changing:

The PWR TrustZone security enables write access security for all features simultaneously.

Table 46. Register security overview

Register nameAccess typeSecurity(1)
PWR_CR1RWWrite security
PWR_CSR1RNon secure

Table 46. Register security overview (continued)

Register nameAccess typeSecurity(1)
PWR_CR2RWWrite secure
PWR_CR3RWWrite secure
PWR_MPUCRRWWrite secure
PWR_WKUPCRRWWrite secure(2)
PWR_WKUPFRRNon secure
PWR_MPUWKUPENRRWWrite secure
PWR_VERRRNon secure
PWR_IDRNon secure
PWR_SIDRNon secure
  1. 1. Security is enabled with the RCC PWRSEC register bit in Section 10.8.1: RCC secure configuration register (RCC_SECCFGR).
  2. 2. Security is additionally channel wise enabled with WKUPEN bits in PWR MPU wakeup enable register (PWR_MPUWKUPENR) register.

9.11 PWR registers

The PWR registers can be accessed in word, half-word and byte format, unless explicitly specified differently.

9.11.1 PWR control register 1 (PWR_CR1)

Address offset: 0x000

Reset value: 0x0000 0200

Reset on any system reset.

This register provides write access security when enabled by PWRSEC register bit in Section 10.8.1: RCC secure configuration register (RCC_SECCFGR). When security is enabled a non-secure write access generates a bus error. Secure and non-secure read accesses are granted and return the register value.

31302928272625242322212019181716
Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.ALS[1:0]AVDEN
rwrwrw
1514131211109876543210
Res.Res.Res.Res.Res.Res.MPU_RAM_LOW_SPEEDDBPPLS[2:0]PVDENSTOP2LVDSLPCFGLPDS
rwrwrwrwrwrwrwrwrwrw

Bits 31:19 Reserved, must be kept at reset value.

Bits 18:17 ALS[1:0]: Analog Voltage Detector level selection.

These bits select the voltage threshold detected by the AVD.

00: 1.7V

01: 2.1V

10: 2.5V

11: 2.8V

Bit 16 AVDEN: Peripheral Voltage Monitor on \(V_{DDA}\) enable.

0: Peripheral Voltage Monitor on \(V_{DDA}\) disabled

1: Peripheral Voltage Monitor on \(V_{DDA}\) enabled

Bits 15:10 Reserved, must be kept at reset value.

Bit 9 MPU_RAM_LOWSPEED: Low speed selection for MPU memories

This bit must be reset by software when MPU needs to operate in Run Overdrive (high speed) mode, after the \(V_{DDCPU}\) supply has reached the overdrive mode voltage range and prior to increasing the MPU frequency into the overdrive frequency range.

It must be set to operate in Run mode after decreasing the MPU frequency into the standard frequency range and prior to decreasing the MPU voltage below the overdrive mode voltage range

0: MPU can operate in Run Overdrive mode (\(V_{DDCPU}\) in Run Overdrive mode voltage range)

1: MPU can only operate in Run mode (\(V_{DDCPU}\) below Run Overdrive mode voltage range)

Bit 8 DBP: Disable backup domain write protection.

In reset state, the RCC_BDCR, PWR_CR2, RTC, and backup registers are protected against parasitic write access. This bit must be set to enable write access to these.

0: Write access to RTC and backup domain registers disabled.

1: Write access to RTC and backup domain registers enabled.

Bits 7:5 PLS[2:0]: Programmable Voltage Detector level selection.

These bits are read only when the SYSCFG register bit PVDL is set (when PVDL is set, there is no bus errors generated when writing this register).

These bits select the voltage threshold detected by the PVD.

000: 1.95 V

001: 2.1 V

010: 2.25 V

011: 2.4 V

100: 2.55 V

101: 2.7 V

110: 2.85 V

111: External voltage level on PVD_IN (compared to internal VREFINT)

Bit 4 PVDEN: Programmable Voltage detector enable.

This bit is read only when the SYSCFG register bit PVDL is set (when PVDL is set, there is no bus errors generated when writing this register).

0: Programmable Voltage detector disabled.

1: Programmable Voltage detector enabled.

Bit 3 STOP2: System LPLV-Stop2 mode selection

0: Keeps System Stop mode when PDDS=0 and MPU enters CStop

1: Allows System LPLV-Stop2 mode when PDDS = 0

Bit 2 LVDS: Low Voltage Deepsleep LPLV-Stop mode selection.

This bit has only effect when the low power stop mode is selected in LPDS and changes the \(V_{DDCORE}\) and \(V_{DDCPU}\) domains supply reset level.

0: LP-Stop mode \(V_{DDCORE}\) and \(V_{DDCPU}\) domains supply reset level at same level as Run mode. The \(V_{DDCORE}\) and \(V_{DDCPU}\) domains supply level in LP-Stop mode must be kept at same level as Run mode.

1: LPLV-Stop mode \(V_{DDCORE}\) and \(V_{DDCPU}\) domains supply reset level at lower level than Run mode. Allows to lower \(V_{DDCORE}\) and \(V_{DDCPU}\) domains supply level in LPLV-Stop mode (see the datasheet for voltage levels).

Bit 1 LPCFG: PWR_ON pin configuration.

0: PWR_ON pin signals Standby mode (PWR_ON =1 in Run, Stop, LP-Stop, LPLV-Stop, LPLV-Stop2 and 0 in Standby).

1: PWR_ON pin signals Standby, LP-Stop, LPLV-Stop and LPLV-Stop2 modes (PWR_ON = 1 in Run, Stop, and 0 in LP-Stop, LPLV-Stop, LPLV-Stop2 and Standby).

Bit 0 LPDS: Low Power Deepsleep Stop mode selection.

0: Stop mode selected, External regulator kept in Main power mode (pwr_lp = 1).

1: low-power stop mode selected External regulator may enter Low-power mode (pwr_lp = 0). Further low power mode selection is provided by LVDS.

9.11.2 PWR control status register 1 (PWR_CSR1)

Address offset: 0x004

Reset value: 0x0000 0000

Reset on any system reset.

31302928272625242322212019181716
Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.AVDO
r
1514131211109876543210
Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.PVDORes.Res.Res.Res.
r

Bits 31:17 Reserved, must be kept at reset value.

Bit 16 AVDO: Analog Voltage detector Output on \(V_{DDA}\).

This bit is set and cleared by hardware. It is valid only if AVD on \(V_{DDA}\) is enabled by the AVDEN bit.

0: \(V_{DDA}\) is equal or higher than the AVD threshold selected with the ALS[2:0] bits.

1: \(V_{DDA}\) is lower than the AVD threshold selected with the ALS[2:0] bits

Note: The AVD is disabled in Standby mode and after system reset. For this reason, this bit is equal to 0 after Standby and reset.

Bits 15:5 Reserved, must be kept at reset value.

Bit 4 PVDO: Programmable Voltage Detect Output

This bit is set and cleared by hardware. It is valid only if PVD is enabled by the PVDEN bit.

0: \(V_{DD}\) or voltage level on PVD_IN is equal or higher than the PVD threshold selected with the PLS[2:0] bits.

1: \(V_{DD}\) or voltage level on PVD_IN is lower than the PVD threshold selected with the PLS[2:0] bits.

Note: The PVD is disabled in Standby mode and after a system reset. For this reason, this bit is equal to 0 after Standby and system reset.

Bits 3:0 Reserved, must be kept at reset value.

9.11.3 PWR control register 2 (PWR_CR2)

Address offset: 0x008

Reset value: 0x0000 0000

Not reset by wakeup from Standby mode, Application reset (NRST, IWDG, ...) and \(V_{DD}\) POR, but reset only by \(V_{SW}\) POR and VSWRST.

Access 6 wait states when writing this register.

After reset the register is write-protected and the DBP bit in the PWR control register 1 (PWR_CR1) has to be set before it can be written. When DBP is cleared, there are no bus errors generated when writing this register.

This register must not be accessed when the RCC VSWRST register bit in Section 10.8.6: RCC low-power Stop modes delay control register (RCC_PWRLPDLYCR) resets the VSW domain.

This register provides Write access security when enabled by PWRSEC register bit in Section 10.8.1: RCC secure configuration register (RCC_SECCFGR). When security is enabled a non-secure write access generates a bus error. Secure and non-secure read accesses are granted and return the register value.

When a system reset occurs during the register write cycle the written data is not guaranteed.

31302928272625242322212019181716
Res.Res.Res.Res.Res.Res.Res.Res.TEMPHTEMPLVBATHVBATLRes.Res.Res.BRRDY
rrrrr
1514131211109876543210
Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.MON
EN
Res.Res.Res.BREN
rwrw

Bits 31:24 Reserved, must be kept at reset value.

Bit 23 TEMPH: Monitored temperature level above high threshold

0: Temperature below high threshold level, or Monitor disabled.

1: Temperature equal or above high threshold level.

Bit 22 TEMPL: Monitored temperature level above low threshold

0: Temperature above low threshold level, or Monitor disabled.

1: Temperature equal or below low threshold level.

9.11.4 PWR control register 3 (PWR_CR3)

Address offset: 0x00C

Reset value: 0x5000 A000

Not reset by wakeup from Standby mode and Application reset (such as NRST, IWDG) but only reset by VDD POR.

Access 6 wait states when writing this register.

This register provides Write access security when enabled by PWRSEC register bit in Section 10.8.1: RCC secure configuration register (RCC_SECCFGR). When security is

enabled a non-secure write access generates a bus error. Secure and non-secure read accesses are granted and return the register value.

When a system reset occurs during the register write cycle the written data is not guaranteed.

31302928272625242322212019181716
REG11
RDY
REG11
EN
REG18
RDY
REG18
EN
Res.USB33
RDY
Res.USB33
DEN
VDDSD
2VALID
VDDSD
1VALID
POPL[4:0]VDDSD
2RDY
rrwrrwrrwrwrwrwrwrwrwrwr
1514131211109876543210
VDDSD
2DEN
VDDSD
1RDY
VDDSD
1DEN
DDRR
ETEN
DDRS
RDIS
DDRS
REN
VBRSVBERes.Res.Res.Res.Res.Res.Res.Res.
rwrrwrwrwrwrwrw

Bit 31 REG11RDY: 1V1 regulator supply ready

Bit 30 REG11EN: 1V1 regulator enable

Bit 29 REG18RDY: 1V8 regulator supply ready

Bit 28 REG18EN: 1V8 regulator enable

Bit 27 Reserved, must be kept at reset value.

Bit 26 USB33RDY: USB 3.3V supply ready

Bit 25 Reserved, must be kept at reset value.

Bit 24 USB33DEN: USB 3.3V voltage level detector enable

Bit 23 VDDSD2VALID: Override VDDSD2 voltage detector

Bit 22 VDDSD1VALID: Override \(V_{DDSD1}\) voltage detector

This bit enables the I/Os in the \(V_{DDSD1}\) domain whatever the state of VDDSD1RDY. This bit can be set by software once \(V_{DDSD1}\) is higher than \(V_{DDSDx\_TH}\) and stable (bit VDDSD1RDY = 1). Subsequently VDDSD1EN can be reset to 0 to disable the voltage detector and save power (refer to datasheet for \(V_{DDSDx\_TH}\) value).

0: I/O enable/disable is controlled by the \(V_{DDSD1}\) voltage detector

1: I/O enable is forced active

Bits 21:17 POPL[4:0]: PWR_ON, PWR_CPU_ON Standby pulse low configuration

These bits are set and cleared by software. They define the minimum guaranteed duration of the PWR_ON and PWR_CPU_ON low pulse in Standby mode (there is no impact on the LP-Stop and LPLV-Stop modes).

The LSI oscillator is automatically enabled when needed by the POPL pulse low configuration.

00000: ~ 62.5 us guaranteed minimum low time (2 LSI cycles)

00001: ~ 1 ms guaranteed minimum low time (1 x 32 LSI cycles)

00010: ~ 2 ms guaranteed minimum low time (2 x 32 LSI cycles)

...

11111: ~ 31 ms guaranteed minimum low time (31 x 32 LSI cycles)

Bit 16 VDDSD2RDY: \(V_{DDSD2}\) supply ready

When the level detector is active (VDDSD2DEN = 1), this bit indicates if a voltage higher than \(V_{DDSDx\_TH}\) is present on the \(V_{DDSD2}\) supply (refer to datasheet for \(V_{DDSDx\_TH}\) value).

0: \(V_{DDSD2}\) supply not present, or voltage detector switched off (VDDSD2EN = 0)

1: \(V_{DDSD2}\) supply present

Bit 15 VDDSD2DEN: \(V_{DDSD2}\) voltage level detector enable

The voltage level detector is active by default. It enables the I/Os in the \(V_{DDSD2}\) domain if and when the \(V_{DDSD2}\) supply voltage is higher than \(V_{DDSDx\_TH}\). Once the supply is stable above this threshold (VDDSD2RDY = 1), the level detectors can be switched off to save power, without disabling the I/Os, by setting VDDSD2VALID = 1 followed by VDDSD2EN = 0 (refer to datasheet for \(V_{DDSDx\_TH}\) value).

0: \(V_{DDSD2}\) level detector switched off. I/Os in \(V_{DDSD2}\) domain are also disabled if VDDSD2VALID = 0

1: \(V_{DDSD2}\) level detector is active. I/Os in \(V_{DDSD2}\) domain are active if VDDSD2RDY = 1

Bit 14 VDDSD1RDY: \(V_{DDSD1}\) supply ready

When the level detector is active (VDDSD1DEN = 1), this bit indicates if a voltage higher than \(V_{DDSDx\_TH}\) is present on the \(V_{DDSD1}\) supply (refer to datasheet for \(V_{DDSDx\_TH}\) value).

0: \(V_{DDSD1}\) supply not present, or voltage detector switched off (VDDSD1EN = 0)

1: \(V_{DDSD1}\) supply present

Bit 13 VDDSD1DEN: \(V_{DDSD1}\) voltage level detector enable

The voltage level detector is active by default. It enables the I/Os in the \(V_{DDSD1}\) domain if and when the \(V_{DDSD1}\) supply voltage is higher than \(V_{DDSDx\_TH}\). Once the supply is stable above this threshold (VDDSD1RDY = 1), the level detectors can be switched off to save power, without disabling the I/Os, by setting VDDSD1VALID = 1 followed by VDDSD1EN = 0 (refer to datasheet for \(V_{DDSDx\_TH}\) value).

0: \(V_{DDSD1}\) level detector switched off. I/Os in \(V_{DDSD1}\) domain are also disabled if VDDSD1VALID = 0

1: \(V_{DDSD1}\) level detector is active. I/Os in \(V_{DDSD1}\) domain are active if VDDSD1RDY = 1

Bit 12 DDRRETEN: DDR retention enable

Set by Hardware on NRST pad reset, when the reset delay control is enabled in the RCC_MP_APRSTCR.RDCTLEN register bit, or when written ‘b1 by software, the DDR PHY puts its pads in retention.

To disable retention software must write this bit to ‘b0.

0: DDR self-refresh retention disabled.

1: DDR self-refresh retention enabled.

Bit 11 DDRSRDIS: DDR self-refresh retention after standby disable

When written ‘b1, the DDR PHY pads retention, enabled due to DDRSREN, is disabled.

0: No action

1: When DDRSREN is ‘b1: Disable DDR self-refresh retention after standby mode. This bit is reset by hardware once DDR self-refresh retention has been disabled.

When DDRSREN is ‘b0 no action.

Bit 10 DDRSREN: DDR self-refresh in standby mode enable

When set, the DDR PHY puts its pads in retention when entering Standby mode.

0: DDR self-refresh retention when entering standby mode disabled.

1: DDR self-refresh retention when entering standby mode enabled (DDR self-refresh retention after Standby must be disabled by DDRSRDIS).

Bit 9 VBRS: VBAT charging resistor selection

0: Charges VBAT through a 5 kOhm resistor.

1: Charges VBAT through a 1.5 kOhm resistor.

Bit 8 VBE: VBAT charging enable

0: VBAT battery charging disabled.

1: VBAT battery charging enabled.

Bits 7:0 Reserved, must be kept at reset value.

9.11.5 PWR MPU control register (PWR_MPUCR)

Address offset: 0x010

Reset value: 0x0000 0000

See individual bits for reset condition.

Access 6 wait states when writing this register.

This register provides Write access security when enabled by PWRSEC register bit in Section 10.8.1: RCC secure configuration register (RCC_SECCFGR). When security is enabled a non-secure write access generates a bus error. Secure and non-secure read accesses are granted and return the register value.

When a system reset occurs during the register write cycle the written data is not guaranteed.

31302928272625242322212019181716
Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.
1514131211109876543210
STAND
BYWFI
L2
Res.Res.Res.Res.Res.CSSFRes.SBFMP
U
SBFSTOPFRes.Res.Res.Res.PDDS
rrwrrrrw

Bits 31:16 Reserved, must be kept at reset value.

Bit 15 STANDBYWFIL2: MPU system idle indication

This bit is set and reset by hardware based on the MPU operation mode.

0: MPU system CRun

1: MPU system CSleep or CStop or CStandby

Bits 14:10 Reserved, must be kept at reset value.

Bit 9 CSSF: Clear MPU Standby, Stop flags.(Always read as 0)

This bit is reset on any system reset.

0: No effect

1: When written, clears the MPU flags (STOPF, SBF, and SBFMPU). The register bit is cleared to 0 by hardware.

Bit 8 Reserved, must be kept at reset value.

Bit 7 SBFMPU: MPU Standby flag

This bit is set by hardware and cleared only by a \(V_{DD}\) POR reset or by setting the MPU CSSF bit (not reset when exit from Standby mode). This bit is cleared by the MPU boot ROM. For more information refer to Boot ROM application note.

0: MPU has not been in CStandby mode.

1: MPU has been in CStandby mode.

Bit 6 SBF: System Standby flag

This bit is set by hardware and cleared only by a \(V_{DD}\) POR reset or by setting the MPU CSSF bit (not reset when exit from Standby mode). This bit is cleared by the MPU Boot ROM. For more information refer to Boot ROM application note.

0: System has not been in Standby mode.

1: System has been in Standby mode, system contents has been lost.

Bit 5 STOPF: Stop flag

This bit is set by hardware and cleared only by any system reset or by setting the MPU CSSF bit. This bit is cleared by the MPU Boot ROM. For more information refer to Boot ROM application note.

0: System has not been in Stop mode

1: System has been in Stop mode, clock system has been stopped.

Bits 4:1 Reserved, must be kept at reset value.

Bit 0 PDDS: System Power Down Deepsleep selection

This bit is reset only by a \(V_{DD}\) POR reset (not reset when exit from Standby mode).

Allows to define the Deepsleep mode for the system.

0: Keeps System Stop when MPU enters to CStop or System LPLV-Stop2 mode when MPU enters to CStandby.

1: Allows System Standby mode when MPU enters to CStandby.

9.11.6 PWR wakeup control register (PWR_WKUPCR)

Address offset: 0x020

Reset value: 0x0000 0000

Not reset by wakeup from Standby mode, but by any application reset (such as NRST, IWDG).

Access 6 wait states when writing this register (when clearing a WKUPF, the AHB write access completes after the WKUPF has cleared).

This register provides Write access security when enabled by PWRSEC register bit in Section 10.8.1: RCC secure configuration register (RCC_SECCFGR). When security is enabled a non-secure write access on individual WKUPC[6:1], WKUPP[6:1] bits and WKUPPUPD[6:1] bit pairs are discarded when the corresponding WKUPEN[6:1] bit in PWR MPU wakeup enable register (PWR_MPUWKUPENR) is set. No bus error is generated. Secure and non-secure read accesses are granted and return the register value.

When a system reset occurs during the register write cycle the written data is not guaranteed.

31302928272625242322212019181716
Res.Res.Res.Res.WKUPPUPD6 [1:0]WKUPPUPD5 [1:0]WKUPPUPD4 [1:0]WKUPPUPD3 [1:0]WKUPPUPD2 [1:0]WKUPPUPD1 [1:0]
rwrwrwrwrwrwrwrwrwrwrwrw
1514131211109876543210
Res.Res.WKUP P6WKUP P5WKUP P4WKUP P3WKUP P2WKUP P1Res.Res.WKUP C6WKUP C5WKUP C4WKUP C3WKUP C2WKUP C1
rwrwrwrwrwrwrc_w1rc_w1rc_w1rc_w1rc_w1rc_w1

Bits 31:28 Reserved, must be kept at reset value.

Bits 27:16 WKUPPUPDn[1:0]: Wakeup pull configuration for WKUPn pin (n = 6 to 1)

These bits define the IO pad pull configuration used when WKUPENn = 1 (note that the associated GPIO port pull configuration must be set to the same value or 00). The wakeup pin pull configuration is maintained in Standby mode.

When PWRSEC is enabled in the RCC and WKUPENn in PWR MPU wakeup enable register (PWR_MPUWKUPENR) is set, bit pair n can only be written by a secure access, a non-secure write on this bit pair is discarded.

When PWRSEC is disabled in the RCC or WKUPENn in PWR MPU wakeup enable register (PWR_MPUWKUPENR) is clear, bit pair n can be written by a secure and non-secure access.

Bits 15:14 Reserved, must be kept at reset value.

Bits 13:8 WKUPP[6:1]: Wakeup Polarity bit for WKUPn pin, n range [6:1]

These bits define the polarity used for event detection on external wake-up WKUPn pin.

When PWRSEC is enabled in the RCC and WKUPENn in PWR MPU wakeup enable register (PWR_MPUWKUPENR) is set, bit n can only be written by a secure access, a non-secure write on this bit is discarded.

When PWRSEC is disabled in the RCC or WKUPENn in PWR MPU wakeup enable register (PWR_MPUWKUPENR) is clear, bit n can be written by a secure and non-secure access.

Bits 7:6 Reserved, must be kept at reset value.

Bits 5:0 WKUPC[6:1]: Clear Wakeup Flag for WKUPn pin, n range [6:1]

When PWRSEC is enabled in the RCC and WKUPENn in PWR MPU wakeup enable register (PWR_MPUWKUPENR) is set, bit n can only be written by a secure access, a non-secure write on this bit is discarded.

When PWRSEC is disabled in the RCC or WKUPENn in PWR MPU wakeup enable register (PWR_MPUWKUPENR) is clear, bit n can be written by a secure and non-secure access.

These bits are always read as 0.

0: No effect

1: Writing 1 clears the WKUPFn wakeup flag (the bit is cleared to 0 by hardware).

9.11.7 PWR wakeup flag register (PWR_WKUPFR)

Address offset: 0x024

Reset value: 0x0000 0000

Not reset by wakeup from Standby mode but by any Application reset (NRST, IWDG, ...)

31302928272625242322212019181716
Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.
1514131211109876543210
Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.WKUP F6WKUP F5WKUP F4WKUP F3WKUP F2WKUP F1
rrrrrr

Bits 31:6 Reserved, must be kept at reset value.

Bits 5:0 WKUPF[6:1]: Wakeup flag for WKUPn pin before enable, n range [6:1].

This bit is set by hardware and cleared only by a NRST Reset or by setting the WKUPCn bit in the PWR wakeup control register (PWR_WKUPCR)

0: No wakeup event occurred

1: A wakeup event was received from WKUPCn pin

9.11.8 PWR MPU wakeup enable register (PWR_MPUWKUPENR)

Address offset: 0x028

Reset value: 0x0000 0000

Not reset by wakeup from Standby mode but by any Application reset (NRST, IWDG, ...).

Access 6 wait states when writing this register.

This register provides Write access security when enabled by PWRSEC register bit in Section 10.8.1: RCC secure configuration register (RCC_SECCFGR). When security is enabled a non-secure write access is discarded and a bus error is generated. Secure and non-secure read accesses are granted and return the register value.

When a system reset occurs during the register write cycle the written data is not guaranteed.

31302928272625242322212019181716
Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.
1514131211109876543210
Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.WKUP
EN6
WKUP
EN5
WKUP
EN4
WKUP
EN3
WKUP
EN2
WKUP
EN1
rwrwrwrwrwrw

Bits 31:6 Reserved, must be kept at reset value.

Bits 5:0 WKUPEN[6:1]: Enable Wakeup WKUPn pin and interrupt for MPU, n range [6:1]

Each bit is set and cleared by software.

When PWRSEC is enabled in the RCC, these bits can only be written by a secure access, a non-secure write is discarded.

When PWRSEC is disabled in the RCC, these bits can be written by a secure and non-secure access.

0: An event on WKUPn pin does not wake up the system from Standby and Stop mode, nor generates an interrupt to MPU.

1: A rising or falling edge on WKUPn pin wakes up the system from Standby and Stop mode and generates an interrupt to MPU.

9.11.9 PWR IP version register (PWR_VERR)

Address offset: 0x3F4

Reset value: 0x0000 0020

31302928272625242322212019181716
Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.
1514131211109876543210
Res.Res.Res.Res.Res.Res.Res.Res.MAJREV[3:0]MINREV[3:0]
rrrrrrrr

Bits 31:8 Reserved, must be kept at reset value.

Bits 7:4 MAJREV[3:0]: Major revision number

Bits 3:0 MINREV[3:0]: Minor revision number

9.11.10 PWR IP identification register (PWR_ID)

Address offset: 0x3F8

Reset value: 0x0001 0001

31302928272625242322212019181716
IPID[31:16]
rrrrrrrrrrrrrrrr
1514131211109876543210
IPID[15:0]
rrrrrrrrrrrrrrrr

Bits 31:0 IPID[31:0]: IP identification

9.11.11 PWR size ID register (PWR_SID)

Address offset: 0x3FC

Reset value: 0xA3C5 DD01

31302928272625242322212019181716
SID[31:16]
rrrrrrrrrrrrrrrr
1514131211109876543210
SID[15:0]
rrrrrrrrrrrrrrrr

Bits 31:0 SID[31:0]: Size identification

9.11.12 PWR register map

Table 47. Power control register map and reset values

OffsetRegister313029282726252423222120191817161514131211109876543210
0x000PWR_CR1Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.ALS[1:0]AVDENRes.Res.Res.Res.Res.Res.Res.MPU_RAM_LOWSPEEDDBPPLS[2:0]PVDENSTOP2LVDSLPCFGLPDS
Reset value0001000000000
0x004PWR_CSR1Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.AVDORes.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.
Reset value0
0x008PWR_CR2Res.Res.Res.Res.Res.Res.Res.Res.TEMPHTEMPLVBATHVBATLRes.Res.Res.BRRDYRes.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.MONENRes.Res.Res.BREN
Reset value0000000
0x00CPWR_CR3REG11RDYREG11ENREG18RDYREG18ENRes.USB33RDYRes.USB33DENVDDSD2VALIDVDDSD1VALIDPOPL[4:0]VDDSD2RDYVDDSD2DENVDDSD1RDYVDDSD1DENDDRRETNDDRSRDISDDRSRENVBRVBERes.Res.Res.Res.Res.Res.Res.Res.
Reset value0101000000000010100000
0x010PWR_MPUCRRes.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.STANDBYWFIL2Res.Res.Res.Res.Res.Res.CSSFRes.SBFMPUSBFSTOPFRes.Res.Res.Res.PDDS
Reset value000000
0x014-0x01CReservedRes.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.
ST logo
ST logo

Table 47. Power control register map and reset values (continued)

OffsetRegister313029282726252423222120191817161514131211109876543210
0x020PWR_WKUPCRRes.Res.Res.Res.WKUPPUPD6
[1:0]
WKUPPUPD5
[1:0]
WKUPPUPD4
[1:0]
WKUPPUPD3
[1:0]
WKUPPUPD2
[1:0]
WKUPPUPD1
[1:0]
Res.Res.WKUPP6WKUPP5WKUPP4WKUPP3WKUPP2WKUPP1Res.Res.WKUPC6WKUPC5WKUPC4WKUPC3WKUPC2WKUPC1
Reset value000000000000000000000000
0x024PWR_WKUPFRRes.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.WKUPF6WKUPF5WKUPF4WKUPF3WKUPF2WKUPF1
Reset value000000
0x028PWR_MPUWKUPENRRes.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.WKUPEN6WKUPEN5WKUPEN4WKUPEN3WKUPEN2WKUPEN1
Reset value000000
0x02C-0x3F0ReservedRes.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.
0x3F4PWR_VERRRes.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.MAJREV[3:0]MINREV[3:0]
Reset value00100000
0x3F8PWR_IDIPID[31:0]
Reset value00000000000000001000000000000001
0x3FCPWR_SIDSID[31:0]
Reset value10100011110001011101110100000001

Refer to Section 2.5 on page 153 for the register boundary addresses.