新聞中心

EEPW首頁(yè) > 嵌入式系統(tǒng) > 設(shè)計(jì)應(yīng)用 > 三種型號(hào)單片機(jī)點(diǎn)亮一只發(fā)光二極管程序

三種型號(hào)單片機(jī)點(diǎn)亮一只發(fā)光二極管程序

作者: 時(shí)間:2016-11-29 來(lái)源:網(wǎng)絡(luò) 收藏
/***************STC89C52RC*************/

#include
sbit LED=P1^0;
void main()
{
LED=0;
while(1);
}

本文引用地址:http://butianyuan.cn/article/201611/323431.htm

/*******ATMEGA16A****************/
#include
#include
void main()
{
DDRA=0X01;
PORTA&=BIT(PORTA7);
while(1);
}

/*******PIC16F877**********************/
#include
#define uint unsigned int
#define uchar unsigned char
__CONFIG(0X3B31);
void main()
{
TRISA0=0;
RA0=0;
while(1);
}



關(guān)鍵詞: 單片機(jī)發(fā)光二極

評(píng)論


技術(shù)專(zhuān)區(qū)

關(guān)閉