51单片机电子万年历设计带有proteus仿真

整理文档很辛苦,赏杯茶钱您下走!

免费阅读已结束,点击下载阅读编辑剩下 ...

阅读已结束,您可以下载文档离线阅读编辑

资源描述

1湖南文理学院课程设计课程名称:单片机课程设计设计题目:电子万年历教学院部:电气与信息工程学院专业班级:自动化09101班指导教师:张晓虎学生姓名:邵泽学号:200916010120完成时间:2012年6月12日报告成绩:评阅意见:评阅教师日期2摘要:电子万年历是一种非常广泛日常计时工具,对现代社会越来越流行。它可以对年、月、日、周日、时、分和秒进行计时,还具有闰年补偿等多种功能,而且DS1302的使用寿命长,误差小。对于数字电子万年历采用直观的数字显示,可以同时显示年、月、日、周日、时、分、秒等信息,还具有时间校准等功能。该电路采用AT89C52单片机作为核心,功耗小,能在3V的低压工作,电压可选用3到5V电压供电。万年历的设计过程在硬件与软件方面进行同步设计。硬件部分主要由AT89C52单片机,液晶显示电路,复位电路,时钟电路,稳压电路电路以及串口下载电路等组成。在单片机的选择上使用了AT89C52单片机,该单片机适合于许多较为复杂控制应用场合。显示器使用液晶LCD1602。软件方面主要包括日历程序、液晶驱动程序,显示程序等。程序采用汇编语言编写。所有程序编写完成后,在KeilC51软件中进行调试,确定没有问题后,在Proteus软件中嵌入单片机内进行仿真。关键词时钟电钟,DS1302,液晶LCD1602,单片机Abstract:Electroniccalendarisaveryextensivedailytimingtoolformodernsocietyismoreandmorepopular.Itcanbetoyear,month,day,Sunday,when,minutes,andsecondsforthetime,alsohasaleapyearcompensationandotherfunctions,andtheDS1302longservicelifeandsmallerror.Fordigitalelectroniccalendarusingintuitivedigitaldisplay,canalsoshowsthatyear,month,day,Sunday,whentheinformationsuchas,minutesandseconds,stillhavetimecalibrationetc.Function.TheAT89C52singlechipmicrocomputerascircuitadoptscore,powerconsumptionissmall,canbein3Voflow-pressurework,voltagecanchoose3to5Vvoltagepowersupply.Thedesignprocessofthecalendarinthehardwareandsoftwaredesignofsynchronization.MainlybyAT89C52singlechipmicrocomputerhardwarepart,liquidcrystaldisplaycircuit,resetcircuit,clockingcircuitonthecircuitcircuitandserialdownloadcircuitetc.TheprocessoronthechoiceofthesinglechipmicrocomputerAT89C52use,thesinglechipmicrocomputersuitableformanymorecomplexcontrolapplications.UseofliquidcrystaldisplayLCD1602.Softwareismainlyincludingcalendarprogram,liquidcrystaldriver,showprogram,etc.Programusingassemblylanguage.Allprogramming,afterthecompletionofKeilC51softwareincommissioning,makesureno,afterProteussoftwareembeddedinwithinthesinglechipmicrocomputersimulation.KeywordsDianZhongclock,DS1302,liquidcrystalLCD1602,microcontroller3目录1设计要求与方案论证............................................................................................................................................41.1设计要求.........................................................................................................................................................41.2系统基本方案选择和论证...............................................................................................................................41.2.1单片机芯片的选择方案和论证................................................................................................................41.2.3时钟芯片的选择方案和论证:................................................................................................................51.3电路设计最终方案决定...................................................................................................................................52系统的硬件设计与实现........................................................................................................................................52.1电路设计框图...................................................................................................................................................52.2系统硬件概述...................................................................................................................................................62.3主要单元电路的设计.......................................................................................................................................62.3.1单片机主控制模块的设计........................................................................................................................62.3.2时钟电路模块的设计................................................................................................................................72.3.3显示模块电路............................................................................................................................................82.3.4串口下载电路............................................................................................................................................92.3.5复位电路....................................................................................................................................................92.3.6稳压电路...................................................................................................................................................103系统的软件设计...................................................................................................................................................103.1程序流程框图...................................................................................................................................................113.2子程序的设计.....................................................................................................................错误!未定义书签。3.2.1读写DS1302子程序...................................................................................................错误!未定义书签。3.2.1读写LCD1602子程序.................................................................................................错误!未定义书签。4软件测试及分析...................................................................

1 / 25
下载文档,编辑使用

©2015-2020 m.777doc.com 三七文档.

备案号:鲁ICP备2024069028号-1 客服联系 QQ:2149211541

×
保存成功