电子万年历毕业设计(基于AT89C51单片机和DS1302时钟芯片) - 图文 下载本文

***********************

*************学校

毕业设计论文

论文题目:电子万年历

系 部: 自动控制系 专 业: 自动化 班 级: 2007级03班 学生姓名: *** 学 号: 071413318 指导教师: 徐海刚

2010年 4月 15 日

- 1 -

***********************

摘要 ….…………………………………………………………………….……………3 绪论 …….….……………………………………………………………….……………5 第1章 设计要求与方案论证…….………….………………………………7

1.1 引言…….……………………………………………………………….……………7 1.2 功能要求.…………………………..……………………………….………………7 1.3方案论证…….………………………………………………………..………………7

目 录

第2章 系统硬件电路设计 …….…………………………….………………11

2.1 电路设计…….………………………………………………………….…………11 2.2 系统硬件概述…….……………………………………………………………15 2.3主要单元电路的设计…….………………………………………………………15

第3章 系统的软件设计…….………………………………….……………22

3.1程序设计…….……………………………………………………………………22 3.2程序设计流程图…….……………………………………………………………22

第4章 结束语…….….………………………………………….……………24 参考文献…….……………………………………………………………………….26 附录一(电路原理图)…… ……………………………………..…………… 附录二(程序清单)…….…………………………………………………………27

- 2 -

***********************

摘要

随着社会、科技的发展,人类得知时间,从观太阳、摆钟到现在电子钟,不断研究、创新。为了在观测时间的同时,能够了解其它与人类密切相关的信息,比如温度、星期、日期等,电子万年历诞生了,它集时间、日期、星期和温度功能于一身,具有读取方便、显示直观、功能多样、电路简洁等诸多优点,符合电

子仪器仪表的发展趋势,具有广阔的市场前景。

该电子万年历主要采用AT89C51单片机作为主控核心,由DS1302时钟芯片提供时钟、LED动态扫描显示屏显示。AT89C51单片机是由Atmel公司推出的,功耗小,电压可选用4~6V电压供电;DS1302时钟芯片是美国DALLAS公司推出的具有涓细电流充电功能的低功耗实时时钟芯片,它可以对年、月、日、星期、时、分、秒进行计时,还具有闰年补偿等多种功能,而且DS1302的使用寿命长,误差小;数字显示是采用的LED液晶显示屏来显示,可以同时显示年、月、日、星期、时、分、秒和温度等信息。此外,该电子万年历还具有时间校准等功能。

关键词:时钟电路; 时钟芯片DS1302;LED动态扫描; 单片机AT89C51;MAX7219;

- 3 -

***********************

Abstract

With the society, science and technology, mankind learned that time, from the view of the sun, to the present electronic clock pendulum clock, continuous research and innovation. Observation time in

the same time, be able to understand other human beings is closely related to information, such as temperature, week, date and so on, the birth of the electronic calendar, and it set the time, date, week and temperature-in-one, with easy to read, intuitive display functional diversity, and many other advantages of simple circuit with the electronic instrumentation of the development trend of the. market prospects are broad

The main use of the electronic calendar AT89C51 single-chip microcomputer as the main core, provided by the DS1302 clock chip clock, DS18B20 the temperature chip acquisition transition temperature, LED display shows the dynamic scan. AT89C51 single-chip microcomputer is introduced by Atmel Corporation, a small power consumption, voltage can be selected 4 ~ 6V power supply voltage; DS1302 clock chip is introduced DALLAS fine with trickle charge function of current low-power real-time clock chip, which can of the year, month, day, week, hour, minute, second for time, also has multiple functions, such as a leap year compensation, and long life of the DS1302, a small error; DS18B20 temperature chip is a digital temperature sensor with a measurement accuracy high, a simple circuit to connect the characteristics of such sensors only need a data cable for data transmission; digital LED display is used to display LCD screen, can display year, month, day, week, hour, minute, second and temperature, etc. information. In addition, the electronic calendar is also a time-calibration functions.

Keywords: clock circuit; clock chip DS1302; LED dynamic scanning; single-chipAT89C51;MAX7219

- 4 -