下載手機汽配人
M51B-3820030C M51B-3820030C M51B-3820030C

M51B-3820030C問答
只是LCD1602的代碼 ;多功能51單片機開發(fā)板 ;LCD1602測試程序 RS EQU P2.0;R0:每行顯示字符的個數(shù) MOV R1,#80H ;寄存器地址 MOV A,#38H ;
  #include   #include   #defineucharunsignedchar   #defineuintunsignedint   sbitds=P2^2;//溫度傳感器信號線   sbitdula=P2^6;//數(shù)碼管段選線   sbitwela=P2^7;//數(shù)碼管位選線   sbitbeep=P2^3;//蜂鳴器   uinttemp;   floatf_temp;   uintwarn_l1=260;   uintwarn_l2=250;   uintwarn_h1=300;   uintwarn_h2=320;   sbitled0=P1^0;   sbitled1=P1^1;   sbitled2=P1^2;   sbitled3=P1^3;   unsignedcharcodetable[]={   0x3f,0x06,0x5b,0x4f,   0x66,0x6d,0x7d,0x07,   0x7f,0x6f,0xbf,0x86,   0xdb,0xcf,0xe6,0xed,   0xfd,0x87,0xff,0xef};//不帶小數(shù)點的編碼   voiddelay(uintz)//延時函數(shù)   {   uintx,y;   for(x=z;x>0;x--)   for(y=110;y>0;y--);   }   voiddsreset(void)//18B20復位,初始化函數(shù)   {   uinti;   ds=0;   i=103;   while(i>0)i--;   ds=1;   i=4;   while(i>0)i--;   }   bittempreadbit(void)//讀1位函數(shù)   {   uinti;   bitdat;   ds=0;i++;//i++起延時作用   ds=1;i++;i++;   dat=ds;   i=8;while(i>0)i--;   return(dat);   }   uchartempread(void)//讀1個字節(jié)   {   uchari,j,dat;   dat=0;   for(i=1;i<=8;i++)   {   j=tempreadbit();   dat=(j<<7)|(dat>>1);//讀出的數(shù)據(jù)最低位在最前面,這樣剛好一個字節(jié)在DAT里   }   return(d
M51B-3820030C新聞
周邊商家產(chǎn)品推薦
相關(guān)問答
產(chǎn)品精選
優(yōu)勢廠家
圖片大全
推薦主題
汽配人網(wǎng)提供各類型的M51B-3820030C相關(guān)信息,包括了M51B-3820030C產(chǎn)品,價格,廠家,品牌,商城,圖片,配件,汽配城,問答,資訊,維修保養(yǎng),資料下載等信息。您還可以找 C5269113 主題 GR100 主題 612600020620 主題 M51B-3820030B 主題 ISME308 主題 1B24981280055A1626A 主題 6754-41-5210 主題 500338953 主題 等信息。
移動版: M51B-3820030C主題