设计说明书
总字数:20000+
摘要
在售货商店的日常运营中,环境质量的稳定与安全直接影响商品保存质量、顾客购物体验及店铺运营安全。温湿度异常可能导致商品变质,烟雾和有害气体泄漏存在安全隐患,照明不合理则会增加能耗,而客流统计对经营策略制定至关重要。因此,研发一套能实时监测、智能调控且便于管理的商店环境监控系统具有重要现实意义。
本设计提出一种基于 STM32F103C8T6 单片机的售货商店环境监控系统。系统主要功能包括:通过DHT11 温湿度传感器检测店内温湿度,当温度低于设置最小值时控制加热设备启动,高于最大值时触发降温设备,湿度高于最大值时启动除湿装置;借助MQ-2 烟雾传感器监测烟雾浓度,当浓度超过设定最大值时,自动开启风扇通风并触发声光报警;通过SGP30 气体传感器检测 CO₂浓度,当浓度高于最大值时启动风扇进行通风换气;利用D203S 人体监测模块判断店内是否有人,结合5516 光照模块检测的光照值自动调节灯光亮度,实现无人时低亮度节能、有人时合理照明的控制逻辑;通过两组HWJS 分离式红外对射管实时监测进入店铺的人数;支持通过按键手动设置各环境参数阈值,并能手动控制各继电器状态;通过OLED 显示屏实时显示温湿度、烟雾浓度、CO₂浓度、光照值及客流数据等测量信息;同时,系统通过ESP8266 WIFI 模块将测量数据发送至手机端,手机端可远程设置各参数阈值,还能远程控制各继电器的工作状态。
该售货商店环境监控系统的作用在于,为商店提供了全方位、自动化的环境管理解决方案。通过实时监测与智能调控,既能保障商品存储环境稳定、降低安全风险,又能实现节能降耗,同时通过数据可视化和远程控制功能,提升了店铺管理的便捷性与效率,为优化经营决策提供数据支持。
关键词:单片机;环境监控;传感器;智能调控;远程监测
A Sales Store Environment Monitoring System Based on Single Chip Microcomputer
Abstract
In the daily operation of a sales store, the stability and safety of environmental quality directly affect the quality of product preservation, customer shopping experience, and store operation safety. Abnormal temperature and humidity may cause product deterioration, and there are safety hazards such as smoke and harmful gas leaks. Improper lighting can increase energy consumption, and passenger flow statistics are crucial for developing business strategies. Therefore, developing a store environment monitoring system that can monitor in real-time, intelligently regulate, and is easy to manage has significant practical significance.
This design proposes a sales store environment monitoring system based on STM32F103C8T6 microcontroller. The main functions of the system include: detecting the temperature and humidity inside the store through the DHT11 temperature and humidity sensor, controlling the heating equipment to start when the temperature is below the set minimum value, triggering the cooling equipment when it is above the maximum value, and starting the dehumidification device when the humidity is above the maximum value; Using MQ-2 smoke sensor to monitor smoke concentration, when the concentration exceeds the set maximum value, the fan will automatically turn on for ventilation and trigger an audible and visual alarm; Detect CO ₂ concentration through SGP30 gas sensor, and start the fan for ventilation when the concentration is higher than the maximum value; Using the D203S human monitoring module to determine if there are people in the store, combined with the light value detected by the 5516 lighting module, the brightness of the lights is automatically adjusted to achieve the control logic of low brightness energy saving when no one is present and reasonable lighting when there are people present; Real time monitoring of the number of people entering the store through two sets of HWJS separated infrared tubes; Support manual setting of various environmental parameter thresholds through buttons, and the ability to manually control the status of various relays; Real time display of measurement information such as temperature and humidity, smoke concentration, CO ₂ concentration, lighting value, and passenger flow data through OLED display screen; At the same time, the system sends measurement data to the mobile phone through the ESP8266 WIFI module, which can remotely set various parameter thresholds and control the working status of various relays.
The purpose of the environmental monitoring system for this sales store is to provide a comprehensive and automated environmental management solution for the store. Through real-time monitoring and intelligent regulation, it can ensure stable storage environment for goods, reduce security risks, and achieve energy conservation and consumption reduction. At the same time, through data visualization and remote control functions, it improves the convenience and efficiency of store management, providing data support for optimizing business decisions.
Keywords:microcontroller; Environmental monitoring; Sensors; Intelligent regulation; Remote Monitoring
目 录
1 绪论
1.1 研究背景及意义
1.2 国内外研究现状
1.3 主要内容
2 系统总体方案设计
2.1系统总体设计
2.2 主要模块方案选择
3 系统硬件设计
3.1 总体硬件框架
3.2 主控模块电路设计
3.3 环境检测模块电路设计
3.4 显示模块电路设计
3.5 按键模块电路设计
3.6 声光报警与继电器控制模块电路设计
3.7 通信模块电路设计
3.8 照明灯模块电路设计
4 系统程序设计
4.1 编程软件介绍
4.2 系统主流程设计
4.3 独立按键
4.4 OLED显示流程设计
4.5 温湿度检测模块子流程
4.6 ADC模数转换子流程设计
4.7 SGP30模块子流程设计
4.8 WiFi模块子流程设计
5 实物制作与功能测试
5.1 实物制作
5.2 温湿度检测与调控功能测试
5.3 烟雾与 CO₂检测功能测试
5.4 人体监测功能测试
5.5 光照检测与照明调节功能测试
5.6 客流统计功能测试
5.7 按键交互功能测试
5.8 显示功能测试
5.9 WiFi 远程功能测试
6 总结
参考文献
致谢
附录A 原理图
附录B PCB
附录C 主程序
购买后可查看具体内容!