您好,欢迎访问三七文档
当前位置:首页 > 临时分类 > 基于51单片机的温度报警器
兰州交通大学---杨彦平II基于51单片机的温度报警器摘要如今火灾频频发生,比如电气线路短路、过载、接触电阻过大等引发高温火灾;静电产生高温火灾;雷电等强电侵入导致高温火灾;最主要是机房内电脑、空调等用电设备长时间工作,导致设备老化,空调发生故障,而不能降温;因此机房内所属的电子产品发热快,在短时间内机房温度升高超出设备正常温度,导致系统瘫痪或产生火灾,这时温度报警系统就会发挥应有的功能了。因此本课程设计将利用单片机STC89S52设计了一种数字温度计,它由单片机、DS18B20传感器以及数码管等部件组成,本温度计属于多功能温度计,功能较强,可以设置上下限报警温度,且测量准确、误差小。当测量温度超过设定的温度上下限时,启动蜂鸣器和指示灯报警。这种温度报警器结构简单,可操作性强,应用广泛。工作时,温度测量范围为5-38ºC。当前环境温度若超过设定的高温临界温度,由单片机发出报警信号,从而防止带来的不必要的损失。关键词:STC89C52;DS18B20;数码管电子技术课设ABSTRACTNowfirehappenfrequently,suchaselectricalwiringshortcircuit,overload,largecontactresistance,hightemperaturefire;Electrostaticgenerationhightemperaturefire;Andsoonhighvoltagecausedbylightningintrudedintotheleadtohightemperaturefire;Themainelectricalequipmentsuchascomputers,airconditioningisthetelecomroomtoworklonghours,causetheequipmentaging,themalfunctionoftheairconditioningnotcooling;Electronicproductheatfaster,sotheroombelongtoroomtemperatureinashorttimemorethananormaltemperature,causingthesystemtocrashortoproducefire,whenthetemperaturealarmsystemwillplaytheirfunctions.ThereforethiscoursewillusethemicrocontrollerSTC89S52designadigitalthermometer,itiscomposedofsinglechip,DS18B20sensorsanddigitaltubeparts,thisbelongstothemultifunctionalthermometerthermometer,strongfunction.Whenmeasuringtemperaturemorethansetthetemperatureoftheupperandlowerlimit,startthebuzzerandlightalarm.Thistemperaturealarmhassimplestructure,strongoperability,wideapplication.Atwork,temperaturemeasurementrangeis5-38DHSC.Ifthecurrentenvironmenttemperaturemorethansethighcriticaltemperature,sendoutalarmsignalbysingle-chipmicrocomputer,topreventunnecessaryloss.Keywords:AT89C52D,S18B20,Digitaltube兰州交通大学---杨彦平III目录第一章设计背景及要求................................................................................................-1-1.1设计意义....................................................................................................................-1-1.2设计要求....................................................................................................................-2-1.2.1基本功能.................................................................................................................-2-1.2.2扩展功能.................................................................................................................-2-1.3总体设计方案............................................................................................................-2-1.3.1数字温度计设计方案论证.....................................................................................-2-1.3.2单片机的选择.........................................................................................................-3-1.3.3温度传感器的选择.................................................................................................-4-1.3.4显示模块选择.........................................................................................................-8-第二章系统硬件电路设计..........................................................................................-10-2.1系统整体电路图.......................................................................................................-11-2.2单片机最小系统.......................................................................................................-11-2.3温度传感器系统......................................................................................................-12-2.4报警电路设计..........................................................................................................-14-2.5显示电路设计..........................................................................................................-15-2.6电源电路设计..........................................................................................................-15-第三章.系统软件设计.................................................................................................-16-3.1主程序......................................................................................................................-16-3.2读出温度子程序......................................................................................................-17-3.3温度转换命令子程序..............................................................................................-17-3.4计算温度子程序......................................................................................................-18-3.5键盘扫描流程图......................................................................................................-19-第四章测试与结果分析..............................................................................................-20-4.1仿真软件介绍..........................................................................................................-20-4.2仿真结果..................................................................................................................-22-4.2.1用Keil进行程序编译.......................................................................................-22-4.2.2在Proteus中仿真.............................................................................................-22-4.3创新设计....................................................................................
本文标题:基于51单片机的温度报警器
链接地址:https://www.777doc.com/doc-1900626 .html