[riot-notifications] [RIOT-OS/RIOT] cpu+board: Add support for NXP Kinetis KW41Z and FRDM-KW41Z development board (#6995)

Joakim NohlgÄrd notifications at github.com
Fri Feb 23 09:48:38 CET 2018


gebart commented on this pull request.



> +static inline void set_lpuart_clock_source(void)
+{
+    /* Use MCGIRCLK (internal reference 4 MHz clock) */
+    SIM->SOPT2 = (SIM->SOPT2 & ~SIM_SOPT2_LPUART0SRC_MASK) | SIM_SOPT2_LPUART0SRC(3);
+}
+
+void board_init(void)
+{
+    /* initialize the CPU core */
+    cpu_init();
+
+    set_lpuart_clock_source();
+#if MODULE_XTIMER
+    /* Start the RTT, used as time base for xtimer */
+    rtt_init();
+#endif

It is because this board uses the lptmr hardware timer for xtimer, while the other boards use the PIT hardware timer for xtimer. the LPTMR driver implementation uses RTT for a time base reference. I would like to improve the lptmr driver, but limitations in the hardware in combination with requirements from the xtimer implementation makes it difficult to make a good implementation without a separate time reference right now.
If you like I can change the default config to use PIT like the other kinetis boards

-- 
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/6995#discussion_r170194639
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.riot-os.org/pipermail/notifications/attachments/20180223/2ff82cf7/attachment.html>


More information about the notifications mailing list