[riot-notifications] [RIOT-OS/RIOT] cpu/sam0_common: RTC: ensure RTC alarm alignment for SAM D2x (#16078)

MrKevinWeiss notifications at github.com
Mon Jun 28 14:59:43 CEST 2021


<details><summary> tested on the samr21-xpro </summary>

```
BOARD=samr21-xpro make test -C tests/periph_rtc
make: Entering directory '/home/weiss/wd/RIOT/tests/periph_rtc'
r
/home/weiss/wd/RIOT/dist/tools/pyterm/pyterm -p "/dev/ttyACM0" -b "115200" --no-reconnect --noprefix --no-repeat-command-on-empty-line 
Twisted not available, please install it if you want to use pyterm's JSON capabilities
Connect to serial port /dev/ttyACM0
Welcome to pyterm!
Type '/exit' to exit.
READY
s
START
main(): This is RIOT! (Version: 2021.04-devel-728-g386e4e-cpu/sam0_common-rtc_alarm_alignment)

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:00

Alarm!
Alarm!
Alarm!
Alarm!
```
</details>


<details><summary> saml10 </summary>

```
BOARD=saml10-xpro make flash test -C tests/periph_rtc
make: Entering directory '/home/weiss/wd/RIOT/tests/periph_rtc'
Building application "tests_periph_rtc" for "saml10-xpro" with MCU "saml1x".

"make" -C /home/weiss/wd/RIOT/boards/saml10-xpro
"make" -C /home/weiss/wd/RIOT/boards/common/saml1x
"make" -C /home/weiss/wd/RIOT/core
"make" -C /home/weiss/wd/RIOT/cpu/saml1x
"make" -C /home/weiss/wd/RIOT/cpu/cortexm_common
"make" -C /home/weiss/wd/RIOT/cpu/cortexm_common/periph
"make" -C /home/weiss/wd/RIOT/cpu/sam0_common
"make" -C /home/weiss/wd/RIOT/cpu/sam0_common/periph
"make" -C /home/weiss/wd/RIOT/cpu/saml1x/periph
"make" -C /home/weiss/wd/RIOT/drivers
"make" -C /home/weiss/wd/RIOT/drivers/periph_common
"make" -C /home/weiss/wd/RIOT/sys
"make" -C /home/weiss/wd/RIOT/sys/auto_init
"make" -C /home/weiss/wd/RIOT/sys/div
"make" -C /home/weiss/wd/RIOT/sys/isrpipe
"make" -C /home/weiss/wd/RIOT/sys/malloc_thread_safe
"make" -C /home/weiss/wd/RIOT/sys/newlib_syscalls_default
"make" -C /home/weiss/wd/RIOT/sys/pm_layered
"make" -C /home/weiss/wd/RIOT/sys/stdio_uart
"make" -C /home/weiss/wd/RIOT/sys/test_utils/interactive_sync
"make" -C /home/weiss/wd/RIOT/sys/tsrb
"make" -C /home/weiss/wd/RIOT/sys/xtimer
   text	   data	    bss	    dec	    hex	filename
  15476	    136	   2416	  18028	   466c	/home/weiss/wd/RIOT/tests/periph_rtc/bin/saml10-xpro/tests_periph_rtc.elf
[INFO] edbg binary not found - building it from source now
CC= CFLAGS= make -C /home/weiss/wd/RIOT/dist/tools/edbg
[INFO] updating edbg /home/weiss/wd/RIOT/dist/tools/edbg/bin/.pkg-state.git-downloaded
echo 99d15460fcff723f73b16c29c8ca14bff4b33b20 > /home/weiss/wd/RIOT/dist/tools/edbg/bin/.pkg-state.git-downloaded
[INFO] patch edbg
[INFO] edbg binary successfully built!
/home/weiss/wd/RIOT/dist/tools/edbg/edbg.sh flash /home/weiss/wd/RIOT/tests/periph_rtc/bin/saml10-xpro/tests_periph_rtc.bin
### Flashing Target ###
Debugger: ATMEL EDBG CMSIS-DAP ATML2769041800000967 03.25.01B6 (S)
Clock frequency: 16.0 MHz
Target: SAM L10E16A (Rev B)
Verification...
at address 0x48 expected 0x11, read 0x91
Error: verification failed
Debugger: ATMEL EDBG CMSIS-DAP ATML2769041800000967 03.25.01B6 (S)
Clock frequency: 16.0 MHz
Target: SAM L10E16A (Rev B)
Programming................................................................ done.
Verification................................................................ done.
Done flashing
r
/home/weiss/wd/RIOT/dist/tools/pyterm/pyterm -p "/dev/ttyACM0" -b "115200" --no-reconnect --noprefix --no-repeat-command-on-empty-line 
Twisted not available, please install it if you want to use pyterm's JSON capabilities
Connect to serial port /dev/ttyACM0
Welcome to pyterm!
Type '/exit' to exit.
READY
s
START
main(): This is RIOT! (Version: 2021.04-devel-728-g386e4e-cpu/sam0_common-rtc_alarm_alignment)

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

Alarm!
Alarm!
Alarm!
Alarm!
make: Leaving directory '/home/weiss/wd/RIOT/tests/periph_rtc'
```

What else is needed?


-- 
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/RIOT-OS/RIOT/pull/16078#issuecomment-869662303
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.riot-os.org/pipermail/notifications/attachments/20210628/0bbdfdf9/attachment.htm>


More information about the notifications mailing list