標(biāo)題: 基于AT89S51室內(nèi)溫度檢測程序 [打印本頁]

作者: 010706    時間: 2021-1-16 18:39
標(biāo)題: 基于AT89S51室內(nèi)溫度檢測程序
#include<reg52.h>
#include"lcd.h"
#include"DS18B20.h"
#define uchar unsigned char
#define uint unsigned int
//uchar data disdata[6];// 百、十、個、小數(shù)位1、小數(shù)位2、        小數(shù)位3、
//uint tvalue; // 溫度值
//uchar tflag; // 溫度正負標(biāo)志


/**************************************************************************************************************/
/******************** 主程序 *********************************************************************************/
void main()
{
init_play();  // 調(diào)用 lcd 初始化顯示子函數(shù)
while(1)
{

read_temp(); // 調(diào)用 ds18b20 讀取溫度
ds18b20disp(); // 調(diào)用溫度顯示子函數(shù)
}
}

基于AT89S51室內(nèi)溫度檢測程序.zip

42.13 KB, 下載次數(shù): 13, 下載積分: 黑幣 -5






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