stm32/rtc: Get rtc.wakeup working on F0 MCUs.

The problem was that the EXTI line for the RTC wakeup event is line 20 on
the F0, so the interrupt was not firing.
This commit is contained in:
Damien George
2018-07-31 17:24:10 +10:00
parent 1e3a7f561f
commit 9dfbb6cc16
3 changed files with 29 additions and 21 deletions

View File

@@ -574,7 +574,7 @@ void TAMP_STAMP_IRQHandler(void) {
void RTC_WKUP_IRQHandler(void) {
IRQ_ENTER(RTC_WKUP_IRQn);
RTC->ISR &= ~(1 << 10); // 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
IRQ_EXIT(RTC_WKUP_IRQn);
}
@@ -583,7 +583,7 @@ void RTC_WKUP_IRQHandler(void) {
void RTC_IRQHandler(void) {
IRQ_ENTER(RTC_IRQn);
RTC->ISR &= ~(1 << 10); // 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
IRQ_EXIT(RTC_IRQn);
}