基于MSP430单片机监测环境温湿度以及二氧化碳浓度毕设.docx
《基于MSP430单片机监测环境温湿度以及二氧化碳浓度毕设.docx》由会员分享,可在线阅读,更多相关《基于MSP430单片机监测环境温湿度以及二氧化碳浓度毕设.docx(78页珍藏版)》请在三一办公上搜索。
1、目录设计总说明General Description of Construction Design第1章 绪论71.1 研究的目的及意义71.2 国内外研究的情况71.3 系统的主要性能指标和工作任务81.4 方案论证9第2章 工具简介112.1 C语言112.2 IAR软件11第3章 硬件设计163.1 主控芯片的介绍163.1.1 MSP430F149的工作方式173.1.2 P口介绍183.1.3 MSP430指令的介绍223.1.4 MSP430中断介绍和存储器断介绍243.1.5 MSP430定时器263.1.6 时钟模块283.1.7 比较器模块293.1.8 模数转换模块303.
2、2 电源电路的设计303.3 晶振和复位电路以及USB下载电路的设计343.4 液晶显示模块LCD12864363.5 时钟芯片 DS1302383.5.1 DS1302 的基本组成和工作原理393.5.2 DS1302 内部寄存器403.6 温湿度芯片433.7 二氧化碳气体传感器473.7.1 二氧化碳浓度传感器TGS4160概述473.7.2 TGS4160的内部结构473.7.3 TGS4160的工作原理483.7.4 二氧化碳检测电路设计493.8 超限控制处理模块50第4章 软件设计524.1 程序的流程图设计524.1.1 主程序设计流程图524.1.2 温湿度和气体采集及处理框
3、图614.1.3 LCD12864显示流程图69第5章 调试与体会735.1 调试过程735.2总结体会74致谢75参考文献77婴儿室环境监测电路的设计设计总说明随着科技的飞速发展和普及,高性能设备越来越多,各行各业对温湿度的要求也越来越高。对于刚出生的婴儿,刚脱离母体进入新环境,对新环境温湿度的要求同样也很高。传统的温湿度监测模式是以人为基础,依靠人工轮流值班,人工巡回查看等方式来测量和记录环境状况信息。在这种模式下,不仅效率低下不利于人才资源的充分利用,而且缺乏科学性,许多重大事故都是由人为因素造成的,人工维护缺乏完整的管理系统。而问世监控系统就可以解决这样人才资源浪费,管理不及时的问题,
4、这是由于它的智能化设计所决定的。温度湿度和气体的浓度在工农业生产、气象、环保、国防、科研等部门有着至关重要的作用,准确测量温湿度在生物制药、食品加工、造纸等行业更是至关重要。因此研究温湿度的测量和控制方法具有重要的意义。本设计核心部件为超低功耗嵌入式单片机MSP430,信号采集及处理部分由SHT11以及二氧化碳传感器GTS4160构成,输出的信号通过AD转换和MSP430的处理在显示器上显示温湿度以及气体的浓度,信号显示采用的是液晶屏点阵显示器LCD12684,其他组成部分为实时时钟发生电路,产生与现在相同的时间和具体日期,也是通过LCD12864液晶模块显示。超限处理模块是使用PID算法设计
5、,使用单片机的引脚电平通过继电器来控制温湿度,和CO2气体浓度。本设计还接入了故障报警模块。MSP430是嵌入式单片机具有高度的集成化,有看门狗定时电路,比较器,模数转换等功能,与51系列单片机比较具有超低功耗,端口多等优点;SHT11温湿度传感器测温范围为-40+1238,精度01,湿度测量范围是099RH,分辨率为003 RH,完全可以满足设计要求的温度2027,湿度3050RH,它为I2C总线连接通信,较其他产品具有品质卓越,超快相应,抗干扰能力强,超高的性价比有点。GTS4160一种含热敏电阻的混合式CO2敏感元件,它使用的时候一般都配有本产品公司专门配套生产的一个转换和测量模块AM-
6、4模块,模块是数字量串行输出,相比其他CO2气体传感器操作简单,精度高。在软件设计部分有对测量的温湿度进行上下值的设定,当测量超过限定值时,通过超限自动控制调节温湿度电气处理电路对其进行处理,分别动作为过冷制热,过热制冷,过湿除湿,过干加湿,和对气体浓度调节,硬件中包括一个开关,为复位开关。开机后,所有器件初始化,LCD12864产生实时时间和日期,温湿度传感器SHT11和CO2传感器开始进行温湿度测量和计算,最后通过LCD液晶显示器显示结果。在测量结果中有超过设定的温湿度上下限的,通过超限模块做出反应。电路主要包括了MSP430控制模块、SHT11温湿度测量模块、二氧化碳检测模块TGS416
7、0、DS1302时间模块、LCD显示模块、超限继电器处理模块。其他是一些附件,比如复位、晶振电路。 关键字:MSP430149;SHT11;TGS4160;DS1302;继电器;LCD12864The babys room environmental monitoring circuit designGeneral Description of Construction DesignWith the rapid development and popularization of science and technology, high-performance equipment more an
8、d more, all walks of life to the temperature and humidity requirements more and more is also high. For a newborn baby, just from the mother into the new environment, also to the requirement of the new environment temperature and humidity is high. Traditional temperature and humidity monitoring model
9、 is based on people, rely on artificial turn on each other, artificial circuit to check the information to measure and record environmental conditions such as way. In this mode, not only low efficiency for better utilization of talent resources, and lack of scientific nature, many major accidents ar
10、e caused by human factors, artificial maintenance of the lack of a complete management system. Appeared and monitoring and control system can solve such waste of talent resources,management is not timely issue, it is because of its intelligent design decisions. Temperature, humidity and gas concentr
11、ation in industrial and agricultural production, weather, environmental protection, national defense, scientific research departments have a vital role, accurate measurement of temperature and humidity in the bio-pharmaceutical, food processing, papermaking and other industries is vital. So the temp
12、erature and humidity measurement and control method has the vital significance.This design for ultra-low power embedded microcontroller MSP430 core components, signal acquisition and processing part consists of SHT11 GTS4160 and carbon dioxide sensor, the output signal through the AD conversion and
13、the processing of MSP430 displayed on the monitor temperature and humidity and gas concentration, signal display USES LCD lattice display LCD12684, other components for the real time clock generating circuit, and the same time and date right now, is through the LCD12864 LCD module display. Transfini
14、te processing module design is the use of PID algorithm, using MCU pin level through the relay to control the temperature and humidity, and CO2 gas concentration. This design also access the fault alarm module.Embedded microcontroller MSP430 is highly integrated, a watchdog timer circuit, comparator
15、, modulus conversion, and other functions, compared with 51 series microcontroller with ultra-low power consumption, port number, etc; SHT11 temperature and humidity sensor measuring temperature range of - 123.8 + 40, the precision of 0.1 , humidity measurement range is 0 99% RH, a resolution of 0.0
16、3 RH, can completely meet the design requirements of the temperature of 20 27 , humidity is 30 50% RH, it for the I2C bus connection communication, compared to other products with excellent quality, super fast, strong anti-jamming capability, high performance to price ratio is a little bit. GTS4160
17、a hybrid CO2 containing thermistor sensor, it USES generally equipped with this product the company specialized production of form a complete set of a transformation AM - 4 module and measuring module, serial output module is the digital quantity, compared to other CO2 gas sensor is simple, high pre
18、cision.This design implementation is single chip microcomputer temperature and humidity measurement and control system, through the LCD display the measured temperature and humidity. Set temperature and humidity sensor and A/D converter is adopted in the system in the integration of SHT11 chip and T
19、GS4160 carbon dioxide gas concentration detection chip, through single chip microcomputer for processing, according to the date of other modules including the real time clock generating circuit and transfinite relay processing circuit, to measure the value of the real-time display and automatically
20、adjust the processing of the necessary. Introduced in this paper based on the Texas instruments MSP430 series MCU real-time temperature and humidity measurement and control system and display system design, including hardware structure principle is introduced, and analysis the corresponding software
21、 design and its key points, including the software design process and its implementation of the program. System structure is simple and practical, and improves the measurement precision and efficiency.Key words:MSP430F149 ; SHT11; TGS4160; DS1302; Relay; LCD12864第1章 绪论1.1 研究的目的及意义温度和湿度以及适应环境所需的各种气体的
22、浓度与人们的生活息息相关。在工农业生产、气象、环保、国防、科研等部门,经常需要对环境温度与湿度和气体浓度进行测量及控制。准确测量温湿度和相关气体浓度在生物制药、食品加工、造纸等行业都是至关重要的。传统的温度计是用水银柱来显示的,它的精确度不高,不易读数。而采用单片机对温湿度及气体进行控制,不仅具有控制方便、简单和灵活等优点,而且可以大幅度提高气体及温湿度控制的技术指标。用LCD来显示温湿度和气体浓度的数字量看起来更加人性化更加直观。采用SHT11数字温湿度传感器作为检测元件,能够同时测试温度和湿度。SHT11传感器可以直接读出被测的温湿度值。同时单片机可以把测量出的数据通过串口传到计算机上,来
23、完成工业中的自动控制,给工业生产带来了极大的便利。用单片机控制的温湿度计不仅硬件电路简单,而且测量精度比较高。用液晶显示测量值看起来比较美观。采用MG811二氧化碳气体浓度检测传元件,直接把空气中的二氧化碳通过化学量的变化,以及模数转换也能直接送到单片机里面进行处理,监测空气中二氧化碳的浓度,调节空气中氧气的含量,给人或者需要贮存的动植物等一个更舒适的环境。无论在日常生活中还是在工业、农业方面都离不开对周围环境进行温湿度及周边异常气体含量的的测量。因此,研究温湿度的测量具有非常重要的意义。1.2 国内外研究的情况测量温湿度和气体浓度的的关键是温湿度传感器。过去测量温度与湿度是分开的。随着技术的
- 配套讲稿:
如PPT文件的首页显示word图标,表示该PPT已包含配套word讲稿。双击word图标可打开word文档。
- 特殊限制:
部分文档作品中含有的国旗、国徽等图片,仅作为作品整体效果示例展示,禁止商用。设计者仅对作品中独创性部分享有著作权。
- 关 键 词:
- 基于 MSP430 单片机 监测 环境 温湿度 以及 二氧化碳 浓度
![提示](https://www.31ppt.com/images/bang_tan.gif)
链接地址:https://www.31ppt.com/p-1906071.html