Example #1
0
File: system.c Project: miaofng/ulp
void sys_Init(void)
{
    SystemInit();
#if CONFIG_DRIVER_WDT == 1
    wdt_init(CONFIG_WDT_PERIOD);
#endif
    time_Init();
#if CONFIG_DRIVER_LED == 1
    led_Init();
#endif
    bsp_init();
#if (CONFIG_IAR_REDIRECT == 1) || (CONFIG_TASK_SHELL == 1)
    console_Init();
#endif
#if (CONFIG_FLASH_NVM == 1)
    nvm_init();
#endif
}
Example #2
0
void main(void)
{
	//P1=0xFF;
	//P2=0xFF;
	//P3=0xFF;

    // Inits watch set to clock mode by default
    watch_Init(clock_state);  
		time_Init();
		//prepare for elapsed time measurement
	Elapsed_Time_Init();



   // Set up simple EOS (10 ms ticks)
   sEOS_Init_Timer2(10);
	 	
   
   while(1) // Super Loop
   {
      // Enter idle mode to save power
      sEOS_Go_To_Sleep();  
   }
}