OSDN Git Service

Added env script.
[kozos-expbrd/kozos_expbrd.git] / firm / bootload / main.c
1 #include "init.h"
2 #include "test.h"
3 #include "boot.h"
4 #include "interrupt.h"
5 #include "portconf.h"
6 #include "lib.h"
7
8 int main(void)
9 {
10   INTR_DISABLE; /* ³ä¹þ¤ß̵¸ú¤Ë¤¹¤ë */
11
12   init_system();
13   init_components();
14   test_execute();
15
16   if (PORTCONF_SDC_DETECT()) {
17       puts("Boot : SDC detected.\n");
18       puts("Boot : Booting from SDC.\n");
19       boot_from_sdc("kozos");
20       puts("Boot : Boot from SDC failed.\n");
21       puts("Boot : Going to serial boot mode.\n");
22       boot_from_ser();
23   } else {
24       puts("Boot : SDC not found.\n");
25       puts("Boot : Going to serial boot mode.\n");
26       boot_from_ser();
27   }
28
29   for (;;) { }
30
31   return 0;
32 }
33