首页 > 期刊投稿知识库 > 温度检测报警系统论文

温度检测报警系统论文

发布时间:

温度检测报警系统论文

摘要本设计的温度测量计加热控制系统以AT89S52单片机为核心部件,外加温度采集电路、键盘显示电路、加热控制电路和越限报警等电路。采用单总线型数字式的温度传感器DSI8B20,及行列式键盘和动态显示的方式,以容易控制的固态继电器作加热控制的开关器件。本作品既可以对当前温度进行实时显示又可以对温度进行控制,以使达到用户需要的温度,并使其恒定再这一温度。人性化的行列式键盘设计使设置温度简单快速,两位整数一位小数的显示方式具有更高的显示精度。建立在模糊控制理论控制上的控制算法,是控制精度完全能满足一般社会生产的要求。通过对系统软件和硬件设计的合理规划,发挥单片机自身集成众多系统及功能单元的优势,再不减少功能的前提下有效的降低了硬件的成本,系统操控更简便。实验证明该温控系统能达到0.2℃的静态误差,0.45℃的控制精度,以及只有0.83%的超调量,因本设计具有很高的可靠性和稳定性。关键词:单片机 恒温控制 模糊控制引言温度是工业控制中主要的被控参数之一,特别是在冶金、化工、建材、食品、机械、石油等工业中,具有举足重轻的作用。随着电子技术和微型计算机的迅速发展,微机测量和控制技术得到了迅速的发展和广泛的应用。 采用单片机来对温度进行控制,不仅具有控制方便、组态简单和灵活性大等优点,而且可以大幅度提高被控温度的技术指标,从而能够大大提高产品的质量和数量。MSP430系列单片机具有处理能强、运行速度快、功耗低等优点,应用在温度测量与控制方面,控制简单方便,测量范围广,精度较高。温度传感器将温度信息变换为模拟电压信号后,将电压信号放大到单片机可以处理的范围内,经过低通滤波,滤掉干扰信号送入单片机。在单片机中对信号进行采样,为进一步提高测量精度,采样后对信号再进行数字滤波。单片机将检测到的温度信息与设定值进行比较,如果不相符,数字调节程序根据给定值与测得值的差值按PID控制算法设计控制量,触发程序根据控制量控制执行单元。如果检测值高于设定值,则启动制冷系统,降低环境温度;如果检测值低于设定值,则启动加热系统,提高环境温度,达到控制温度的目的。图形点阵式液晶可显示用户自定义的任意符号和图形,并可卷动显示,它作为便携式单片机系统人机交互界面的重要组成部分被广泛应用于实时检测和显示的仪器仪表中。支持汉字显示的图形点阵液晶在现代单片机应用系统中是一种十分常用的显示设备,汉字BP机、手机上的显示屏就是图形点阵液晶。它与行列式小键盘组成了现代单片机应用系统中最常用的人机交互界面。本文设计了一种基于MSP430单片机的温度测量和控制装置,能对环境温度进行测量,并能根据温度给定值给出调节量,控制执行机构,实现调节环境温度的目的。━、硬件设计1:MSP430系列单片机简介及选型单片机即微控制器,自其开发以来,取得了飞速的发展。单片机控制系统在工业、交通、医疗等领域的应用越来越广泛,在单片机未开发之前,电子产品只能由复杂的模拟电路来实现,不仅体积大,成本高,长期使用后元件老化,控制精度大大降低,单片机开发以后,控制系统变为智能化了,只需要在单片机外围接一点简单的接口电路,核心部分只是由人为的写入程序来完成。这样产品体积变小了,成本也降低了,长期使用也不会担心精度达不到了。特别是嵌入式技术的发展,必将为单片机的发展提供更广阔的发展空间,近年来,由于超低功耗技术的开发,又出现了低功耗单片机,如MSP430系列、ZK系列等,其中的MSP430系列单片机是美国德州仪器(TI)的一种16位超低功耗单片机,该单片机

已把我毕业论文的一部分发给你了,应该是你想要的。还需要其它的说一声

无限温度检测报警系统论文

本系统主要由单片机和GSM短信模块组成,借助最可靠、最成熟的GSM移动网络,以最直观的中文短消息或电话形式,直接把报警地点的情况反映到您的手机屏幕上。它采用主动式红外传感器进行检测,变有形的传统防盗网防盗窗为无形,给火灾时的逃生提供方便。并配备烟雾传感器和燃气泄漏传感器,实现防火、防燃气泄漏的作用。【关键词】单片机 GSM模块 传感器237513901

