基于单片机的温湿度监测系统
2017-10-17刘娟花杨幸芳
刘娟花 杨幸芳
摘 要: 采用AT89S52单片机和SHT11数字温湿度传感器构成成本低廉的温湿度监测系统。由AT89S52单片机将采集到的数据处理后发送到1602液晶显示器显示,同时当温度或湿度超过设定的上限或下限值时由发光二极管与蜂鸣器产生声光报警。系统结构简单、成本低廉、抗干扰能力强、适用范围广、功耗较低,符合仪器仪表小型化的潮流,为智能化的微型温湿度监测系统的开发与研究奠定了良好的基础。
关键词: 单片机; SHT11; LCD1602; 报警
中图分类号: TN931+.3?34; TP368 文献标识码: A 文章编号: 1004?373X(2017)20?0165?04
Abstract: The AT89S52 MCU and SHT11 digital temperature?humidity sensor are used to construct a temperature?humidity monitoring system with low cost. The data acquired and processed by 52?MCU is sent to LCD1602 for displaying. If the value of temperature or humidity exceeds the set valves, the sound and light alarms are generated by LED and buzzer. The system has simple structure, low cost, strong anti?interference ability, wide application range and low power consumption, and conforms to the trend of the instrument miniaturization, which lays the good foundations for the research and development of the intelligent micro temperature?humidity monitoring system.
Keywords: microcontroller; SHT11; LCD1602; alarm
现代检测技术中温湿度测量占据着重要的位置,如何快速、准确地测量温湿度受到各行各业的重视。随着电子工业和计算机技术的发展,现代检测技术也在向自动化、智能化和数字化方向发展。近年来,利用微型机控制的数字化在线温湿度检测已成为温湿度检测技术方面的发展趋势。本文介绍的温湿度监测系统,以微型机AT89S52为基础搭建数字温湿度传感器SHT11构成一种结构简单、测量准确、价格低廉、稳定可靠的智能化温湿度检测系统,可广泛地应用于实际生产生活中。
1 系统硬件设计
本系统硬件部分由以下几个模块组成[1?2]:AT89S52单片机控制模块、温湿度采集模块、键盘设置模块、时钟模块、LCD显示模块、报警模块以及其他辅助模块。系统实现的功能为:单片机处理SHT11传感器采集到的数据,并控制液晶显示器显示出实时温度和湿度,同时当温度或湿度超过设定的上限或下限值时产生声光报警。……
