[riot-notifications] [RIOT-OS/RIOT] cpu/stm32/rtc: add unlock/lock to rtc_clear_alarm (#15796)

Francisco notifications at github.com
Tue Jan 19 13:36:46 CET 2021

### Contribution description

#15628 (because a `rtc_clear_alarm` call was added to the test) exposed a bug on `stm32/rtc` where the RTC was not `locked`/`unlocked` when calling `rtc_clear_alarm`. This caused `tests/periph_rtc` to hang at least on `nucleo-f207zg`.

### Testing procedure

`BOARD=nucleo-f207zg make -C tests/periph_rtc flash test -j3`

main(): This is RIOT! (Version: 2021.04-devel-66-g7c12e-pr_rtc_lock_unlock)

RIOT RTC low-level driver test
This test will display 'Alarm!' every 2 seconds for 4 times
  Setting clock to   2020-02-28 23:59:57
Clock value is now   2020-02-28 23:59:57
  Setting alarm to   2020-02-28 23:59:59
   Alarm is set to   2020-02-28 23:59:59
  Alarm cleared at   2020-02-28 23:59:57
       No alarm at   2020-02-28 23:59:59
  Setting alarm to   2020-02-29 00:00:01


You can view, comment on, or merge this pull request online at:


-- Commit Summary --

  * cpu/stm32/rtc: add unlock/lock to rtc_clear_alarm

-- File Changes --

    M cpu/stm32/periph/rtc_all.c (8)

-- Patch Links --


You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.riot-os.org/pipermail/notifications/attachments/20210119/713eb351/attachment.htm>

More information about the notifications mailing list