智能无线防盗系统的设计 摘要:系统地介绍智能无线防盗系统的基本原理、组成框图,详细地描述电话网络的接收方法;论述热释电红外传感器、语音等电路,给出部分基本电路和软件流程。 关键词:无线防盗 报警 热释电红外传感器 随着国家智能化小区建设的推广,防盗系统已成为智能小区的必需设备。本文利用单片机控制技术和无线网络技术,开发一种具有联网功能的智能无线防盗系统,并开发相关的传感器。采用无线数据传输方式,不需重新布线,特别适用于已装修用户及布线不方便的场合。 1 智能无线防盗系统的基本原理 智能无线防盗系统由传感器、家庭智能报警器、物业管理中心接警主机及相关的控制管理软件组成。图1为家庭智能报警器方框图,图2为物业管理中心接警主机方框图。 1.1 主机电路 如图1所示,主机电路由射频接收模块接收传大吃一惊器发来的报警信号,通过解码器(PT2272)解码后得到报警传感器的地址和数据类型只有主机和传感器地址相同时才能被主机接收。解码输出的数字代表传感器类型解骊输出信号进入CPU的INT1,触发中断处理程序。中断处理程序通过DTMF收发电路,拨打用户预先设好的电话号码(如手机号码,办公室号码)进行远程拨号报警;同时,启动语音电路,将预先录制好的语音信号通过电话线传给主人,实现语音提示通信功能。CPU输出警笛触发信号,经放大后推动警笛或喇叭,以驱赶和震胁盗贼。用户还可通过电话线进行远程设/布防,及输入远程控制信号,通过8路控制输出端控制有线连接的电器设备,也可通过编码电路和射频发射模块控制无线连接的电器设备。显示部分采用RT12232A图形点阵LCD模块,实现汉字显示功能;显示报警时间与报警类型。键盘可实现密码修改、语音录入和信息查看功能。 物业管理中心的接收主机具有家庭报警主机的功能外,还可以通过RS232实现与物业管理中心的通信 功能,实现联网和小区控制。 1.1.1 DTMF收发电路 要实现电话线远程通信,关键部分为DTMF收发电路。它将实现自动拨号、忙音识别、铃声识别、远程接键数字信号识别等功能。我们选用MT8888双音多频(DTMF)收发器,与单片机及音频放大电路组合,实现各种信号音的检测及DTMF信号的产生,并将DTMF信号送到电话线上,如图3所示。 MT8888是采用CMOS工艺生产的DTMF信号收发一体的集成电路。它的发送部分采用信号失真小、频率稳定性高的开关电容式D/A变换器,可发出16种双音多频DTMF信号。接收部分用于完成DTMF信号的妆收、分离和译码,并以4位并行二进制码的方式输出。 图3 选择中断模式时,当接收或发送了有效的音频信号后IRQ/CP脚输出低电平,产生中断信号供给CPU,在延迟控制电压的跳变缘将数据锁存至输出端;当选择呼叫过程(CP)方式时,只能接收250~550Hz的信号音,在拒收或无输入时,IRQ/CP脚输出低电平。 (1)电话信号音格式 忙音:450Hz,350ms有,350ms无。拨号音:450Hz,持续。回铃音:450Hz,1s有,4s无。 (2)信号音的判断方式 将MT8888的IRQ/CP脚连到AT89S52的T0脚,电话呼叫过程中的各种信号音经MT8888滤波限幅后得到方波,由MT8888的IRQ输出到AT89S52的T0脚,对T0脚信号记数5s。计数值位于2175~2357范围内,为拨号音;计数值位于1041~1212范围内,为忙音;计数值位于425~475范围内,为回铃音。在实际编程中,考虑到计数的误差以及程序的简化,可将范围适当放宽,但不能重叠。 (3)自动摘机 控制器与家里电话并接在一条电话线上。为了实现报警放打电话共用一条线,摘机电路按如下设置:将电话振铃信号通过光电耦合器TP521输入到AT89S52的IT脚,进行计数。接到振铃信号时,若连续振铃10次用户还没有摘机,则自动转到家庭智能报警器,CPU置P1.5脚为“1”,使继电器K1吸合,实现自动摘机功能。若在这10次振铃过程中,用户接通了电话,则控制器不响应,这样,使得控制器与电话不互相干扰。摘机后,检测MT8888输出的双音多频信号,以读出用户发来的远程信息,实现远程通信与控制功能。 图4 (4)自动报警 当接收到热释电传感器等发来的无线报警信号后,CPU立即发出报警信号,通过电话线传到远程用户。报警方式如下:用户通过面板设备10个报警电话,将它们存入24C04存储器中。当接到警情后,从第1个电话开始拨号,一直拨到第10个,来回拨3遍。如果任意一个电话回送了“#”键确认信号,即意味着报警已收到,不再继续拨号。每个号码需拨号。每个号码需拨号时间100ms,号码之间留500ms间隔。拨号时,先检测24C04中存储的电话号码。若为空,即未设此电话,跳过不拨,继续拨下一个电话号码。这样,用户可随意设置数个报警电话号码。我们规定号码长度最多不超过4位,以便存在24C04中。 1.1.2 语音电路 为了便于通信,采用了语音芯片,实现语音指示和报警功能。ISD1420为单片语音记录、回放一体化芯片,记录时长为20s;可被划分为160小段,每段125ms。当REC脚为低电平时,进行录音,PLAYE或PLAYL为低时进行放音,ISD1420可进行连续录音,也可进行分段录音。 分段放音:先送停止录放音码P1.2~P1.4=000,再送放音首地址A7~A0,P1.3或P1.4为低电平(PLAYE或PLAYL)开始放音;延时进行放音,最后送停止录放音码P1.2~P1.4=000,完成本段放音。重复上述过程,可分段放出数段语音。图4为语音电路原理。 1.1.3 编/解码电路 PT2262/2272是台湾普城公司生产的一种CMOS工艺制造的低功耗、低价位、通用编解码电路。PT2262/2272最多可有12位(A0~A11)三态地址端引脚(悬空、接高电平、接低电平),任意组合可提供531441地址码。 PT2262最多可有6位(D0~D5)数据端引脚,设定的地址码和数据码从17脚串行输出。编码芯片PT2262发出的编码信号由地址码、数据码、同步码组成一个完整的码字。地址码必须与家庭控制主机内解码芯片PT2272编址相同,以区分家庭控制器;数据码可用于区分传感器类型。当有报警信号时,PT2262的14脚为低电平,使能PT2262,从17脚输出编码信号,通过射频模块发射出去。 解码芯片PT2272接收到信号后,其地址码经过两次比较核对,VT脚才输出高电平,送到89S52的INT1,触发中断处理程序,以读取D0~D3的数据码,得知报警传感器状态和报警类型。图5为编/解码电路原理。 1.1.4 射频发射模块与射频接收模块 射频发射模块与射频接收模块原理如图6和图7所示,工作频率为433MHz。最大传输距离可达1000m。 1.2 传感器设计 1.2.1 被动红外热释电传感器 人体有恒定的体温,一般在37℃,所以会发出特定波长为10μm左右的红外线。被动式红外探头就是靠探测人体发射的10μm左右的红外线而进行工作的。人体发射的10μm左右的红外线,通过菲涅尔滤光片增强后,聚集到红外感应源上。红外感应源泉通常采用热释电元件。这种元件在接收到人体红外辐射温度发生变化时将会失去电荷平衡,向外释放电荷,后续电路经检测处理后产生报警信号。 图8为双元热释电红外检测元件LHI968的内部电路。它由两个双元热释电陶瓷,感应红外信号,再经场效应管放大输出。D端的电阻和S端的电容具有抗电磁干扰能力。 图7 信号从S端引出经前级放大,通过47μF电容后再次放大,与设定门限电压进行比较,获得报警输出信号。47μF电容能够除直流成分,从而消除了使用环境(阳光、灯光、火源泉等)对探测器的影响,后面再加一延时触发电路以便主人设防与撤防。现在已有专用集成芯片BISS0001实现以上功能。为了适应主人进门时撤防的需要,设计一报警延时电路。延时长度须满足:当人以1m/s的速度从探测器的正前方移动0.2m,不产生报警;但移动3m应报警,测试速度应能检测0.3~3m/s或更宽的速度范围。 1.2.2 门磁传大吃一惊器 无线门磁传感器一般案卷在门内侧的上方。它由两部分组成:较小的部件为永磁体,内部有一块永久磁铁,用来产生恒定的磁场;较大的是无线门磁主体,内部有一个常开型的干簧管。当永磁体和干簧管靠得很近时(小于5mm),无线门磁传感器处于工作守候状态;当永磁体离开干簧管一定距离后,无线门磁传感器立即发射包含地址编码和自身识别码(也就是数据码)的433MHz的高频无线电信号。主机通过识别这个无线电信号的地址码,判断是否为同一个报警系统,然后根据自身识别码(也就是数据码),确定是哪一个无线门磁报警。 2 网络中心控制主机设计 网络中心控制主机设计与家庭控制器基本相同,只是加了一个RS232接口,实现与PC机相连。通过放在物管中心的PC机实现小区网络监控功能。 结语 采用现有电话网络,结合射频无线通信技术和单片机网络控制技术,使本防盗报警系统经济、可靠,组网灵活;家庭无需为传感器布线;具有广泛的市场发展前景。

