然后Rebuild,下载代码到板子上
int main()
{
SYS_UnlockReg();
SYS_Init();
UART0_Init();
printf("\n");
printf("+------------------------------------------------------------------+\n");
printf("| Simple Blinky Demo |\n");
printf("+------------------------------------------------------------------+\n");
/* Init GPIO for LED toggle */
LED_INIT();
LED_YELLOW = 1;
LED_RED = 0;
while(1)
{
LED_YELLOW ^= 1;
LED_RED ^= 1;
CLK_SysTickLongDelay(200000);
LED_YELLOW ^= 1;
LED_RED ^= 1;
CLK_SysTickLongDelay(200000);
}
}
|