在线看毛片网站电影-亚洲国产欧美日韩精品一区二区三区,国产欧美乱夫不卡无乱码,国产精品欧美久久久天天影视,精品一区二区三区视频在线观看,亚洲国产精品人成乱码天天看,日韩久久久一区,91精品国产91免费

<menu id="6qfwx"><li id="6qfwx"></li></menu>
    1. <menu id="6qfwx"><dl id="6qfwx"></dl></menu>

      <label id="6qfwx"><ol id="6qfwx"></ol></label><menu id="6qfwx"></menu><object id="6qfwx"><strike id="6qfwx"><noscript id="6qfwx"></noscript></strike></object>
        1. <center id="6qfwx"><dl id="6qfwx"></dl></center>

            新聞中心

            EEPW首頁 > 嵌入式系統(tǒng) > 設(shè)計應(yīng)用 > 單片機制作超級流水燈

            單片機制作超級流水燈

            作者: 時間:2016-11-23 來源:網(wǎng)絡(luò) 收藏


            實驗源程序:

            本文引用地址:http://www.biyoush.com/article/201611/320570.htm

            #include
            #include
            unsigned int a,b;
            unsigned char d;
            sbit LED1 = P1^0;
            sbit LED2 = P1^1;
            sbit LED3 = P1^2;
            sbit LED4 = P1^3;
            sbit LED5 = P1^4;
            sbit LED6 = P1^5;
            sbit LED7 = P1^6;
            sbit LED8 = P1^7;
            sbit LED9 = P2^0;
            sbit LED10 = P2^1;
            sbit LED11 = P2^2;
            sbit LED12 = P2^3;
            sbit LED13 = P2^4;
            sbit LED14 = P2^5;
            sbit LED15 = P2^6;
            sbit LED16 = P2^7;
            sbit LED17 = P3^0;
            sbit LED18 = P3^1;
            sbit LED19 = P3^2;
            sbit LED20 = P3^3;
            sbit LED21 = P3^4;
            sbit LED22 = P3^5;
            sbit LED23 = P3^6;
            sbit LED24 = P3^7;

            void Delay()
            {
            for(a=100;a>0;a--)
            for(b=100;b>0;b--);
            }

            void main()
            {
            while(1)
            {
            P1 = 0;
            P2 = 0;
            P3 = 0;
            LED1 = 1;
            Delay();
            LED1 = 0;
            LED2 = 1;
            Delay();
            LED2 = 0;
            LED3 = 1;
            Delay();
            LED3 = 0;
            LED4 = 1;
            Delay();
            LED4 = 0;
            LED5 = 1;
            Delay();
            LED5 = 0;
            LED6 = 1;
            Delay();
            LED6 = 0;
            LED7 = 1;
            Delay();
            LED7 = 0;
            LED8 = 1;
            Delay();

            LED8 = 0;
            LED9 = 1;
            Delay();
            LED9 = 0;
            LED10 = 1;
            Delay();
            LED10 = 0;
            LED11 = 1;
            Delay();
            LED11 = 0;
            LED12= 1;
            Delay();
            LED12 = 0;
            LED13= 1;
            Delay();
            LED13= 0;
            LED14= 1;
            Delay();
            LED14= 0;
            LED15= 1;
            Delay();
            LED15 = 0;
            LED16= 1;
            Delay();

            LED16 = 0;
            LED17= 1;
            Delay();
            LED17 = 0;
            LED18 = 1;
            Delay();
            LED18 = 0;
            LED19= 1;
            Delay();
            LED19 = 0;
            LED20= 1;
            Delay();
            LED20= 0;
            LED21= 1;
            Delay();
            LED21= 0;
            LED22= 1;
            Delay();
            LED22 = 0;
            LED23= 1;
            Delay();
            LED23 = 0;
            LED24= 1;
            Delay();
            }
            }



            關(guān)鍵詞: 單片機超級流水

            評論


            技術(shù)專區(qū)

            關(guān)閉