我这里有 并且带gsm无线报警模块基于GSM平台的小区防盗报警系统设计摘 要现在单片机和PC机通过串行接口构成的多微机系统已经广泛应用于工业控制、,环境监测等场合,这些系统大多采用RS-232, RS-485或是有线Modem的通信方式,虽然很经济适用,但是有线数据传输方式很大程度上限制了其使用的场合,针对这种情况,可以利用GSM网络进行数据传输,在单片机系统中利用GSM引擎模块,结合已有的单片机系统通过RS-232接口实现数据的无线传输。本系统主要由单片机和GSM短信模块组成,借助最可靠、最成熟的GSM移动网络,以最直观的中文短消息或电话形式,直接把报警地点的情况反映到您的手机屏幕上。它采用主动式红外传感器进行检测,变有形的传统防盗网防盗窗为无形,给火灾时的逃生提供方便。。【关键词】单片机 GSM模块 传感器The guard against theft and alarm system Based on GSM ModemAbstractNowadays, the mufti-microcomputers system, which constituted with the single chip computer and PC through the serial interface, is already widely applied in many situations such as industry control, environment monitoring and so on. These systems are mostly based on RS-232, RS-485 or wired modem. Although very economical they are, their application is limited by the wired data transmission way in very great degree. To solve the problem, the data transmission would carry on through the GSM network, in other words, the GSM engine module would be combined with the traditional single chip system, and realize wireless data transmission through the RS-232 interface.The System is made up of MCU and GSM Modem. It will display the alarm content in Chinese directly at your mobile screen, and it recurs to the most reliable GSM mobile network. The system adopted initiative infrared sensor to detect, and it turned the traditional alarm net and alarm windows to immateriality..【keywords】 MCU GSM modem sensor绪论 22 89C51单片机简介 53 GSM系统简介 144系统硬件设计 195 家庭防盗报警系统的软件设计 29结 论 31致 谢 32参考文献 32

已把我毕业论文的一部分发给你了,应该是你想要的。还需要其它的说一声

温度检测报警论文

