为什么这个if语句既执行if后面的函数体又执行else后面的函数体
while ( 1 ){
status = PcdRequest(PICC_REQALL, g_ucTempbuf);//寻卡
if (status != MI_OK)
{ LED_2 =1;
delay(2000);
LED_2 =0;
delay(2000);
LED_2=1;
delay(2000);
continue; }
else
//display_type();//寻到卡后显示出该卡的类型
LED_1 =0;
delay(2000);
LED_1 =1;
delay(2000);
LED_1=0;
delay(2000);
//printf("卡的类型:");
for(i=0;i<2;i++)
{
temp=g_ucTempbuf[i];
printf("%X",temp);
}
status = PcdAnticoll(g_ucTempbuf);//防冲撞
if (status != MI_OK)
{ continue; }
else
display_cardnum();//显示寻到的卡的序列号
}
}