void DelayX1ms (unsigned char count)
{
unsigned char i,j;
for (i=0;i <count;i++)
for(j=0;j <140;j++)
;
}
void main(void)
{
EA=1;
EX0=1;
EX1=1;
while (P1_4)
{
P2=0xbc;
P0=0xfb;
DelayX1ms (10);
//EA=0;
}
while (P1_5)
{
P2=0xbc;
P0=0xf7;
DelayX1ms (10);
//EA=0;
}
while (P1_6)
{
P2=0xbc;
P0=0xfd;
DelayX1ms (10);
}
while (P1_7)
{
P2=0xbc;
P0=0xef;
DelayX1ms (10);
}