the "System on a Chip"Much has been written about the concept of a "system on a chip," the ever-increasing integration of logic and analog functions on one silicon die or chip. This paradigm is about to change. The results of work by universities, national labs, and companies such as Motorola, Inc., are paving the way for a true system on a chip, or SOC. These new SOCs will not only analyze data, but will measure, analyze, and react to their environment.The integration of power and analog elements with a CMOS microcontroller unit (MCU) has been possible for several years. Products have been introduced such as an integrated 68HC05 motor controller with integral power devices in an H-bridge configuration (1990). In 1993, a product called a System Chip MCU was introduced that provided a Society of Automotive Engineers J1850 interface, including the physical layer. This chip could withstand 40 V, based on the combination of power and analog capability with the MCU. However, the system input was not included in previous monolithic designs.What is the most recent development that promises to truly enable a system on a chip? It is the ability to combine CMOS and MEMS (microelectromechanical systems) structures into one process flow. Photo 1 illustrates a 68HC05 microcontroller with a 100 kPa pressure sensor integrated onto a single silicon die. A likely application is a side air bag sensor.A pressure sensor, inside the door panel of a car, could detect the change in pressure when the panel crumples under an impact. The ability to program the onchip microcontroller will enable the auto manufacturer to embed the control algorithm inside the chip. To complete an entire system, only a mechanism for actuating the air bag need be added. This actuation capability could be yet another step in the continuous integration of silicon and electronics/electromechanical systems. This platform provides a first step in the integration of electronics with electromechanical structures and at the same time raises several issues that must be resolved before a low-cost, high-quality product can be mass produced. One of these issues is that of testability.Typical logic circuits have many years of accumulated test data that can be used as a foundation for building the next generation of product. With sensors, however, very little previous technology can be reused. The reasons are the relative infancy of sensor technology and the uniqueness of each type of sensor. For example, the technology used to measure pressure (a thin diaphragm with integral strain gauge) is much different from that used for measuring acceleration (a proof mass forming a moving capacitor). The testing technology is different as well. Pressure measurements require a pressure source to be connected to the sensor; acceleration or shock detection requires shaking the device at some known frequency and force.System ConfigurationTo develop a proof-of-concept vehicle (see Figure 1), a 100 kPa pressure sensor was integrated onto Motorola's standard 8-bit 68HC05 microcontroller core along with the associated analog circuitry [1]. To this basic core was added analog circuitry for signal conditioning, a voltage and current regulator, and 10-bit A/D and 8-bit D/A converters. A temperature sensor was also incorporated into the design for compensation purposes.The pressure transducer is temperature dependent and has an inherent nonlinearity. To increase the accuracy of the system, a calibration or conditioning algorithm must be programmed into the microcontroller.The pressure transducer's output is conditioned by a variable gain and input offset amplifier that is controlled by the program stored in the MCU. The A/D converter is used to read the temperature sensor's and the pressure transducer's outputs. The band gap voltage regulator supplies a constant voltage for the pressure sensor, amplifier, and A/D converter. The band gap current regulator provides a constant current source for the temperature sensor.Calibration MethodThe MCU calibrates and compensates the pressure sensor's nonlinearity and temperature drift. To provide the maximum accuracy, an A/D input resolution of 10 bits was chosen and the calculation resolution was set at 16 bits, fixed point. To calibrate span and offset and compensate the nonlinearity of the sensor output, calibration software performs a second-order polynomial correction of sensor output described as:Vout = c0 + c1Vp + c2Vp2 (1)Cp = (c0, c1, c2 ) (2)where:Vout = calibrated outputVp = uncompensated pressure sensor outputTo compensate the temperature dependency of Cp, calibration software is used to calculate Cp using a second-order polynomial fitting equation to temperature:c0 = c00 + c01Vt + c02 Vt2 (3)c1 = c10 + c11Vt + c12 Vt2 (4)c2 = c20 + c21Vt + c22Vt2 (5)(6)where:Vt = temperature sensor outputThe Cts are read during the calibration procedure and stored in EPROM. The MCU calculates Cp from the temperature sensor output, Vt, and Ct. Cp is then used to calculate the calibrated pressure sensor output using the pressure transducer's output, Vp.Calibration ProcedureThe calibration system first adjusts the gain and offset of the amplifier to use the full A/D range. Then the characteristics of the uncompensated pressure sensor output are examined over several temperature points. At each temperature, a second-order polynomial described in Equation 1 is obtained by least square fitting and the coefficient set, Cp, is determined. After completing the calculation of Cp over all temperature points, Ct is determined by the least square fitting of Equations 3, 4, and 5 to determine Cp over the temperature points. At present, at least three separate temperature sampling points are required to complete the fitting calculation.Figure 2. The uncompensated output of the sensor-based system on a chip is plotted at four different temperatures.CharacteristicsFigure 2 shows the uncompensated sensor output characteristics over various temperatures after adjusting gain and offset. Based on these data, the coefficients for calibration were calculated and written into the onchip EPROM by the calibration system. The compensation value was rounded off to 8 bits. Figure 3 shows the calibrated and compensated output of the integrated MCU. Figure 4 shows the error from expected values. Since 1 bit is 0.4% error, the result indicates the error is within 0.4% of full-scale output.Figure 3. Compensated output of the system on a chip is improved through testing and calibration at three temperatures.Test IssuesSeveral issues are raised by this initial work, including the different types of testing required, unique test equipment, and the need for multipass testing. To make a low-cost integrated solution possible, these concerns must be addressed.The integration of a physical measurement function onto the already complex mixed-mode analog-digital chip raises the need for an additional type of testing. The physical medium being tested must be applied to the device and the response must be measured. Measuring the response to a physical stimulus is not aFigure 4. Bit error in the compensated output is within 1 bit at both 30°C and 85°Cstandard test for the semiconductor industry, especially under multiple temperatures. Standard equipment can test the digital and analog portions of the chip, but the application of a physical stimulus and the procedure of heating and cooling the device under test rapidly and accurately drive the need for a modified and unique tester. These testers are one of a kind and are not available as a standard. The tester therefore represents a large part of the final unit's cost.Not only are the testers expensive, but the throughput is limited. This raises the cost of each part because of the increased depreciation costs allocated to each device. The cost is further increased by the need for multipass testing. Remember that each part is first tested, using at least three different temperatures, to determine the transducer's output characteristics over temperature. Then these values are used to derive the compensation algorithm, which is loaded into the onchip EPROM. To complete the cycle, the device is once again tested over temperature to prove accuracy. Hence, not only is a special tester required, but it becomes a bottleneck since it must be used twice to complete each device—once to measure the characteristics and a second time to verify the result.Future DirectionsFinding ways to reduce the cost of testing is one of the keys to making a low-cost integrated sensor and MCU a reality. Ideas that could prove promising include:Thoroughly characterizing the designLimiting the operating temperatureLimiting the accuracyProgramming the MCU to take data during testingLoading the test and compensation algorithm into the MCU before testingSince this is a first proof-of-concept device, further characterization could provide a way to limit the number of temperatures required for compensations. Limiting the operating temperature range could also reduce the number of temperatures required for compensation testing. Data shown in Figure 3 indicate a 5% accuracy from 5°C to 25°C. Another potential cost reduction step would be to use the MCU's programmability for data logging during test. By storing the compensation program in the onchip EPROM prior to test, and then logging the uncompensated output into the EPROM during test, it might be possible to develop an algorithm for a one-pass test over temperature.Without a breakthrough in lowering the cost of testing this new integrated sensor and MCU, the system designer may be limited to the continued use of the present day solution—separate MCU and sensor.----------All the DS18B20 sensors, used for the multipoint test temperature, are connected with MCU on one of IO bus, and temperature data are collected by turns. If the system has a large amount of sensors, the time of MCU used in processing the temperature data is obviously prolonged, so the cycle of alternate test gets longer. In this paper, a new method that DS18B20 are rationally grouped is presented, and some measures are taken in software; as a result, the speed of alternate test advances distinctly.---------

