久久精品天天中文字幕人妻,成人做爰9片免费看网站,清纯校花自慰呻吟流白浆,久久人妻无码毛片A片麻豆

技術支持???Support
聯(lián)系我們???Contact
你的位置:首頁 > 技術支持 > 下載中心

DS18B20測溫程序

2015-5-12 10:49:00??????點擊:

如有疑問聯(lián)系客服,程序下載在低端程序開頭如下:

#include "reg52.h"

#include "intrins.h"
#define uchar unsigned char
#define uint unsigned int
sbit ds=P2^2;
sbit dula=P2^6;
sbit wela=P2^7;
uchar flag ;
uint temp;               //參數temp一定要聲明為 int 型 
uchar code table[]={0x3f,0x06,0x5b,0x4f,0x66,0x6d,0x7d,
0x07,0x7f,0x6f,0x77,0x7c,0x39,0x5e,0x79,0x71};     //不帶小數點數字編碼


uchar code table1[]={0xbf,0x86,0xdb,0xcf,0xe6,0xed,0xfd,
0x87,0xff,0xef};        //帶小數點數字編碼


/*延時函數*/
void TempDelay (uchar us)
{
   while(us--);
}

void delay(uint count) //延時子函數
{
uint i;
while(count)
{
i=200;
while(i>0)
i--;
count--;
}

}

  更多優(yōu)質傳感器來自永陽新能源: PT100 http://www.yyhktv.cn