mirror of
https://github.com/RIOT-OS/RIOT.git
synced 2025-01-18 12:52:44 +01:00
Merge pull request #8543 from OTAkeys/pr/rtt_clean_up
periph_rtt: remove RTT_NUMOF guard and init from periph_common
This commit is contained in:
commit
071614bf04
@ -29,9 +29,6 @@
|
||||
extern "C" {
|
||||
#endif
|
||||
|
||||
/* guard file in case no RTT device was specified */
|
||||
#if RTT_NUMOF
|
||||
|
||||
#ifndef RTT_FREQUENCY
|
||||
#warning "RTT_FREQUENCY undefined. Set RTT_FREQUENCY to the number of ticks" \
|
||||
"per second for the current architecture."
|
||||
@ -166,8 +163,6 @@ void rtt_poweron(void);
|
||||
*/
|
||||
void rtt_poweroff(void);
|
||||
|
||||
#endif /* RTT_NUMOF */
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif
|
||||
|
@ -26,6 +26,9 @@
|
||||
#ifdef MODULE_PERIPH_RTC
|
||||
#include "periph/rtc.h"
|
||||
#endif
|
||||
#ifdef MODULE_PERIPH_RTT
|
||||
#include "periph/rtt.h"
|
||||
#endif
|
||||
#ifdef MODULE_PERIPH_HWRNG
|
||||
#include "periph/hwrng.h"
|
||||
#endif
|
||||
@ -44,6 +47,11 @@ void periph_init(void)
|
||||
rtc_init();
|
||||
#endif
|
||||
|
||||
/* Initialize RTT */
|
||||
#ifdef MODULE_PERIPH_RTT
|
||||
rtt_init();
|
||||
#endif
|
||||
|
||||
#ifdef MODULE_PERIPH_HWRNG
|
||||
hwrng_init();
|
||||
#endif
|
||||
|
Loading…
Reference in New Issue
Block a user