用DS18B20做的电子温度计,非常简单。#include #include\"AscLed.h\"#include #include //********************************************************#define Seck (500/TK) //1秒中的主程序的系数#define OffLed (Seck*5*60) //自动关机的时间5分钟!//********************************************************#if (FHz==0) #define NOP_2uS_nop_()#else #define NOP_2uS_nop_();_nop_()#endif//**************************************#define SkipK 0xcc //跳过命令#define ConvertK 0x44 //转化命令#define RdDs18b20K 0xbe //读温度命令//*******************************************extern LedOut(void);//*************************************************sbit PNP1=P3^4;sbit PNP2=P3^5;sbit BEEP=P3^2;//***********************************#defineDQ PNP2 //原来的PNP2 BEEP//***********************************static unsigned char Power=0;//************************************union{ unsigned char Temp[2]; //单字节温度 unsigned int Tt; //2字节温度}T;//***********************************************typedef struct{ unsigned char Flag; //正数标志 0;1==》负数 unsigned char WenDu; //温度整数 unsigned int WenDuDot; //温度小数放大了10000}WENDU; //***********************************************WENDU WenDu;unsigned char LedBuf[3];//----------------------------------//功能:10us 级别延时// n=1===> 6Mhz=14uS 12MHz=7uS//----------------------------------void Delay10us(unsigned char n){ do{ #if (FHz==1) NOP_2uS;NOP_2uS; #endif }while(--n);}//-----------------------------------//功能:写18B20//-----------------------------------void Write_18B20(unsigned char n){ unsigned char i; for(i=0;i<8;i++){ DQ=0; Delay10us(1);//延时13us 左右 DQ=n & 0x01; n=n>>1; Delay10us(5);//延时50us 以上 DQ=1; }}//------------------------------------//功能:读取18B20//------------------------------------unsigned char Read_18B20(void){ unsigned char i; unsigned char temp; for(i=0;i<8;i++){ temp=temp>>1; DQ=0; NOP_2uS;//延时1us DQ=1; NOP_2uS;NOP_2uS;//延时5us if(DQ==0){ temp=temp&0x7F; }else{ temp=temp|0x80; } Delay10us(5);//延时40us DQ=1; } return temp;}//-----------------------------------void Init (void){ DQ=0; Delay10us(45);//延时500us DQ=1; Delay10us(9);//延时90us if(DQ){ //0001 1111b=1f Power =0; //失败0 }else{ Power++; DQ=1; }}//----------------------------------void Skip(void){ Write_18B20(SkipK); Power++;}//----------------------------------void Convert (void){ Write_18B20(ConvertK); Power++;}//______________________________________void Get_Ds18b20L (void){ T.Temp[1]=Read_18B20(); //读低位 Power++;}//______________________________________void Get_Ds18b20H (void){ T.Temp[0]=Read_18B20(); //读高位 Power++;}//------------------------------------//规范化成浮点数// sssss111;11110000// sssss111;1111(0.5,0.25,0.125,0.0625)//------------------------------------void ReadTemp (void){ unsigned char i; unsigned intF1=0; char j=1; code int Code_F[]={6250,1250,2500,5000}; WenDu.Flag=0; if (T.Temp[0] >0x80){ //负温度 T.Tt =~T.Tt+1; //取反+1=源吗 +符号S WenDu.Flag=-1; } T.Tt <<= 4; //左移4位 WenDu.WenDu=T.Temp[0]; // 温度整数 //************************************************** T.Temp[1]>>=4; //--------------------------- for (i=0;i<4;i++){ //计算小数位 F1 +=(T.Temp[1] & 0x01)*Code_F; T.Temp[1]>>=1; } WenDu.WenDuDot=F1; //温度的小数 Power=0;}//----------------------------------void Delay1S (void){ static unsigned int i=0; if (++i==Seck) {i=0ower++;}}//----------------------------------void ReadDo (void){ Write_18B20(RdDs18b20K); Power++;}/**********************************函数指针定义***********************************/code void (code *SubTemp[])()={ Init,Skip,Convert,Delay1S,Init,Skip,ReadDo,Get_Ds18b20L, Get_Ds18b20H,ReadTemp};//**************************************void GetTemp(void){ (*SubTemp[Power])();}//---------------------------------------------------//将温度显示,小数点放大了10000.void GetBcd(void){ LedBuf[0]=WenDu.WenDu / 10; LedBuf[1]=WenDu.WenDu % 10 +DotK; LedBuf[2]=(WenDu.WenDuDot/1000)%10; if(LedBuf[0]==0)LedBuf[0]=Black; if(WenDu.Flag==0) return; if(LedBuf[0] !=Black){ LedBuf[2]=LedBuf[1]; LedBuf[1]=LedBuf[0]; LedBuf[0]=Led_Pol; //'-' }else{ LedBuf[0]=Led_Pol; //'-' }}/*//---------------------------------------------------void JbDelay (void){ static long i; if (++i>=OffLed){ P1=0xff; P2=0xff; PCON=0x02; }}*//*****************************************************主程序开始1:2002_10_1 设计,采用DS18B20测量2:采用函数数组读取DS18B20.LED数码管显示正常!3:改变FHz可以用6,12MHz工作!******************************************************/code unsigned char Stop[3] _at_ 0x3b;void main (void){ P1=0xff; WenDu.WenDu=0; while (1){ GetTemp(); GetBcd(); // JbDelay(); LedOut(); }}复制代码 20091012_8b1ef92155560c13b5807ZmoDVSacjwD[1].jpg (12 KB) 2009-10-21 23:21 上传下载次数:0

