while(1)
{
if(flag == 1)
{
ES = 0;
for(i = 0;i < 6;i++)
{
SBUF = table[i];
while(!TI);
TI = 0;
}
SBUF = a;
while(!TI);
TI = 0;
ES = 1;
flag = 0;
}
}
}
/*----------------------------
UART interrupt service routine
----------------------------*/
void Uart_Isr() interrupt 4 using 1
{
RI = 0;
a = SBUF;
flag = 1;
}