int main(void)
{
u8 key;
delay_init(168);
LED_Init();
BEEP_Init();
KEY_Init();
LED0=0;
while(1)
{
key=KEY_Scan(0);
if(key)
{
switch(key)
{
case WK_UP_PRES:
BEEP=!BEEP; 在这儿总是显示expected expression是什么意思
break;
case KEY0_PRES:
LED0=!LED0;
break;
case KEY1_PRES:
LED1=!LED0;
break;
case KEY2_PRES:
LED1=!LED1;
LED0=!LED0;
break;
}
}else delay_ms(10);
}
} |