摘要随着科技发展和人民生活水平的提高,大家对公路的重视度越来越高。
每年发生的交通事故都很多,所以减少交通事故发生是我们现在重点讨论的问题。
在公路上路灯起了照明作用,大大减少了因为视野视线问题发生的问题,可是一些很少车辆经过的路段就会浪费了一些资源,所以模拟路灯控制系统就是为了研究节能与安全的话题,它既可以在无车辆经过时节省资源,另一方面又可以在来车辆时候提供照明作用。
是一个非常实用的课题。
本文首先介绍了一种新型的控制系统,基于ZigBee技术的路灯智能控制系统,分析了它的技术特点及其应用,并分析了本设计设计的ZigBee技术路灯控制系统可以实现的功能。
其次根据设计要求,先画出了设计系统的总体框图,它的总体框图包括:PC监控系统、网路协调器、ZigBee终端节点、微波检测电路、光强检测电路、路灯直接控制电路。
其次根据总体框图分别设计了各个部分的硬件。
然后对设计的系统进行了软件部分的设计,设计的程序包括:系统流程图路灯检测流程图、模拟路灯控制系统液晶显示程序、实时监测流程图、人工控制模式、时钟电路流程图、按键流程图、按键扫描流程图。
最后根据设计的系统,运用PROTUES软件对系统进行了仿真调试,仿真的结果显示系统的设计满足设计要求。
关键词:Zigbee技术;LED路灯;设计ABSTRACTWith the development of science and technology and the improvement of people's living standard, people pay more and more attention to the road. There are a lot of traffic accidents every year, so it is our focus to reduce the traffic accident. In highway road lamp lighting, greatly reducing the problem because of the horizon line of sight problem, but some very few vehicles through the road will waste resources, so the simulation street lamp control system is in order to study energy saving and safety topics, it can in the vehicle after the season, resources, on the other hand can provide lighting effect in the vehicle when. Is a very practical subject.This paper introduces the application of a simulated street lamp control system, using the technology of the single chip microcomputer, which is used to realize the intelligent control of the analog street lamp. The control system has set the timing function of street lamp, also can be independently controlled street lamp turn-on and turn off; can also have a dimming function, on the road of light adjusted can also be in accordance with the requirements as set out in the street driving power output in the range of 20% - 100% adjusting. During the day mode, but also according to changes in the environment of light and shade to control the opening and closing of street lights, in the case of the night mode, according to the traffic road conditions automatically switch lights. When the lamp fails, it can detect and alarm by sound and light system. The scheme takes the chip ATS8952 as the core, and the peripheral circuit is simple, and the whole technical content of the analog street lamp control system is realized. STC microcontroller in recent years more and more widely used, because of its strong anti-interference ability, good stability, cost-effective, and therefore is the first choice for low cost street lamp control solutions. The control system in addition to the use of low-cost chip, but also the use of low-cost infrared sensor, greatly reducing the cost of the system. The circuit of the whole system is simple, the structure is compact, the power source is driven only by the transformer and the three terminal voltage regulator, the addition of a little filter capacitor can achieve a stable power output. After many tests, it is proved that the system can work stably for a long time, and can meet the design requirements completely.Keywords: Simulate controlling; LED lighting; Single-chip microcomputer目录1 绪论 (1)1.1 课题的背景与意义 (1)1.2 国内外的发展现状 (1)1.3本文研究主要的内容 (2)2 基于ZigBee的路灯控制系统的设计 (3)2.1 控制系统的总体框架 (3)2.2 ZigBee技术及其应用 (4)2.2.1 ZigBee技术概述 (4)2.2.2 ZigBee技术的特点 (4)2.2.2 ZigBee技术的应用 (5)2.3 本设计实现的功能 (6)3 ZigBee技术开发的硬件平台 (7)3.1无线通信芯片的选择 (7)3.2 CC2430芯片介绍 (7)3.2.1 I/O端口线引脚功能 (8)3.2.2 CC2430芯片电源线引脚功能 (9)3.2.3 控制线引脚功能 (9)3.3 CC2430芯片典型应用电路 (10)3.4 Zigbee天线系统设计 (10)3.5 RS232(DB9)MAX232 (11)3.5.1 RS232 (DB9)引脚定义 (11)3.5.2 MAX232原理 (11)3.6 GPRS模块解决方案 (12)4 路灯监控系统的硬件设计 (13)4.1 终端硬件电路的设计与实现 (13)4.2 各个分电路的硬件设计 (14)4.2.1 直流稳压电源的供电电路设计 (14)4.2.2 光敏检测电路 (15)4.2.3微波检测电路 (15)4.2.4路灯控制模块 (16)图11 路灯控制驱动电路 (17)5 模拟路灯控制系统软件设计 (18)5.1 软件的设计思路 (18)5.2 系统主程序流程图 (18)5.2.1 系统流程图 (18)5.2.2模拟路灯检测电路 (19)5.2.2 模拟路灯控制系统液晶显示程序 (20)5.2.3 实时监测流程图 (20)5.2.4人工控制模式 (21)5.2.5 时钟电路流程图 (22)5.2.6 按键流程图 (22)5.2.7 按键扫描流程图 (23)5.2.8 故障报警程序 (24)6 基于PROTEUS对设计系统仿真 (25)6.1 仿真软件PROREUS的介绍 (25)6.2 模拟路灯控制仿真模型的建立 (25)6.3 模拟路灯控制不同模式下的仿真 (26)6.3.1 定时模式仿真 (26)6.3.2 光强控制模式仿真 (27)6.3.3 路灯故障检测模式仿真 (27)6.5 仿真结果分析 (28)结束语 (29)参考文献 (30)致谢................................................. 错误!未定义书签。
附录1 程序代码.. (32)附录 2 硬件原理图 (45)附录3 PCB图(部分) (46)1 绪论1.1 课题的背景与意义在如今社会如此现代的情况下,科技发展更可谓一日千里。
而能源问题在当今世界上是一个必须要解决的大问题,在有限的资源下,要考虑到如何节能和寻找其他资源代替显得尤其重要。
照明工程迅猛发展,其路灯数量的增大,而且功耗和性能大大提高,因而对路灯定时控制的要求较精确。
路灯开关灯控制方法多为“钟控”和“光控”。
“钟控”不适应天气突变与季节变化等自然情况从而会出现:开灯早,关灯晚;或者开灯晚,关灯早的现象。
前者会造成巨大的电能浪费,后者会损害城市形象、影响社会治安和交通安全,从而影响城市的投资环境。