diff --git a/boards/stm32l476g-disco/Makefile.features b/boards/stm32l476g-disco/Makefile.features index ebd3cb29fe..624e5dfd01 100644 --- a/boards/stm32l476g-disco/Makefile.features +++ b/boards/stm32l476g-disco/Makefile.features @@ -1,4 +1,6 @@ # Put defined MCU peripherals here (in alphabetical order) +FEATURES_PROVIDED += periph_rtc +FEATURES_PROVIDED += periph_rtt FEATURES_PROVIDED += periph_timer FEATURES_PROVIDED += periph_uart diff --git a/boards/stm32l476g-disco/Makefile.include b/boards/stm32l476g-disco/Makefile.include index 8528a671da..5f98bef0cd 100644 --- a/boards/stm32l476g-disco/Makefile.include +++ b/boards/stm32l476g-disco/Makefile.include @@ -2,6 +2,9 @@ export CPU = stm32l4 export CPU_MODEL = stm32l476vg +# we use shared STM32 configuration snippets +INCLUDES += -I$(RIOTBOARD)/common/stm32/include + # define the default port depending on the host OS PORT_LINUX ?= /dev/ttyACM0 PORT_DARWIN ?= $(firstword $(sort $(wildcard /dev/tty.usbmodem*))) diff --git a/boards/stm32l476g-disco/include/periph_conf.h b/boards/stm32l476g-disco/include/periph_conf.h index 9dcce88960..dfd181b8ea 100644 --- a/boards/stm32l476g-disco/include/periph_conf.h +++ b/boards/stm32l476g-disco/include/periph_conf.h @@ -20,6 +20,7 @@ #define PERIPH_CONF_H #include "periph_cpu.h" +#include "cfg_rtt_default.h" #ifdef __cplusplus extern "C" { @@ -116,17 +117,6 @@ static const uart_conf_t uart_config[] = { #define UART_NUMOF (sizeof(uart_config) / sizeof(uart_config[0])) /** @} */ -/** - * @name RTT configuration - * - * On the STM32Lx platforms, we always utilize the LPTIM1. - * @{ - */ -#define RTT_NUMOF (1) -#define RTT_FREQUENCY (1024U) /* 32768 / 2^n */ -#define RTT_MAX_VALUE (0x0000ffff) /* 16-bit timer */ -/** @} */ - /** * @name RTC configuration * @{