摘 要本次设计以 AT89C52 芯片为核心,辅以必要的外围电路,设计了一个简易的数字电子时钟,它由 5V 直流电源供电。在硬件方面,除了 CPU 外,使用两个四位一体的七段 LED 数码管和一个单独的共阳极数码管显示时、分、秒。四个简单的独立按键实现对时间的调整以与时钟/秒表功能的转换。软件方面采纳 C语言编程,使用 keil 软件进行编程与调试,使整个电子时钟能够完成时间的显示调时,秒表,报时等功能。数字时钟是采纳数字电路实现对“时”、“分”、“秒”数字显示的计时装置。数字时钟的精度、稳定度远远超过老式的机械时钟。在这次设计中,我们采纳 LED 数码管分别显示时、分、秒,以 24 小时计时方式,根据数码管动态显示原理来进行显示,用 12MHz 的晶振产生振荡脉冲,定时器计数。数字时钟体积小巧,价格低廉,时间精度高,使用方便,功能全,便于集成化而受广阔消费的喜爱,因此得到了广泛的应用。关键词:单片机;数字电子时钟;LED;数码管ABSTRACTThis design with AT89C52 chip as the core, supplemented by the necessary peripheral circuit, design a simple digital electronic clock, it consists of 5 v dc power supply. In terms of hardware, in addition to the CPU, using two four one of the seven segment LED digital tube and a single anode digital tube display when, minutes and seconds. Four simple implementation independent buttons adjust your time as well as the conversion clock/stopwatch function. Software using C language programming, programming and debugging, using keil software to complete the whole electronic clock time, according to the adjustment, timing alarm clock, reset, etc. Digital Clock is a digital circuit implementation of the “when”, “minutes”, “seconds” the figures show the timing device. Digital clock precision, stability, far more than the old mechanical clock. In this design, we use LED digital display hours, minutes, seconds, to 24-hour time mode, according to digital control theory to dynamic display to display, use the 12MHz...