串口调试助手怎么向单片机发数据



void main()
{
while(1)
{
if(flag==1)
{
switch(a)
{
case 1: 执行语句1; break;
.................
case 8:执行语句8; break;
break:执行默认语句;break;
}
........
}
}
}
void ser() interrupt 4
{
RI=0;
a=SBUF;
flag=1;
}


Copyright © 2009-2011 All Rights Reserved.