diff --git a/cpu/stm32_common/periph/rtc.c b/cpu/stm32_common/periph/rtc.c index fa513f12d2..78c8fe546e 100644 --- a/cpu/stm32_common/periph/rtc.c +++ b/cpu/stm32_common/periph/rtc.c @@ -237,7 +237,7 @@ void rtc_init(void) EXTI->FTSR &= ~(EXTI_FTSR_BIT); EXTI->RTSR |= EXTI_RTSR_BIT; EXTI->IMR |= EXTI_IMR_BIT; - EXTI->PR |= EXTI_PR_BIT; + EXTI->PR = EXTI_PR_BIT; /* enable global RTC interrupt */ NVIC_EnableIRQ(IRQN); } @@ -351,7 +351,7 @@ void ISR_NAME(void) } RTC->ISR &= ~RTC_ISR_ALRAF; } - EXTI->PR |= EXTI_PR_BIT; + EXTI->PR = EXTI_PR_BIT; /* only clear the associated bit */ cortexm_isr_end(); } diff --git a/cpu/stm32_common/periph/rtt.c b/cpu/stm32_common/periph/rtt.c index 5b59f32903..5ede032e2b 100644 --- a/cpu/stm32_common/periph/rtt.c +++ b/cpu/stm32_common/periph/rtt.c @@ -115,7 +115,7 @@ void rtt_init(void) !defined(CPU_FAM_STM32WB) EXTI->FTSR_REG &= ~(EXTI_FTSR_BIT); EXTI->RTSR_REG |= EXTI_RTSR_BIT; - EXTI->PR_REG |= EXTI_PR_BIT; + EXTI->PR_REG = EXTI_PR_BIT; #endif NVIC_EnableIRQ(LPTIM1_IRQn); /* enable timer */ @@ -206,7 +206,7 @@ void isr_lptim1(void) LPTIM1->ICR = (LPTIM_ICR_ARRMCF | LPTIM_ICR_CMPMCF); #if !defined(CPU_FAM_STM32L4) && !defined(CPU_FAM_STM32L0) && \ !defined(CPU_FAM_STM32WB) - EXTI->PR_REG |= EXTI_PR_BIT; + EXTI->PR_REG = EXTI_PR_BIT; /* only clear the associated bit */ #endif cortexm_isr_end();