已把我毕业论文的一部分发给你了,应该是你想要的。还需要其它的说一声

价格合理!信工毕业 就会单片机

温度报警系统毕业论文

温度相关的毕业设计 ·基于单片机的数字温度计的设计·基于MCS-51数字温度表的设计·单片机的数字温度计设计·基于单片机的空调温度控制器设计·基于数字温度计的多点温度检测系统·设施环境中温度测量电路设计·DS18B20数字温度计的设计·多点温度采集系统与控制器设计·基于PLC和组态王的温度控制系统设计·温度监控系统的设计·用单片机进行温度的控制及LCD显示系统的设计·单片机电加热炉温度控制系统·全氢罩式退火炉温度控制系统·数字温度计的设计·基于单片机AT89C51的语音温度计的设计·基于单片机的多点温度检测系统·基于51单片机的多路温度采集控制系统·基于单片机的数字显示温度系统毕业设计论文·基于MCS51单片机温度控制毕业设计论文·西门子S7-300在温度控制中的应用·燃气锅炉温度的PLC控制系统·焦炉立火道温度软测量模型设计·温度检测控制仪器·智能温度巡检仪的研制·电阻炉温度控制系统·数字温度测控仪的设计·温度测控仪设计·多路温度采集系统设计·多点数字温度巡测仪设计·LCD数字式温度湿度测量计·64点温度监测与控制系统·温度报警器的电路设计与制作·基于单片机的数字温度计的电路设计·全氢煤气罩式炉的温度控制系统的研究与改造·温度检测与控制系统·红外快速检测人体温度装置的设计与研制·具有红外保护的温度自动控制系统的设计·基于单片机的温度测量系统的设计·数字温度计设计·DS18B20温度检测控制·PN结(二极管)温度传感器性能的实验研究·多功能智能化温度测量仪设计·软胶囊的单片机温度控制(硬件设计)·空调温度控制单元的设计·大容量电机的温度保护——软件设计·大容量电机的温度保护 ——硬件电路的设计·基于DS18B20温度传感器的数字温度计设计·热轧带钢卷取温度反馈控制器的设计·基于单片机的温度采集系统设计·多点温度数据采集系统的设计·基于单片机的数字式温度计设计·18B20多路温度采集接口模块·基于单片机的户式中央空调器温度测控系统设计·单片机电阻炉温度控制系统设计·基于单片机的电阻炉温度控制系统设计·基于ARM的嵌入式温度控制系统的设计·基于DS18B20的多点温度巡回检测系统的设计·基于单片机的多点无线温度监控系统·基于MSC1211的温度智能温度传感器·用集成温度传感器组成测温控制系统·室内温度控制报警器·自动温度控制系统·烤箱温度控制系统·基于单片机的电加热炉温度控制系统设计·基于PLC的温度监控系统设计·基于无线传输技术的室温控制系统设计——温度控制器软件设计·温度箱模拟控制系统·基于无线传输技术的室温控制系统设计——温度控制器硬件设计·数字式温度计的设计·温度监控系统设计·基于单片机的电阻炉温度控制系统·基于plc的温度湿度检测和显示系统设计·基于单片机的3KW电炉温度控制系统的设计·腔型肿瘤热疗仪温度控制系统设计·基于AT89S51单片机的数字温度计设计·吹塑薄膜挤出机温度控制与检测系统设计·电加热炉PLC温度自适应控制系统的研究·高压母线温度自动监测装置的设计·高压母线温度自动检测装置·小型热水锅炉单片机温度控制系统·消毒柜单片机温度控制·嵌入式系统在多点温度控制中的应用·单片机温度控制系统·上下限温度报警器的设计·基于单片机的饮水机温度控制系统设计·基于单片机的温度测量系统设计

