switch (i) //判断键值(那一个键按下)
{
case 0xe7: if (count<6) { mbuf[count]=1; count++;SBUF=65;while(!TI);TI=0;}break;
case 0xd7: if (count<6) { mbuf[count]=2; count++;SBUF=66;while(!TI);TI=0;}break;
case 0xb7: if (count<6) { mbuf[count]=3; count++;SBUF=67;while(!TI);TI=0;}break;
case 0x77: if (count<6) { mbuf[count]=4; count++;SBUF=68;while(!TI);TI=0;}break;
case 0xeb: if (count<6) { mbuf[count]=5; count++;SBUF=69;while(!TI);TI=0;}break;
case 0xdb: if (count<6) { mbuf[count]=6; count++;SBUF=70;while(!TI);TI=0;}break;
case 0xbb: if (count<6) { mbuf[count]=7; count++;SBUF=71;while(!TI);TI=0;}break;
case 0x7b: if (count<6) { mbuf[count]=8; count++;SBUF=72;while(!TI);TI=0;}break;
case 0xed: if (count<6) { mbuf[count]=9; count++;SBUF=73;while(!TI);TI=0;}break;
case 0xdd: if (count<6) { mbuf[count]=10;count++;SBUF=74;while(!TI);TI=0;}break;
case 0xbd: if (count==6) { pwflag = pwcmp();} else pwflag = 0;
if(pwflag) {P3=0Xaa;} else {P3=0X00;}break;
case 0x7d: if (count<=6) {count=0;}break;