stm32/stm32_it: Fix RTC IRQ handler to handle all EXTI IRQs on F0 MCUs.
This commit is contained in:
parent
67b326d97e
commit
a270cf280b
@ -509,8 +509,18 @@ void RTC_WKUP_IRQHandler(void) {
|
||||
|
||||
void RTC_IRQHandler(void) {
|
||||
IRQ_ENTER(RTC_IRQn);
|
||||
RTC->ISR &= ~RTC_ISR_WUTF; // clear wakeup interrupt flag
|
||||
Handle_EXTI_Irq(EXTI_RTC_WAKEUP); // clear EXTI flag and execute optional callback
|
||||
if (RTC->ISR & RTC_ISR_WUTF) {
|
||||
RTC->ISR &= ~RTC_ISR_WUTF; // clear wakeup interrupt flag
|
||||
Handle_EXTI_Irq(EXTI_RTC_WAKEUP); // clear EXTI flag and execute optional callback
|
||||
}
|
||||
if (RTC->ISR & RTC_ISR_ALRAF) {
|
||||
RTC->ISR &= ~RTC_ISR_ALRAF; // clear Alarm A flag
|
||||
Handle_EXTI_Irq(EXTI_RTC_ALARM); // clear EXTI flag and execute optional callback
|
||||
}
|
||||
if (RTC->ISR & RTC_ISR_TSF) {
|
||||
RTC->ISR &= ~RTC_ISR_TSF; // clear timestamp flag
|
||||
Handle_EXTI_Irq(EXTI_RTC_TIMESTAMP); // clear EXTI flag and execute optional callback
|
||||
}
|
||||
IRQ_EXIT(RTC_IRQn);
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user