2010-09-22 15:10:42 +02:00
|
|
|
#include <stdint.h>
|
|
|
|
#include <stdio.h>
|
2010-11-04 14:12:05 +01:00
|
|
|
#include <board_uart0.h>
|
2010-12-13 01:29:46 +01:00
|
|
|
#include <rtc.h>
|
2010-12-14 16:40:47 +01:00
|
|
|
#include <display.h>
|
|
|
|
#include <display_putchar.h>
|
2010-09-22 15:10:42 +02:00
|
|
|
#include <auto_init.h>
|
|
|
|
|
|
|
|
#define ENABLE_DEBUG
|
|
|
|
#include <debug.h>
|
|
|
|
|
|
|
|
extern void main(void);
|
|
|
|
|
|
|
|
void auto_init(void) {
|
2010-12-14 16:40:47 +01:00
|
|
|
#ifdef MODULE_BOARD_DISPLAY
|
|
|
|
lcd_init();
|
|
|
|
DEBUG("DISP OK");
|
|
|
|
#endif
|
|
|
|
#ifdef MODULE_DISPLAY_PUTCHAR
|
|
|
|
init_display_putchar();
|
|
|
|
DEBUG("DISP OK");
|
|
|
|
#endif
|
2010-09-22 15:10:42 +02:00
|
|
|
#ifdef MODULE_HWTIMER
|
|
|
|
DEBUG("Auto init hwtimer module.\n");
|
|
|
|
hwtimer_init();
|
|
|
|
#endif
|
|
|
|
#ifdef MODULE_SWTIMER
|
|
|
|
DEBUG("Auto init swtimer module.\n");
|
|
|
|
swtimer_init();
|
|
|
|
#endif
|
2010-11-04 14:12:05 +01:00
|
|
|
#ifdef MODULE_UART0
|
|
|
|
DEBUG("Auto init uart0 module.\n");
|
|
|
|
board_uart0_init();
|
|
|
|
#endif
|
2010-11-04 18:16:39 +01:00
|
|
|
#ifdef MODULE_RTC
|
|
|
|
DEBUG("Auto init rtc module.\n");
|
|
|
|
rtc_init();
|
|
|
|
rtc_enable();
|
|
|
|
#endif
|
2010-09-22 15:10:42 +02:00
|
|
|
#ifdef MODULE_SHT11
|
|
|
|
DEBUG("Auto init SHT11 module.\n");
|
|
|
|
sht11_init();
|
|
|
|
#endif
|
|
|
|
#ifdef MODULE_GPIOINT
|
|
|
|
DEBUG("Auto init gpioint module.\n");
|
|
|
|
gpioint_init();
|
|
|
|
#endif
|
|
|
|
#ifdef MODULE_CC110X
|
|
|
|
DEBUG("Auto init CC1100 module.\n");
|
|
|
|
cc1100_init();
|
|
|
|
#endif
|
|
|
|
#ifdef MODULE_LTC4150
|
|
|
|
DEBUG("Auto init ltc4150 module.\n");
|
|
|
|
ltc4150_init();
|
|
|
|
#endif
|
|
|
|
main();
|
|
|
|
}
|