標題: 點亮一個led閃光燈 [打印本頁]

作者: 251314    時間: 2017-7-5 09:17
標題: 點亮一個led閃光燈
#include<stc12c5a60s2.h>

sbit D1=P1^0;                 //定義第一個LED的端口P1^0為D1

void main()                     //主函數(shù)
{
        while(1)
        {
                 D1=0;                 //電亮第一個LED
        }
}






歡迎光臨 (http://www.torrancerestoration.com/bbs/) Powered by Discuz! X3.1