diff --git a/targets/TARGET_STM/rtc_api.c b/targets/TARGET_STM/rtc_api.c index c9e9341cf8..e592531fd2 100644 --- a/targets/TARGET_STM/rtc_api.c +++ b/targets/TARGET_STM/rtc_api.c @@ -295,13 +295,10 @@ int rtc_isenabled(void) static void RTC_IRQHandler(void) { + /* Update HAL state */ HAL_RTCEx_WakeUpTimerIRQHandler(&RtcHandle); -} - -void HAL_RTCEx_WakeUpTimerEventCallback(RTC_HandleTypeDef *hrtc) -{ + /* In case of registered handler, call it. */ if (irq_handler) { - // Fire the user callback irq_handler(); } }