| With the unprecedented development of the Internet of Things technology,smart wearable devices and smart phones are becoming more and more abundant,and their power consumption is becoming higher and higher.Therefore,extending the standby time of smart devices has become a "high ground" for competition among major hardware manufacturers,and the optimization of chip power consumption has gradually become one of the core issues facing the field of IC design.The chip is designed with two working modes:high-precision mode and low-power mode.In the low-power mode,the chip’s clock source is a low-power RC oscillator.After the RC oscillator is self-calibrated,it can provide a high-precision clock close to that of a quartz crystal oscillator.The RTC chip in this article mainly includes perpetual calendar,watchdog timer(WDT),countdown timer and alarm,supports 12/24 hour conversion,leap year automatic conversion,16 kinds of programmable clock square wave output and RC oscillator frequency self-calibration.It communicates with the Microcontroller Unit(MCU)through a four-wire Serial Peripheral Interface(SPI).The frequency self-calibration function of the RC oscillator is a special function of the RTC chip in this article that is different from the ordinary RTC chip.This design will automatically turn on the quartz crystal oscillator regularly,and the RC oscillator will automatically be calibrated to the same frequency as the crystal oscillator.After the calibration is completed The quartz crystal oscillator is automatically turned off.This design optimizes circuit power consumption at the system level,making RTC products more competitive in low-power application scenarios.In addition,there are many cross-clock-domain signal interactions in the RTC chip.This article summarizes the traditional cross-clock-domain signal processing method,combined with the characteristics of real-time clock circuits,and designs a more stable cross-clock-domain processing dedicated circuit.This article adopts the top-down design method,divides the sub-function modules,writes RTL-level code with verilog HDL,and completes the design of the digital circuit part.Then,use the Modelsim simulation tool to verify the circuit function.Finally,use ISE to complete circuit synthesis,build a verification platform,and complete the circuit verification on the FPGA development board and serial port software tools.After verification,the RTC circuit has fully realized the designed function. |