Skip to content
Snippets Groups Projects
Commit a270cf28 authored by Dave Hylands's avatar Dave Hylands Committed by Damien George
Browse files

stm32/stm32_it: Fix RTC IRQ handler to handle all EXTI IRQs on F0 MCUs.

parent 67b326d9
No related branches found
No related tags found
No related merge requests found
...@@ -509,8 +509,18 @@ void RTC_WKUP_IRQHandler(void) { ...@@ -509,8 +509,18 @@ void RTC_WKUP_IRQHandler(void) {
void RTC_IRQHandler(void) { void RTC_IRQHandler(void) {
IRQ_ENTER(RTC_IRQn); IRQ_ENTER(RTC_IRQn);
if (RTC->ISR & RTC_ISR_WUTF) {
RTC->ISR &= ~RTC_ISR_WUTF; // clear wakeup interrupt flag RTC->ISR &= ~RTC_ISR_WUTF; // clear wakeup interrupt flag
Handle_EXTI_Irq(EXTI_RTC_WAKEUP); // clear EXTI flag and execute optional callback 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); IRQ_EXIT(RTC_IRQn);
} }
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment