8000
We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 910f579 commit bb77c1dCopy full SHA for bb77c1d
ports/stm32/powerctrl.c
@@ -941,9 +941,11 @@ void powerctrl_enter_standby_mode(void) {
941
// Clear and mask D1 EXTIs.
942
EXTI_D1->PR1 = 0x3fffffu;
943
EXTI_D1->IMR1 &= ~(0xFFFFu); // 16 lines
944
+ #if defined(EXTI_D2)
945
// Clear and mask D2 EXTIs.
946
EXTI_D2->PR1 = 0x3fffffu;
947
EXTI_D2->IMR1 &= ~(0xFFFFu); // 16 lines
948
+ #endif
949
// Clear all wake-up flags.
950
PWR->WKUPCR |= PWR_WAKEUP_FLAG_ALL;
951
#elif defined(STM32G0) || defined(STM32G4) || defined(STM32L4) || defined(STM32WB)
@@ -970,7 +972,7 @@ void powerctrl_enter_standby_mode(void) {
970
972
PWR->CSR1 |= PWR_CSR1_EIWUP;
971
973
#endif
974
- #if defined(NDEBUG)
975
+ #if defined(NDEBUG) && defined(DBGMCU)
976
// Disable Debug MCU.
977
DBGMCU->CR = 0;
978
0 commit comments