基于STM32的环境监测系统的设计
基于STM32的环境监测系统的设计(论文12500字)
摘要:环境监测系统可以同时监测多种环境参数,有相对较好的市场发展前景和较高的技术应用价值。基于大多数传统的环境监测仪移动性差、体积庞大,不方便在一些严苛的环境下作业,本文设计了一个基于STM32的环境监测系统。该系统由单片机处理模块、PM2.5监测模块、温湿度监测模块、声光报警模块、液晶显示模块以及电源模块等几部分组成。该系统以STM32单片机为数据处理核心,实现了环境变量的自动测量。系统选择GJB10测量环境的PM2.5浓度,选择DHT11测量环境的温湿度,并且将数据实时显示在显示屏LCD1602上,供用户读取。该系统经调试,能够实时监测环境的各项参数,而且使用方便,对于旅游、农业、出行都能带来诸多便利,具有一定的使用价值。
关键字:温湿度;PM2.5;STM32;液晶显示器。
STM32 - based environmental monitoring system
Abstract:Environmental monitoring system can simultaneously monitor a variety of environmental parameters which possesses a relatively good market development prospects and high technical value. Based on the fact that most of the traditional environmental monitors are poorly mobile, bulky and inconvenient to operate in harsh environments, this paper designs an environment monitoring system based on STM32. The system consists of SCM processing module, PM2.5 monitoring module, temperature and humidity monitoring module, sound and light alarm module, liquid crystal display module and power module and other components. The system is based on STM32 microcontroller for data processing core and achieves the automatic measurement of environmental variables. The system chooses the PM2.5 concentration of the GJB10 as measurement environment, selects the temperature and humidity as the DHT11 measurement environment, and displays the data in real time on the display LCD1602 for the user to read. The system is debugged to monitor the parameters of the environment in real time, and it’s is easy to use, at the same time,it’s meanful for tourism, agriculture.
Keywords: Temperature and humidity; PM2.5;STM32;Liquid crystal display.
[来源:http://Doc163.com]
目 录
1 绪论.....................................................1
1.1课题研究的目的意义......................................................1
1.2国内外研究进展..........................................................1
1.3本文主要内容............................................................2
2 系统方案与系统设计.......................................3
2.1系统方案分析............................................................3
2.1.1处理器方案分析....................................................3
2.1.2电源管理方案分析..................................................3
2.1.3液晶显示屏方案分析................................................3
2.1.4 DHT11温湿度检测方案分析..........................................3
2.1.5 PM2.5浓度测试方案分析............................................3
2.1.6 蜂鸣器方案分析 ...................................................4
2.2系统设计方案............................................................4
3 硬件电路设计.............................................4
3.1处理器模块..............................................................4
3.1.1 处理器芯片STM32F103C8T6..........................................4
3.1.2晶振模块..........................................................5
3.2温湿度传感模块..........................................................6
3.3 PM2.5传感器模块........................................................6
3.3.1 PM2.5工作原理....................................................6 [资料来源:http://www.doc163.com]
3.3.2光学灰尘传感器....................................................7
3.4电源传感模块............................................................8
3.5显示电路模块............................................................9
3.5.1显示电路设计......................................................9
3.5.2 LCD1602介绍......................................................9
3.6按键模块...............................................................11
3.7报警模块...............................................................11
4 软件程序设计...........................................13
4.1软件设计方案分析.......................................................13
4.1.1开发环境方案分析.................................................13
4.1.2程序设计方案分析.................................................13
4.2系统总流程图...........................................................14
4.3按键模块程序设计.......................................................15 [资料来源:https://www.doc163.com]
4.4显示模块程序设计.......................................................15
4.5基于状态机的按键消抖算法...............................................16
4.6报警模块程序设计.......................................................18
4.7温湿度模块程序设计.....................................................19
5 系统调试及分析..........................................19
5.1 硬件的检测............................................................19
5.2 软件硬件整体调试......................................................22
6 总结与展望..............................................22
参考文献..................................................23
附录......................................................25 [资料来源:http://doc163.com]