河南理工大学毕业设计(论文)说明书I摘要传统的温度计多采用物理原理,根据水银等随温度升降的热胀冷缩的性质,通过读取刻度值来判断温度值,这种方法不太方便,且测量需要的时间较长。本项目提供一种新的温度测量方案,采用具有SPI(SerialPeripheralInterface串行外围接口)接口的TN系列红外温度传感器来测量温度信号,可同时测量目标温度和环境温度,并将测量的数据送给SPCE061A单片机处理,之后送数码管显示,同时利用SPCE061A单片机的语音功能播报温度值。红外测温打破了传统的测温模式,它响应快、测量精度高、可靠性高、范围广,为非接触测量,因而不易损坏。该温度计以其准确快捷的测量功能、清晰易懂的数字化显示方便人们日常生活使用,语音播报功能使其更加智能化、人性化。关键词:红外测温;SPCE061A单片机;语音播报河南理工大学毕业设计(论文)说明书IIADesignofIntelligentInfraredThermometerAbstractMostofthetraditionalthermometersadoptsmercurycolumnwhichhasthephysicalprinciplethatitexpandswithheatandcontractswithcoldalongwiththechangeoftemperature,andwecanreadthetemperatureoutaccordingtotheinfinity.Thismethodisnotconvenient,andittakesalongtimetomeasure.ThispaperproposesanewthermometerprojecttomeasurethetemperaturesignalbyusingtheTNseriesinfraredtemperaturesensorwhichhastheSPI(SerialPeripheralInterface).Thesensorcanmeasureboththetargettemperatureandenvironmenttemperatureatthesametime,meanwhilethetemperaturedatawhichhavebeenmeasuredcanbetransferredtotheSPCE061Amicrocontrollertoprocess.Then,thedatawillbetransferredtodatadisplay,andwillbereportedbyusingtheSPCE061A’svoicereportfunctioninthemeanwhile.Infraredthermometerbreaksthroughtraditionaltemperaturemeasurementpattern.Itresponsesquickly,andhashighaccuracyandhighreliabilityandmeasuresinlargearea.Itisalsoawayofnon-contactmeasurement,soitisn’teasytobreak.Thisthermometercanmeasureaccuratelyandquickly,andhastheclearandeasydisplay.Alltheseofferconvenientconditiontoourdailylife.Furthermore,thevoicereportfunctionmakesitmoreintelligentandhuman.Keywords:infraredthermometry;SPCE061Amicrocontroller;voicereport河南理工大学毕业设计(论文)说明书III目录1前言.......................................................11.1选题的目的和意义........................................11.2红外测温技术的发展和国内外研究概况......................11.3设计任务和要求..........................................31.3.1设计任务............................................31.3.2设计要求............................................32概述.......................................................42.1红外测温概况............................................42.1.1红外测温的基础理论..................................42.1.2红外测温的特点......................................72.2智能化测量仪表概述......................................72.2.1智能化测量仪表的基本组成及其发展....................82.2.2智能化测量仪表的设计方法............................93系统方案论证..............................................113.1任务分析...............................................113.2方案选择...............................................113.2.1方案一.............................................113.2.2方案二.............................................113.3系统工作原理...........................................124系统硬件设计..............................................144.1主控模块...............................................144.1.1SPCE061A简介......................................144.1.2SPCE061A精简开发板................................154.1.3主控模块电路.......................................164.2电源和音频输出电路.....................................164.2.1电源电路...........................................164.2.2音频输出电路.......................................164.3红外测温模块...........................................164.3.1红外测温模块的引脚介绍.............................184.3.2红外测温模块时序图.................................184.3.3红外测温模块温度值的计算...........................194.4键盘显示模块...........................................204.4.1键盘显示电路.......................................204.4.2模块功能及接口说明.................................20河南理工大学毕业设计(论文)说明书IV4.5系统总体硬件电路图.....................................215系统软件设计..............................................225.1主程序.................................................225.2测温程序...............................................225.3播报显示程序...........................................225.4中断服务程序...........................................225.5软件结构...............................................226抗干扰技术................................................296.1单片机抗干扰技术概述...................................296.1.1干扰的来源和后果...................................296.1.2硬件抗干扰技术.....................................306.1.3软件抗干扰技术.....................................326.2本系统采用的抗干扰技术.................................347结论......................................................36致谢........................................................37参考文献....................................................38附录一智能红外测温计的程序................................391主程序...................................................392读测量数据的用户函数.....................................413红外测温模块驱动函数.....................................434显示并播放温度值函数.....................................465共阴数码管显示驱动程序...................................486初始化键盘函数和扫描键盘函数.............................557中断服务程序.............................................57附录二系统总体硬件电路图...................................59河南理工大学毕业设计(论文)说明书11前言1.1选题的目的和意义体温是人体生命活动的基本特征,也是观察人体机能是否正常的重要指标之一。在目前的日常生活中,人们使用最广的水银体温计是根据水银等随温度升降的热胀冷缩的性质,通过读取刻度值来判断温度值,它有着诸多缺点:传统温度计在使用时,要和被测量者接触,往往要等待较长时间,以期让其充分受热,当测量结束后还要将水银重新甩入水银泡中。由于水银泡是由很薄的玻璃制成极易破碎,而且其中的水银蒸汽对人体有着极强的毒害作用,报纸上就曾多次刊登小孩因咬碎水银泡而误吞水银造成中毒的事件,可