Ds1302数字时钟的芯片.docx
文本预览下载声明
中文摘要本文基于单片机,通过编程实现了数字钟,它不仅能够显示24小时制的时间,可以人为调整时间,并且可以显示具体的年、月、日,还带有闹钟的功能。本文实现的数字时钟由三个部分构成,提供振荡信号的DS1302芯片,转换振荡信号、实现多种功能的AT89S52单片机,以及可根据需要将结果表达的LCD1602显示器。本文设计的数字钟没有采用汇编语言,而是采用更为高级的C语言,与前者相比,后者语言更加凝练,程序结构更明了。本文最终完成的程序能完成对DS1320芯片进行操作,使其产生秒振荡信号,控制AT89S52单片机实现相应功能,当然,也包括控制LCD1602按照想要的形式输出统计出来的时间结果,比如以数字形式显示当前时间,调整设定闹钟等。本文设计的数字钟与其他相比,具有许多优点,用户体验更好。对于使用者来说,操作非常简便,与时间相关的功能基本都具备,时间显示比较准确可靠。另外,基于各种芯片、集成电路,大大减少了体积空间以及耗电量。关键词:DS1302数字时钟芯片;AT89S52单片机;LCD1602液晶显示器;C语言编辑。ABSTRACTThis paper introduces a design of multi- function digital clock system. It can display the24- hour time, can adjust the time,human and can display year, month, day, also with alarm clock function. The digital clock design system selection using single- chip microcomputer AT89 S52 single chip microcomputer,choice is used digital clock chip DS1302 and choice in the time display is LCD display LCD1602 display.The system software design using C language for programming. Mainly includes the main program of system software, DS1302 initialization program DS1302,read, write, DS1302 procedures, LCD1602 display, date/ time adjustment, timing alarm design.This system has a friendly user interface, simple operation, stable performance. The digital clock system is a long- term, continuous,reliable, steady work, the system also has small volume, low power consumption, easy to carry, easy to use.Key words:DS1302 digital clock chip;AT89S52 Microcontroller; LCD1602 liquid crystal displayer;C language programming.目录1 前言………………………………………………………………11.1 课题研究的背景…………………………………………………11.2 课题研究的意义…………………………………………………11.3 数字时钟的应用及发展前景……………………………………11.4课题的研究内容及技术要求……………………………………2 2. 核心芯片简介……………………………………………………32.1 DS1302简介……………………………………………………32.2 AT89S52简介……………………………………………………62.3 LCD的结构及工作原理…………………………………………83 系统的硬件设计与实现……………………………………………103.1 电路设计框图……………………………………………………103.2 系统硬件概述……………………………………………………103.3 主要单元电路的设计……………………………………………104 系统的软件设计……………………………………………………124.1 系统软件设计概述……………………………………………124.2 系统主程序设计………………………………………………124.3 时钟芯片
显示全部