室温温度检测系统设计论文

热电致冷器件特别适合于小热量和受空间限制的温控领域。改变加在器件上的直流电的极性即可变致冷为加热,而吸热或放热率则正比于所加直流电流的大小。Pe1tier 温控器的设定温度可以在一个较宽的范围内任意选择,可选择低于或高于环境温度。在本系统中我们选用了天津蓝天高科电源有限公司生产的半导体致冷器件 TES1-12739,其最大温差电压 14.7V,最大温差电流3.9A最大致冷功率33.7W。1.5 其它部分系统采用Samsung(三星)公司生产的真空荧光数码显示屏 VFD用来实时显示当前温度,以观察控制效果。键盘和串行通信接口用来设定控制温度和调整PID参数。系统电路原理图如图3所示。2 系统软件设计系统开始工作时,首先由单片机控制软件发出温度读取指令,通过数字温度传感器 DS18B20 采样被控对象的当前温度值T1并送显示屏实时显示。然后,将该温度测量值与设定值T比较,其差值送 PID控制器。PID 控制器处理后输出一定数值的控制量,经DA 转换为模拟电压量,该电压信号再经大电流驱动电路,提高电流驱动能力后加载到半导体致冷器件上,对温控对象进行加热或制冷。加热或制冷取决于致冷器上所加电压的正负,若温控对象当前温度测量值与设定值差值为正,则输出负电压信号,致冷器上加载负电压温控对象温度降低;反之,致冷器上加载正向电压,温控对象温度升高。上述过程:温度采样-计算温差-PID调节-信号放大输出周而复始,最后将温控对象的温度控制在设定值附近上下波动,随着循环次数的增加,波动幅度会逐渐减小到某一很小的量,直至达到控制要求。为了加快控制,在进入PID控制前加入了一段温差判断程序。当温度差值大于设定阈值Δt时,系统进行全功率加热或制冷,直到温差小于Δt才进入PID控制环节。图4为系统工作主程序的软件流程图.3 结论本文设计的基于单片机数字PID控制的精密温度控制系统,在实际应用中取得了良好的控制效果,温度控制精度达到±0.1℃。经48小时连续运行考验,系统工作稳定,有效地降低了辐亮度标准探测器的温度系数,使辐亮度标准探测器在温度变化较大的环境中也能保持其高精度,为实现基于探测器的高精度辐射定标的广泛应用奠定了基础。本文作者创新点:在原来基于PC的PID温控系统的基础上,设计了由单片机、数字式温传感器DS18B20和半导体致冷器组成的精密温度控制系统。该温控系统的应用为高精度光辐射测量仪器-辐亮度标准探测器的小型化、智能化提供了有利条件。

毕业设计论文可以找别人帮你做啊,把你的详细要求发不到任务中国网,让高手给你解决这个问题。或者你去抄一片。

二.系统软件设计图4 系统程序流程图2.1 系统程序流程图系统程序流程图如图4所示。2.2 温度部分软件设计DS18B20的一线工作协议流程是:初始化→ROM操作指令→存储器操作指令→数据传输。其工作时序包括初始化时序、写时序和读时序。故主机控制DS18B20完成温度转换必须经过三个步骤:每一次读写之前都要对DS18B20进行复位,复位成功后发送一条ROM指令,最后发送RAM指令,这样才能对DS18B20进行预定的操作。复位要求主CPU将数据线下拉500微秒,然后释放,DS18B20收到信号后等待16~60微秒左右,后发出60~240微秒的存在低脉冲,主CPU收到此信号表示复位成功。程序主要函数部分如下:(1)初始化函数//读一个字节函数ReadOneChar(void){unsigned char i=0;unsigned char dat = 0;for (i=8;i>0;i--){ DQ = 0; // 给脉冲信号dat>>=1;DQ = 1; // 给脉冲信号if(DQ)dat|=0x80;delay(4);}return(dat);}//写一个字节函数WriteOneChar(unsigned char dat){unsigned char i=0;for (i=8; i>0; i--){DQ = 0;DQ = dat&0x01;delay(5);DQ = 1;dat>>=1;}}(2)读取温度并计算函数ReadTemperature(void){unsigned char a=0;unsigned char b=0;unsigned int t=0;float tt=0;Init_DS18B20();WriteOneChar(0xCC); // 跳过读序号列号的操作WriteOneChar(0x44); // 启动温度转换Init_DS18B20();WriteOneChar(0xCC); //跳过读序号列号的操作WriteOneChar(0xBE); //读取温度寄存器等(共可读9个寄存器) 前两个就是温度a=ReadOneChar();b=ReadOneChar();t=b;t<<=8;t=t|a;tt=t*0.0625;t= tt*10+0.5; //放大10倍输出并四舍五入---此行没用(3)主程序部分见前return(t);}三. 结束语AT89C2051单片机体积小、重量轻、抗干扰能力强、对环境要求不高、价格低廉、可靠性高、灵活性好。即使是非电子计算机专业人员,通过学习一些专业基础知识以后也能依靠自己的技术力量来开发所希望的单片机应用系统。本文的温度控制系统只是单片机广泛应用于各行各业中的一例,相信读者会依靠自己的聪明才智使单片机的应用更加广泛化。另外对本例子可以作一些扩展,单片机的应用越来越广泛,由于单片机的运算功能较差,往往需要借助计算机系统,因此单片机和PC机进行远程通信更具有实际意义。目前此设计已成功应用于钻井模拟器实验室室温控制。本文作者创新观点:采用的单片机AT89C2051性价比高,而且温度传感器DS18B20转化温度的方法非常简洁且精度高、测试范围较广。参考文献[1]林伸茂.8051单片机彻底研究基础篇 北京:人民邮电出版社 2004[2]范风强等.单片机语言C51应用实战集锦 北京:电子工业出版社 2005[3]谭浩强.C语言程序设计(第二版) 北京:清华大学出版社 1999[4]夏路易等.电路原理图与电路板设计教程 北京:北京希望电子出版社 2002[5]赵晶.Protel99高级应用 北京:人民邮电出版社 2000[6]聂毅.单片机定时器中断时间误差的分析及补偿[J] 微计算机信息 2002,18(4):37~38

