摘要
随着互联网的快速发展,网络智能化已经应用在生活的方方面面。物联网发展了近20多年,得力于无线通讯行业的快速发展,手机和电脑以此为媒介进行数据传输。我以ESP32wifi蓝牙模块为主要芯片,设计了一个物联网小型气象站,包含有ESP32模块、太阳能充电电路、手机APP、温湿度传感器、紫外线传感器、光照强度传感器、风向、风速等传感器数据采集模块,通过ESP32模块将这些传感器采集的数据发送到手机或者电脑上。
随着气象科技和业务的快速发展,气象观测越来越趋于自动化。局部区域天气变幻无常,网络上的天气预报不会实时告知身边的天气情况,新型的气象站正在向着小型化、简单化、易操作,低成本方向发展,为了降低成本,实现远程信息采集,我设计了一种太阳能和锂电池互补的供电系统的小型气象站,供电系统可以让气象站随时保持正常工作,实时传输气象数据,可以让监控人员实时查看气象站的气象信息,为人民生活出行提供良好的保障以及可以随时了解气象站所在地的各项环境信息。
关键词:自动气象站,数据采集,物联网,自动化
ABSTRACT
With the rapid development of the Internet, network intelligence has been applied to all aspects of life. The Internet of Things has developed for more than 20 years, thanks to the rapid development of the wireless communication industry. Mobile phones and computers use this as a medium for data transmission. I designed a small IoT weather station with ESP32wifi Bluetooth module as the main chip, including ESP32 module, solar charging circuit, mobile APP, temperature and humidity sensor, ultraviolet sensor, light intensity sensor, wind direction, wind speed and other sensor data acquisition modules. The data collected by these sensors is sent to the mobile phone or computer through the ESP32 module.
With the rapid development of meteorological technology and business, meteorological observations are becoming more and more automated. The weather in local areas is fickle, and the weather forecast on the network will not inform the weather conditions around you in real time. The new weather station is developing towards miniaturization, simplicity, ease of operation, and low cost. In order to reduce costs and realize remote information collection, I A small weather station with a complementary power supply system of solar energy and lithium batteries is designed. The power supply system can keep the weather station in normal operation at any time, transmit meteorological data in real time, and allow monitoring personnel to view the weather information of the weather station in real time, providing people's life and travel. Good guarantee and can keep abreast of various environmental information where the weather station is located.
Keywords: automatic weather station, data collection, internet of things, automation
目录
1、引言 8
2、自动气象站硬件设计与实现 8
2.1气象站采集器硬件设计框架 8
2.2嵌入式微处理器最小系统设计 9
2.3 气象数据采集模块硬件电路设计 11
2.3.1电源模块电路硬件设计 11
2.3.2温湿度传感器模块电路设计 11
2.3.3紫外线传感器模块电路设计 13
2.3.4光照强度传感器模块电路设计 15
2.3.5风速传感器模块电路设计 15
2.3.6风向传感器模块电路设计 17
2.3.7雨量传感器模块电路设计 18
2.3.8外部温度传感器模块电路设计 19
2.4气象站系统通信模块电路设计 19
2.5气象站系统硬件电路实现 20
3、自动气象站软件设计与实现 21
3.1软件总体设计 21
3.2传感器数据采集程序设计与实现 21
3.2.1温湿度驱动代码 21
3.2.2紫外线驱动代码 23
3.2.3光照强度驱动代码 24
3.2.4风速传感器驱动代码 26
3.2.5风向传感器驱动代码 27
3.2.6雨量传感器驱动代码 29
3.2.7外部温度传感器驱动代码 29
3.3气象站系统通信协议与软件简介 30
3.3.1系统通信协议设计 30
3.3.2软件简介 30
4、自动气象站数据显示 31
4.1将传感器数据上传到 ThingSpeak 31
4.2将传感器数据上传到Blynk软件 32
总结 34
参考文献 35
致谢 36