用C语言编写程序,要求实现两盏LED灯交替闪烁,间隔时间为2秒?

如题所述

第1个回答  2022-07-12
bit LED1;
bit LED2;
LED1=1;
LED2=0;
while (1)
{ delay(2000);
LED1=!LED1;
LED2=!LED2;
}
相似回答