#include "includes.h"


extern void delay_nms(unsigned int t);
extern void APT32F102_init(void);

//本项目对应的Boot软件版本号，必须要
const volatile char Project_Boot_Support[32] __attribute__ ((section(".textcsky.VinFlash"))) = "***MD203_Bootloader_V04***";

/***************************************************/
//main
/**************************************************/
int main(void) 
{
//	delay_nms(2000);
	APT32F102_init();							//102 initial
	
	Dbg_Println(DBG_BIT_SYS_STATUS,"APP Run Start! 111 %s",Project_Boot_Support);
	Dbg_Println(DBG_BIT_SYS_STATUS,"MCU Start!");

    while(1)
	{
		SYSCON_IWDCNT_Reload(); 				//IWDT Clear

		UART0_TASK();
	
		UART1_TASK();
		
		UART2_TASK();
		
		DIP_ScanTask();

		BLV_EngDetect_Tack();

		BUS485Send_Task();

    }
}


