From a47fb723e468368808f44e48712552c52519a31a Mon Sep 17 00:00:00 2001 From: Atis Elsts Date: Mon, 25 Apr 2016 18:02:26 +0300 Subject: [PATCH] cc26xx: enable sync between radio timer and RTC, useful for TSCH --- cpu/cc26xx-cc13xx/clock.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/cpu/cc26xx-cc13xx/clock.c b/cpu/cc26xx-cc13xx/clock.c index 4f6df056f..85ea6e444 100644 --- a/cpu/cc26xx-cc13xx/clock.c +++ b/cpu/cc26xx-cc13xx/clock.c @@ -118,6 +118,9 @@ clock_init(void) /* GPT0 / Timer B: One shot, PWM interrupt enable */ HWREG(GPT0_BASE + GPT_O_TBMR) = ((TIMER_CFG_B_ONE_SHOT >> 8) & 0xFF) | GPT_TBMR_TBPWMIE; + + /* enable sync with radio timer */ + HWREGBITW(AON_RTC_BASE + AON_RTC_O_CTL, AON_RTC_CTL_RTC_UPD_EN_BITN) = 1; } /*---------------------------------------------------------------------------*/ static void