我做的课程设计,用的数码管,也做了protues仿真,你有需要的话,我邮箱是。希望对你有帮助,#includesbit P11=P1^1;sbit P12=P1^2;sbit P13=P1^3;sbit P14=P1^4;/////数码管1断码控制///////////////sbit P15=P1^5;sbit P16=P1^6;sbit P17=P1^7;sbit P32=P3^2;/////数码管2段码控制////////////////sbit up=P3^7;sbit down=P3^6; ////按键操作端口//////////////////sbit P35=P3^5; ////////控制晶闸管端口/////////sbit DQ =P3^3; ///////温度传感器端口///////// #define THCO 0xee#define THLO 0x00unsigned char code duan[]={ 0xc0,0xf9,0xa4,0xb0,0x99,0x92,0x82,0XD8,0x80,0x90,0x88,}; //////////////////////////////////////////int b=0;char pwm=0;int k;char r=0,q=0;static char wendu_1;char hao=20;//////////////////////////////////////////////void delay(unsigned int i){while(i--);}//////////////////////////////////////////Init_DS18B20(void){unsigned char x=0;DQ = 1; //DQ复位delay(8); //稍做延时DQ = 0; //单片机将DQ拉低delay(80); //精确延时 大于 480usDQ = 1; //拉高总线delay(14);x=DQ; //稍做延时后 如果x=0则初始化成功 x=1则初始化失败delay(20);}////////////////////////////////////////////ReadOneChar(void){unsigned char i=0;unsigned char dat = 0;for (i=8;i>0;i--){DQ = 0; // 给脉冲信号dat>>=1;DQ = 1; // 给脉冲信号if(DQ)dat|=0x80;delay(4);}return(dat);}////////////////////////////////////////////////WriteOneChar(unsigned char dat){unsigned char i=0;for (i=8; i>0; i--){DQ = 0;DQ = dat&0x01;delay(5);DQ = 1;dat>>=1;}//delay(4);}/////////////////////////////////////////////////DS18B20程序读取温度ReadTemperature(void){unsigned char a=0;unsigned char b=0;unsigned int t=0;float tt=0;Init_DS18B20();WriteOneChar(0xCC); // 跳过读序号列号的操作WriteOneChar(0x44); // 启动温度转换Init_DS18B20();WriteOneChar(0xCC); //跳过读序号列号的操作WriteOneChar(0xBE); //读取温度寄存器等(共可读9个寄存器) 前两个就是温度a=ReadOneChar();b=ReadOneChar();t=b;t<<=8;t=t|a;tt=t*0.0625;return(t);}xianshi(){/////////////////当前温度显示///////////////////////////// P11=1; P0=duan[wendu_1/1000]; for(k=0;k<1000;k++); P1=0;P12=1; P0=duan[wendu_1/100%10]; for(k=0;k<1000;k++); P1=0;P13=1; P0=duan[wendu_1%100/10]; for(k=0;k<1000;k++); P1=0;P14=1; P0=duan[wendu_1%10]; for(k=0;k<1000;k++); P1=0; ///////////////////////////目标电压显示/////////////// P15=1; P2=duan[hao/1000]; for(k=0;k<1000;k++); P1=0;P16=1; P2=duan[hao/100%10]; for(k=0;k<1000;k++); P1=0;P17=1; P2=duan[hao%100/10]; for(k=0;k<1000;k++); P1=0;P32=1; P2=duan[hao%10]; for(k=0;k<1000;k++); P32=0;////////////////////////////////////////////////////////// }/////////////////////////////////////////////////////////// main(void){ P11=0; P12=0; P13=0; P14=0; P15=0; P16=0; P17=0; P32=0; P35=0; /////////////////////////////////////////////////////////// while(1){ wendu_1=ReadTemperature()/16;//读温度 xianshi(); ///显示系统数据/////////////////////////////////////操作函数//////////////////////////////////// if(down==0) {hao--;} if(up==0){hao++;} ///////////////////////////////////////////////////////////////////hao为理想温度/////wendu_1为实际环境温度/////////////////////////////////////////////////////////////////P35为高时 led灯工作///////////////////////////////////// P35=0; pwm=hao-wendu_1; if(pwm>0) {P35=1;} if(pwm<0) {P35=0;} if(pwm==0) {P35=0;}///////////////////////////////////////////////////////////////// }}

  • 索引序列
  • 温度检测报警系统论文
  • 无限温度检测报警系统论文
  • 温度检测报警论文
  • 温度报警系统毕业论文
  • 室温温度检测系统设计论文
  • 返回顶部