1、 基于单片机的时钟电路的设计基于单片机的时钟电路的设计 The design of clock circuit based on MCU 专专 业:电子信息科学与技术业:电子信息科学与技术 学学 号:号: 姓姓 名:名: 指导教师:指导教师: I 基于单片机的时钟电路的设计基于单片机的时钟电路的设计 摘摘 要要: 文章主要采用 AT89c51 单片机最小化应用设计,LED 显示采用动态扫描方式 实现,P0 口输出段码数据,P1.0-P1.2 口作扫描输出,P0.1P0.4 口接按钮开 关 S1,S2,S3,S4,S5,rest 接 S6 复位按键。P0.0 控制秒的调整,每按一次加 1 秒;P
2、0.1 控制分的调整,每按一次加 1 分;P0.2 控制时的调整,每按一次加 1 个小时。为了提供 LED 数码管的驱动电流,用 74ls595 作电源驱动输出。实际设 计按情况采用 11.0592MHz 的晶振。电子时钟电路采用 12h 记时方式,时间用 8 位数码管显示。该电路采用 AT89c51 单片机,使用 5V 电池供电。 关键词关键词: : 单片机;抖动;数码管;中断;低功耗;时钟 II The design of clock circuit based on MCU Abstract: This article mainly uses at98c51 monolithic int
3、egrated circuit minimum application design, LED demonstrated that selects the dynamic scanning method to realize, the P0 mouth output section code data, the P1.0-P1.2 mouth makes the scan out, the P0.1-P0.4 mouth meets push-button switch S1, S2, S3, S4, S5, rest. P0.0 control of the second adjustmen
4、t, and each time one second; P0.1 control points of adjustment, each time at 1 pm; P0.2 control of the adjustment, and each time one hour.In order to provide the LED nixietube the drive current, 9012 makes the power source with the triode to actuate the output. The actual design uses 11.0592MHz according to the situation the crystal oscillator. The electron clock circuit selects the 24h time method, the time demonstrated with 8 nixietubes. This electric circuit uses at98c51 monolit