일부러 flag를 써가면서 * 을 왕복 시킬 필요가 없이 switch문을 이용하면
좀 더 깔끔하게 처리가 되네.
for (;;)
{
switch(i)
{
case 0: PC_DispStr(0, 1, "* ", DISP_FGND_YELLOW+DISP_BGND_BLACK), i=1; break;
case 1: PC_DispStr(0, 1, " * ", DISP_FGND_YELLOW+DISP_BGND_BLACK), i=2; break;
case 2: PC_DispStr(0, 1, " * ", DISP_FGND_YELLOW+DISP_BGND_BLACK), i=3; break;
case 3: PC_DispStr(0, 1, " * ", DISP_FGND_YELLOW+DISP_BGND_BLACK), i=4; break;
case 4: PC_DispStr(0, 1, " * ", DISP_FGND_YELLOW+DISP_BGND_BLACK), i=5; break;
case 5: PC_DispStr(0, 1, " * ", DISP_FGND_YELLOW+DISP_BGND_BLACK), i=0; break;
delay(10);
}
}