网站大量收购独家精品文档,联系QQ:2885784924

单片机的简单交通灯控制设计.doc

  1. 1、本文档共32页,可阅读全部内容。
  2. 2、有哪些信誉好的足球投注网站(book118)网站文档一经付费(服务费),不意味着购买了该文档的版权,仅供个人/单位学习、研究之用,不得用于商业用途,未经授权,严禁复制、发行、汇编、翻译或者网络传播等,侵权必究。
  3. 3、本站所有内容均由合作方或网友上传,本站不对文档的完整性、权威性及其观点立场正确性做任何保证或承诺!文档内容仅供研究参考,付费前请自行鉴别。如您付费,意味着您自己接受本站规则且自行承担风险,本站不退款、不进行额外附加服务;查看《如何避免下载的几个坑》。如果您已付费下载过本站文档,您可以点击 这里二次下载
  4. 4、如文档侵犯商业秘密、侵犯著作权、侵犯人身权等,请点击“版权申诉”(推荐),也可以打举报电话:400-050-0827(电话支持时间:9:00-18:30)。
查看更多
单片机的简单交通灯控制设计

摘 要 采用单片机,设计交通灯控制实现了通过芯片的P1口设置红、绿灯亮的功能输出显示时间在对系统功能分析的基础上,提出了三种设计方案,经比较,选择性能较优的LED动态循环显示方案进行了设计。设计包括硬件和软件两大部分。硬件包括单片机、时间显示、交通灯显示部分。选用Atmel公司的AT89S5单片机作为控制核心东西南北四个方向设置了LED时间显示和交通灯显示时间显示采用位LED显示器,交通灯显示则采用红绿色高亮发光二极管来模拟。软件采用了模块化的设计方法,主要分为主程序、定时器中断服务子程序、倒计时显示子程序、交通灯模拟显示子程序四部分。关键词: 交通灯;单片机;AT89S5 Abstract Traffic light control system based on SCM (Single Chip Microcomputer) is designed in this paper. System requires that MCS-51 series SCM is used as CPU. Traffic light control system should be designed and made .There are four groups light which indicate to turn left, turn right, and go straight ahead and pedestrian access in east, west, north and south four directions. Timer shows traffic conversion remainder time. When special vehicles, such as 119,120 go through, the system can automatically allow special vehicles running and other vehicles is prohibited. Based on analysis of the system functions, three schemes are put forward .By comparison, LED dynamic cycle display scheme has better functions and it is selected to be designed. The design includes hardware part and software part. Hardware has three parts .They are SCM system, LED time display, traffic lights. AT89S51 SCM is selected as control CPU. LED display and traffic lights are set in east, west, north and south four directions. Three LED monitors are used to show time. Highlight and red-green two color traffic lights are used as traffic lights. Software is designed by module. It is divided into main program, timer interrupting service subroutine, LED display subroutine, traffic display subroutine. Key words: Traffic light; SCM; AT89S51 目录 摘 要 I 1、绪 论 1 1.1 课题背景 1 1.1.1课题研究的意义 1 1.1.2课题研究的动态 1 1.2 课题内容 2 1.2.1课题研究的主要内容 2 1.2.2预期达到的成果 2 2、系统工作原理及设计方案 3 2.1 设计原理 3 2.2方案论证 4 2.2.1 显示界面方案 4 2.3 单片机概述 5 3、硬件电路的设计 8 3.1 时钟电路和复位电路 8 3.1.1时钟电路 8 3.2.2复位电路 8 3.2控制模块 9 3.3 信号灯模块 10 3.4显示模块 11 3.4.1数码管介绍 11 3.4.2 LED显示器的显示方法 12 3.5 报警模块 13 3.6按键模块 13 4、程序设计与流程图 15 4.1主程序模块 15 4.2信号灯模块 15 4.3 显示模块 16 4.4 中断服务模块 19 结

文档评论(0)

2017meng + 关注
实名认证
内容提供者

该用户很懒,什么也没介绍

1亿VIP精品文档

相关文档