diff --git a/targets/TARGET_Maxim/TARGET_MAX32600/rtc_api.c b/targets/TARGET_Maxim/TARGET_MAX32600/rtc_api.c index 67bd74ce3c..18121d1ba1 100644 --- a/targets/TARGET_Maxim/TARGET_MAX32600/rtc_api.c +++ b/targets/TARGET_Maxim/TARGET_MAX32600/rtc_api.c @@ -33,6 +33,7 @@ #include "rtc_api.h" #include "lp_ticker_api.h" +#include "ticker_api.h" #include "cmsis.h" #include "rtc_regs.h" #include "pwrseq_regs.h" @@ -73,8 +74,10 @@ void rtc_init(void) MXC_PWRSEQ->reg0 |= MXC_F_PWRSEQ_REG0_PWR_RTCEN_RUN; // Prepare interrupt handlers +#ifdef DEVICE_LPTICKER NVIC_SetVector(RTC0_IRQn, (uint32_t)lp_ticker_irq_handler); NVIC_EnableIRQ(RTC0_IRQn); +#endif NVIC_SetVector(RTC3_IRQn, (uint32_t)overflow_handler); NVIC_EnableIRQ(RTC3_IRQn);