Skip to main content
bruzzim
Associate III
March 10, 2010
Question

RTC alarm versus clock Counter

  • March 10, 2010
  • 6 replies
  • 1346 views
Posted on March 10, 2010 at 17:52

RTC alarm versus clock Counter

    This topic has been closed for replies.

    6 replies

    damh
    Associate III
    May 17, 2011
    Posted on May 17, 2011 at 13:42

    If you only use stopmode, you can use the RTC_SECOND for frequent interrupts and then you doesn't have to update RTC at all.

    If you use standbymode, too, you are forced in this cases to use RTC_ALARM!

    swhite2
    Associate II
    May 17, 2011
    Posted on May 17, 2011 at 13:42

    When you update any RTC register you MUST wait for the operation to complete.

    If you're using ST's standard peripheral library you accomplish this by a call to

    RTC_WaitForLastTask();

    (See the attached image)

    I suspect you're not doing this and one or more writes are being missed.

    ongth602
    Visitor II
    May 17, 2011
    Posted on May 17, 2011 at 13:42

    Hi,

    You can't use RTC second interrupt in stop mode. Pls refer to application note AN2629.

    BR,

    Ong

    bruzzim
    bruzzimAuthor
    Associate III
    May 17, 2011
    Posted on May 17, 2011 at 13:42

    I use stop-mode and I'd really like to use RTC_SECOND but it simply doesn't work: once in stop-mode rtc second interrupts dont't awake the cpu. In fact reading the reference manual (pag. 61 table 11):

    (about exiting from stop mode)

    <<.. If WFI was used for entry: Any EXTI Line configured in Interrupt Mode( the corresponding EXTI Interrupt vector must be enavlled in the NVIC)>>

    I understand that I need to configutre EXTI as Interrupt Event but as far as I know just ALARM has its own EXTI line (line 15) then SECOND INTERRUPT cannot awake from STOP.

    Am I right?

    Kaouther BELHADJ
    ST Employee
    May 17, 2011
    Posted on May 17, 2011 at 13:42

    Only RTC Alarm Event mapped on EXTI Line 17 can wake up the system from Stop mode.  All details for stop mode enrty/ exit are available in RM0008 and you can find some examples in AN2629. teik_hong.ongFriday, May 14, 2010 8:40 AMRTC alarm versus clock Counter

    Hi,

    You can't use RTC second interrupt in stop mode. Pls refer to application note AN2629.

    BR,

    Ong

    filippo2991
    Associate III
    May 17, 2011
    Posted on May 17, 2011 at 13:42

    You would switch to  stm32f low power line as soon as they will be available. I heard that it can be awoke by lse interrupts. 

    BR