欧美极品高清xxxxhd,国产日产欧美最新,无码AV国产东京热AV无码,国产精品人与动性XXX,国产传媒亚洲综合一区二区,四库影院永久国产精品,毛片免费免费高清视频,福利所导航夜趣136
標題:
新手第一個自編單片機程序,正反流水燈
[打印本頁]
作者:
mediocre
時間:
2019-2-8 10:35
標題:
新手第一個自編單片機程序,正反流水燈
#include <reg52.h>
unsigned int i;
void Delay(unsigned int t);
void Delay(unsigned int t)
{
while(t--);
}
/*先正后反流水燈*/
void main()
{
while(1)
{
i=1;
while(i<129)
{
P1=~i;
Delay(60000);
i=i*2;
}
while(i>=2)
{
i=i/2;
P1=~i;
Delay(60000);
}
}
}
/* 反向流水燈
void main()
{
while(1)
{
i=128;
while(i>=1)
{
P1=~i;
Delay(60000);
i=i/2;
}
}
}
*/
用了3天時間才搞成,不過還是有點高興
歡迎光臨 (http://m.raoushi.com/bbs/)
Powered by Discuz! X3.1