Skip to content
Snippets Groups Projects
Commit f2466fb8 authored by Vincent Dupont's avatar Vincent Dupont
Browse files

periph/rtc: move init from auto_init to periph_init

parent 87b0477b
No related branches found
No related tags found
No related merge requests found
...@@ -23,6 +23,9 @@ ...@@ -23,6 +23,9 @@
#ifdef MODULE_PERIPH_SPI #ifdef MODULE_PERIPH_SPI
#include "periph/spi.h" #include "periph/spi.h"
#endif #endif
#ifdef MODULE_PERIPH_RTC
#include "periph/rtc.h"
#endif
void periph_init(void) void periph_init(void)
{ {
...@@ -32,4 +35,9 @@ void periph_init(void) ...@@ -32,4 +35,9 @@ void periph_init(void)
spi_init(SPI_DEV(i)); spi_init(SPI_DEV(i));
} }
#endif #endif
/* Initialize RTC */
#ifdef MODULE_PERIPH_RTC
rtc_init();
#endif
} }
...@@ -32,10 +32,6 @@ ...@@ -32,10 +32,6 @@
#include "xtimer.h" #include "xtimer.h"
#endif #endif
#ifdef MODULE_RTC
#include "periph/rtc.h"
#endif
#ifdef MODULE_GNRC_SIXLOWPAN #ifdef MODULE_GNRC_SIXLOWPAN
#include "net/gnrc/sixlowpan.h" #include "net/gnrc/sixlowpan.h"
#endif #endif
...@@ -105,10 +101,6 @@ void auto_init(void) ...@@ -105,10 +101,6 @@ void auto_init(void)
DEBUG("Auto init xtimer module.\n"); DEBUG("Auto init xtimer module.\n");
xtimer_init(); xtimer_init();
#endif #endif
#ifdef MODULE_RTC
DEBUG("Auto init rtc module.\n");
rtc_init();
#endif
#ifdef MODULE_SHT11 #ifdef MODULE_SHT11
DEBUG("Auto init SHT11 module.\n"); DEBUG("Auto init SHT11 module.\n");
sht11_init(); sht11_init();
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment