Skip to content

Commit 9e7829f

Browse files
ABOSTMfpistm
authored andcommitted
Restore PWR clock at wakeup
This avoid to miss it in system clock configuration, as it is not systematically done by cubeMX Signed-off-by: Alexandre Bourdiol <alexandre.bourdiol@st.com>
1 parent e1c7372 commit 9e7829f

1 file changed

Lines changed: 5 additions & 0 deletions

File tree

src/low_power.c

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -347,6 +347,11 @@ void LowPower_EnableWakeUpUart(serial_t *serial, void (*FuncPtr)(void))
347347
*/
348348
WEAK void SystemClock_ConfigFromStop(void)
349349
{
350+
#if defined(__HAL_RCC_PWR_CLK_ENABLE)
351+
/* Enable PWR clock, needed for example: voltage scaling */
352+
__HAL_RCC_PWR_CLK_ENABLE();
353+
#endif
354+
350355
SystemClock_Config();
351356
}
352357

0 commit comments

Comments
 (0)