【正文】
摘 要 本設計主要包括 溫度 傳感器 DS18B單片機 AT89S51 和 LCD1602 等器件,硬件電路包括 溫度檢測電路、溫度控制電路和一些接口電路等 輔助電路, 軟件設計主要包括 數碼管顯示程序、鍵盤掃描及按鍵處理程序、溫度信號處理程序、繼電器控制程序、 超溫 報警程序 五 個模塊。設計電路工作原理為: 首先,由 DS18B20 溫度傳感器芯片測量當前的溫度,并將結果送入單片機。然后,通過 AT89S51 單片機芯片對送來的測量溫度讀數進行計算和轉換,井將此結果送入液晶顯示模塊 ,如果測量溫度超過預定值,單片機同時也會把信號傳 遞給報警電路單元 。最后, LCD1602A 芯片將送來的值顯示于顯示屏上 。 關鍵詞: AT89S51 單片機; 溫度傳感器; DS18B20; LCD1602 ABSTRACT The design includes temperature sensor DS18B20, MCU AT89S51, LCD1602 and other devices. Hardware circuit includes the temperature sensing circuit, the temperature control circuit , a number of interface circuits and other auxiliary circuits, Software design process includes five modules, such as digital tube display, keyboard scanning and key processes, the temperature signal processing, relay control procedures, overtemperature alarm program. The circuit design works as follows: First, by measuring current DS18B20 Temperature sensor chip temperatures, and the results into the single chip. Then sending the microcontroller chip on the measurement of temperature readings to calculate and convert the result well into this LCD module through the AT89S51, if the measured temperature exceeds a predetermined value, the microcontroller will also send signals to the alarm circuit module. Finally, SMC1602A sends the value of the chips which will be shown on the screen. Keywords: AT89S51 Microcontroller, Temperature sensor, DS18B20, LCD1602 i 目 錄 第一章 前言 ......................................................................................................................... i 課題背景及目的 ....................................................................................................... 1 論文構成及研究內容 ............................................................................................... 1 倉庫溫度檢測系統(tǒng)的原理框圖 ............................................................................... 1 第二章 核心器件的選擇 ................................................................................................ 3 單片機的選擇 ........................................................................................................... 3 AT89S51 簡 介 ............................................................................................... 3 AT89S51 引腳功能 ....................................................................................... 3 溫度傳感器的選擇 ................................................................................................... 5 DS18B20 簡介 ............................................................................................... 5 DS18B20 的性能特點 ................................................................................... 6 第三章 硬件設計電路 ..................................................................................................... 7 主控制器 ................................................................................................................... 8 顯示電路 ................................................................................................................... 8 溫度檢測電路 ........................................................................................................... 8 溫度報警電路 ........................................................................................................... 9 第四章 軟件設計 ............................................................................................................. 10 概述 ...............