cancel
Showing results for 
Search instead for 
Did you mean: 

rtc interrupt service routine not woring

vitthal muddapur
Associate II
Posted on February 10, 2018 at 09:59

hi,

ALRAF bit is set in ISR register but doesn,t execute the rtc-irq handler.

i enabled NVIC_RTC.

18 REPLIES 18
straubm
Associate III
Posted on February 10, 2018 at 12:22

What's the configuration? MCU? CubeMX and/or LL-drivers in use ?

Jack Peacock
Associate II
Posted on February 10, 2018 at 15:05

Did you also enable the EXTI line for RTC alarm?

Posted on February 10, 2018 at 16:10

Chronically vague, provide context.

Show code, show detail

Tips, Buy me a coffee, or three.. PayPal Venmo
Up vote any posts that you find helpful, it shows what's working..
henry.dick
Senior II
Posted on February 10, 2018 at 18:38

The bug is obvious: you just need to set the 3rd bit 38th line down on the 2nd page of your 8th function about 2/3 logic high. As now, it is not high enough.

T J
Lead
Posted on February 12, 2018 at 08:43

Which IDE are you using ?

can you check the registers with single step ?

You could read the Reference manual to find all the register descriptions.

your problem would be in there, as a guess.

Posted on February 12, 2018 at 07:53

MCU CONFIGURATION

Posted on February 12, 2018 at 08:07

void RTC_ALRMAR_SET()

{

RTC->WPR = 0xCA;

RTC->WPR = 0x53;

RTC->CR &=~ RTC_CR_ALRAE;

while((RTC->ISR & RTC_ISR_ALRAWF) != RTC_ISR_ALRAWF)

{

}

RTC->ALRMAR = RTC_ALRMAR_MSK4 | RTC_ALRMAR_MSK3 | RTC_ALRMAR_MSK2 | 1<<30(Week day selection mask) | 1<<4(set Second tens in BCD format.);

RTC->CR = RTC_CR_ALRAIE | RTC_CR_ALRAE;

RTC->WPR = 0xFE;

RTC->WPR = 0x64;

}

trying to get interrupt at 10 sec but not working 

Posted on February 12, 2018 at 08:08

void RTC_ALRMAR_SET()

{

RTC->WPR = 0xCA;

RTC->WPR = 0x53;

RTC->CR &=~ RTC_CR_ALRAE;

while((RTC->ISR & RTC_ISR_ALRAWF) != RTC_ISR_ALRAWF)

{

}

RTC->ALRMAR = RTC_ALRMAR_MSK4 | RTC_ALRMAR_MSK3 | RTC_ALRMAR_MSK2 | 1<<30(Week day selection mask) | 1<<4(set

Second tens in BCD format.);

RTC->CR = RTC_CR_ALRAIE | RTC_CR_ALRAE;

RTC->WPR = 0xFE;

RTC->WPR = 0x64;

}

trying to get interrupt at 10 sec but not working

Posted on February 12, 2018 at 08:29

no