【正文】
....................................................................... 5 設(shè)計(jì)要求 ....................................................................................................... 5 系統(tǒng)基本方案選擇和論證 ........................................................................... 5 單片機(jī)芯片的選擇 方案和論證 ........................................................ 5 溫度傳感器設(shè)計(jì)方案論證 ................................................................ 6 掉電保持方案論證 ............................................................................ 6 電路設(shè)計(jì)最終方案決定 .............................................................................. 7 第二章 主要元件介紹 ................................................................................... 7 STC89C51 介紹 ............................................................................................ 7 STC89C51 主要功能及 PDIP 封裝 .................................................... 7 STC89C51 引腳介紹 .......................................................................... 8 單片機(jī)最小系統(tǒng): ............................................................................ 9 DS18B20 傳感器介紹 ................................................................................. 10 DS18B20 概述 ................................................................................... 10 DS18B20 引腳介紹 ........................................................................... 11 DS18B20 的內(nèi)部結(jié)構(gòu) ....................................................................... 11 DS18B20 的程序流程圖 ................................................................... 12 數(shù)碼管介紹 ................................................................................................ 13 數(shù)碼管概述 ...................................................................................... 14 AT24C02 簡介 ............................................................................................. 14 I2C 總線說明 .................................................................................... 15 第三章 程序流程圖 ..................................................................................... 18 結(jié)論 ................................................................................................................... 19 共 頁 第 頁 參考文獻(xiàn) ........................................................................................................... 20 致 謝 ................................................................................................................. 21 附錄 A 電路原理圖 ....................................................................................... 22 附錄 B C 語言程序 ....................................................................................... 23 共 頁 第 頁 第一章 設(shè)計(jì)要求與方案論證 設(shè)計(jì)要求 基本范圍 0℃ 99℃ ; 精度誤差小于 ℃ ; 數(shù)碼 管 直讀顯示 ; 擴(kuò)展功能 : 可以任意設(shè)定溫度的上下限報(bào)警功能 ,并可以掉電保持上下限溫度值。 The main room is in air conditioning equipment such as puter, electricity work long hours, cause of old equipment, air conditioning fault, and can39。 Electrostatic generation high temperature or or fire。 關(guān)鍵詞 :STC89C51 單片機(jī),數(shù)字控制,溫度計(jì) , DS18B20, AT24C02 共 頁 第 頁 ABSTRACT Single chip technology has spread to we live, work, scientific research, each domain, has bee a mature technology, this paper introduces a kind of based on single chip microputer control digital temperature device, the thermometer belongs to the multifunction thermometer, can set up and down the temperature alarm, when the temperature is not set range, you can call the police. With modern industrial and agricultural technology and the development of people to the improvement of the living environment requirements, and people urgently need to test and control the temperature. Through the use of ponents of the buzzer as acoustic temperature alarm design, it is expounded that the device for the design and production of the specific processes and methods. The temperature alarm simple structure, the maneuverability is strong, wide application. Work, temperature measurement range for 538 186。 當(dāng)前環(huán)境溫度若超過設(shè)定的高溫臨界溫度,由單 片機(jī)發(fā)出報(bào)警信號(hào), 從而防止帶來的不必要的損失。工作時(shí),溫度測(cè)量范圍為 5— 38186。 本文通過采用 蜂鳴器作為電聲元件 的溫度報(bào)警器的設(shè)計(jì),闡明了該裝置進(jìn)行設(shè)計(jì)與制作的具體過程及方法。 共 頁 第 頁 摘要 單片機(jī)技術(shù)已經(jīng)普及到我們生活,工作,科研,各個(gè)領(lǐng)域,已經(jīng)成為一種比較成熟的技術(shù) ,本文將介紹一種基于單片機(jī)控制的 數(shù)字溫度器 ,本溫度計(jì)屬于多功能溫度計(jì),可以設(shè)置上下報(bào)警溫度,當(dāng)溫度不在設(shè)置范圍內(nèi)時(shí),可以報(bào)警。 隨著現(xiàn)代工農(nóng)業(yè)技術(shù)的發(fā)展及人們對(duì)生活環(huán)境要求的提高,人們也迫切需要檢測(cè)與控制溫度。這種溫度報(bào)警器結(jié)構(gòu)簡單,可操作性強(qiáng),應(yīng)用廣泛。C。 造成高溫火災(zāi)有:電氣線路短路、過載、接觸電阻過大等引發(fā)高溫或火災(zāi);靜電產(chǎn)生高溫或或火災(zāi);雷電等強(qiáng)電侵入導(dǎo)致高溫或火災(zāi);最主要是機(jī)房內(nèi)電腦、空調(diào)等用電設(shè)備長時(shí)間工作,導(dǎo)致設(shè)備老化,空調(diào)發(fā)生故障,而不能降溫;因此機(jī)房內(nèi)所屬的電子產(chǎn)品發(fā)熱快,在短時(shí)間內(nèi)機(jī)房溫度升高超出設(shè)備正常溫度,導(dǎo)致系統(tǒng)癱瘓或產(chǎn)生火災(zāi),這時(shí)溫度報(bào)警系統(tǒng)就會(huì)發(fā)揮應(yīng)有的功能。 C. The current environment temperature if more than the high temperature of setting the critical temperature, issued a warning signal by singlechip microputer, thus preventing bring unnecessary losses. High temperature caused by fire are: electric short circuit, overload, contact resistance by too high temperature or fire。 Lightning and lead to high temperatures or high voltage into the fire。t cooling。 系統(tǒng)基本方案選擇和論證 單片機(jī)芯片的選擇方案和論證 由于單片機(jī)具有以下的很多優(yōu)點(diǎn),被我們選定為制作該作品的首選芯片 單片機(jī)特點(diǎn): ( 1) 高集成度,體積小,高可靠性 單片機(jī)將各功能部件集成在一塊晶體芯片 上,集成度很高,體積自然也是最小的。單片機(jī)程序指令,常數(shù)及表格等固化在 ROM 中不易破壞,許多信號(hào)通道均在一個(gè)芯片內(nèi),故可靠性高。 ( 3)低電壓,低功耗,便于生產(chǎn)便攜式產(chǎn)品 為了滿足廣泛使用于便攜式系統(tǒng),許多單片機(jī)內(nèi)的 最低 工作電壓僅為 ~ ,而工作電流僅 為數(shù)百微安。芯片外部有許多供擴(kuò)展用的三總線及并行、串行輸入 /輸出管腳,很容易構(gòu)成各種規(guī)模的計(jì)算機(jī)應(yīng)用系統(tǒng)。為了提高速度和運(yùn)行效率,單片機(jī)已開始使用 RISC 流水線和 DSP等技術(shù)。由于單片機(jī)的廣泛使用,因而銷量極大,各大公司的商業(yè)競(jìng)爭更使其價(jià)格十分低廉,其性能價(jià)格比極高。 STC89C51 內(nèi)部具有 8KB ROM 存儲(chǔ)空間 ,512