【正文】
本科學(xué)生畢業(yè) 設(shè)計 基于 STC89C52 的傳感器控制系統(tǒng)設(shè)計 黑 龍 江 工 程 學(xué) 院 二 ○一一 年六月 The Graduation Design for Bachelor39。s Degree Design for STC 89C52based sensor control system Heilongjiang Institute of Technology 202006Harbi黑龍江工程學(xué)院本科生畢業(yè)設(shè)計 I 摘 要 本設(shè)計實現(xiàn) 的是單片機溫濕度測量與紅外開關(guān)控制系統(tǒng) ,以 STC89C52單片機為控制核心 , 采用集 A/D、 D/A 為一體的 PCF859151T 芯片進行模數(shù)轉(zhuǎn)換, 通過數(shù)碼管顯示所測量的溫濕度,紅外傳感器采集的紅外信號用單片機檢測高低電平進而控制 繼電器開關(guān)電路 。 闡述了 硬件結(jié)構(gòu)原理, 并分析了相應(yīng)的軟件 設(shè)計及其要點,包括軟件設(shè)計流程及其程序?qū)崿F(xiàn)。 傳統(tǒng)的溫濕度測量方法是用濕度表、毛發(fā)濕度表、雙金屬式測量計和濕度試紙等測試器材,通過人工進行檢測,傳統(tǒng)的開關(guān)電路都是人工撥動開關(guān)實現(xiàn)的,這種人工方法費時費力、效率低,且測試的溫度及濕度誤差 大,隨機性大。而本文就是針對這種缺陷而研究的一種系統(tǒng),設(shè)計一種造價低廉、使用方便且測量 系統(tǒng)結(jié)構(gòu)簡單、實用,提高了測量精度和效率 。 關(guān)鍵詞: 單片機;傳感器;控制 ; 測量 ;系統(tǒng) 黑龍江工程學(xué)院本科生畢業(yè)設(shè)計 II ABSTRACT The design and implementation of measurement and control temperature humidity and infrared is MCU system, STC89C52 microcontroller as control core, using set A/D and D/A for the integration of PCF859151T chips for frequencyfield, as measured by digital pipe display of temperature and humidity, infrared sensors to collect infrared signal detection height level and MCU control relay switching applications. Describe the hardware structure and principle, and analyzes the corresponding software design and main points, including software design process and procedure of implementation. The traditional temperature and humidity measurement method is to use humidity table, hair humidity table, dual metal type gauge and humidity dipstick test equipment, such as by artificial detection, the traditional switch circuit are artificially clicked switch implementation, this artificially method, the low efficiency, timeconsuming and testing temperature and humidity error is big, the randomness. This paper is aimed at the defects and research system, design a kind of low cost, use convenient and measurement system structure is simple, practical, and improve the measuring precision and efficiency. Key words: microcontroller。 sensor。 control。 measurement。 system 黑龍江工程學(xué)院本科生畢業(yè)設(shè)計 目 錄 摘要 .................................................................................................................. I Abstract ........................................................................................................... II 第 1章 緒論 ................................................................................................... 1 課題研究的目的和意義 ............................................................................................ 1 課題現(xiàn)狀和發(fā)展趨勢 ................................................................................................ 1 主要內(nèi)容和研究方法 ................................................................................................ 2 第 2章 系統(tǒng)總體分析與硬件設(shè)計 ................................................................ 4 系統(tǒng)功能及系統(tǒng)的組成和工作原理 ........................................................................ 4 技術(shù)指標(biāo)及設(shè)計方案 ...................................................................................... 4 硬件系統(tǒng)設(shè)計 .................................................................................................. 4 主要組件簡介 ................................................................................................. 7 模塊的 設(shè)計 .............................................................................................................. 14 溫度采集模塊 ............................................................................................... 14 濕度采集模塊 ............................................................................................... 15 紅外采集模塊 ............................................................................................... 17 單片機處理模塊 ........................................................................................... 18 本章小結(jié) .................................................................................................................. 18 第 3章 軟件系統(tǒng)設(shè)計 ................................................................................... 19 軟件的仿真和編譯 .................................................................................................. 19 仿真軟件介紹 ............................................................................................... 19 軟件的編譯過程 ........................................................................................... 21 軟件的模塊化設(shè)計 .................................................................................................. 21 采樣轉(zhuǎn)換與控制 ........................................................................................... 21 顯示結(jié)果 ....................................................................................................... 22 本章小結(jié) .................................................................................................................. 22 第 4章 硬件調(diào)試方案 ................................................................................... 23 硬件電路的調(diào)試 ...................................................................................................... 23 功能模塊的調(diào)試方案 ............................................................................................ 24 本章小結(jié) .................................................................................................................. 25 黑龍江工程學(xué)院本科生畢業(yè)設(shè)計 結(jié)論 ................................................................................................................ 26 參考文獻 ........................................................................................................ 27 致謝 ................................................................................................................ 28 附錄 ................................................................................................................ 29 黑龍江工程學(xué)院本科生畢業(yè)設(shè)計 1 第 1章 緒 論 隨著社會經(jīng)濟的快速