//標頭檔

#include "reg51.h" 

#define LED P1

LEDdelay();

int i,j;


//主程式

main()

{

  LED=0x18; 

 

  LEDdelay();


  LED=0xe7;


  LEDdelay();

}

//函數檔

LEDdelay() // 1sec

{

for(i=0;i<10200;i++)

{

for(j=0;j<10;j++);

}

}

文章標籤
全站熱搜
創作者介紹
創作者 42Hu 收入創造家 的頭像
42Hu 收入創造家

《 42hu 被動收入創造家 》

42Hu 收入創造家 發表在 痞客邦 留言(0) 人氣(11)