基于GSM网络的远程监控系统设计
院 系 专 业 班 级 学 号 姓 名 指导教师 负责教师
计算机学院 计算机科学与技术
84010102 20080401010xx
张维君
沈阳航空航天大学
2012年6月
沈阳航空航天大学毕业设计(论文)
摘 要
该设计是采用STC89C52单片机实现的基于GSM网络SMS短消息功能的家庭防火报警系统。该系统主要由单片机STC89C52、TC35模块、DS18B20温度传感器、蜂鸣器报警器、数码显示管,其它基本外围电路组成。借助最可靠、最成熟的GSM移动网络,以最直观的短消息,直接把报警地点的情况反映到所设定的手机屏幕上。
该系统通过传感器检测家庭安全隐患,把检测结果送入单片机,通过单片机控制GSM Modem向预先设定好的手机号码发送报警信号。同时配备蜂鸣报警器发出警报声,以及数码显示管显示现场当前的温度。
该设计融合了通信技术、计算机技术、测试技术、家庭安防技术等多个学科。是一个涉及电子、通信、计算机软硬件的综合应用系统。设计的系统运行稳定,性能良好,具有一定的应用前景。
关键词:GSM通信;远程监控;报警;STC89C52
I
沈阳航空航天大学毕业设计(论文)
Abstract
The design using MCU STC89C52 is a family fire alarm system which is based on the GSM network SMS messaging function. The system mainly consists of MCU STC89C52, module of TC35, DS18B20 temperature sensor, buzzer alarm, digital display tubes and other basic peripheral circuit. With the most reliable, most mature GSM mobile network and the most intuitive message, it reflects the situation of the alarm location to set on the phone screen directly.
The system detects the home security risks through sensor, puts the test results into the MCU and controls the GSM Modem through the MCU to send alarm signals to the predefined phone number. At the same time, it is equipped with a buzzer alarm warning sound, and digital display tube displays current temperature.
The design combines communications technology, computer technology, testing technology, home security technology disciplines involved in electronics, and it is a comprehensive applications system which involve communications, computer hardware and software, the design of the system is running stable, good performance and with a certain application prospects .
Keywords: GSM Communication; Remote monitoring; Alarm; STC89C52
II
沈阳航空航天大学毕业设计(论文)
目 录
1 绪论 ................................................................................................................................... 1 1.1 开发背景及意义 ........................................................................................................ 1 1.2 国内外研究现状 ........................................................................................................ 1 1.3 内容概述 .................................................................................................................... 2 2 方案选择和论证 ............................................................................................................... 3 2.1 方案1—基于8031单片机的防盗报警监控系统设计 ........................................... 3 2.2 方案2—基于GSM网络的远程监控设计 .............................................................. 4 2.3 系统设计工具 ............................................................................................................ 5 2.4 技术经济分析 ............................................................................................................ 6 2.4.1 技术性分析 .......................................................................................................... 6 2.4.2 经济性分析 .......................................................................................................... 6 3 硬件系统设计 ................................................................................................................... 7 3.1 核心单元STC89C52模块 ........................................................................................ 7 3.1.1 STC89C52单片机概述 ........................................................................................ 8 3.1.2 STC89C52单片机特性 ........................................................................................ 8 3.1.3 STC89C52引脚和封装 ........................................................................................ 9 3.2 GSM无线通信模块—TC35 .................................................................................... 10 3.2.1 TC35使用技巧 ................................................................................................... 11 3.2.2 AT指令说明 ....................................................................................................... 11 3.2.3 SIM卡 ................................................................................................................. 11 3.2.4 RS232-串行接口 ................................................................................................. 12 3.3 温度采集模块 .......................................................................................................... 14 3.4 数码管显示模块 ...................................................................................................... 17 3.5 蜂鸣器报警模块 ...................................................................................................... 17 4 软件系统实现 ................................................................................................................. 19 4.1 主程序流程图 .......................................................................................................... 19 4.2 温度子程序设计 ...................................................................................................... 20
III
沈阳航空航天大学毕业设计(论文)
4.3 短信发送流程图 ...................................................................................................... 21 4.4 短信接收流程图 ...................................................................................................... 22 4.5 数码管显示子程序 .................................................................................................. 23 5 系统调试 ......................................................................................................................... 24 5.1 硬件测试 .................................................................................................................. 24 5.1.1 静态调试 ............................................................................................................ 24 5.1.2 联机调试 ............................................................................................................ 24 5.2 软件测试 .................................................................................................................. 25 5.3 系统调试 .................................................................................................................. 25 6 测试结果 ......................................................................................................................... 26 结 论 ................................................................................................................................... 27 参考文献 ............................................................................................................................. 28 致 谢 ................................................................................................................................. 29
IV