CN109150168B - All-digital phase-locked loop of pipeline circuit structure and phase-locked control method - Google Patents

All-digital phase-locked loop of pipeline circuit structure and phase-locked control method Download PDF

Info

Publication number
CN109150168B
CN109150168B CN201811181639.9A CN201811181639A CN109150168B CN 109150168 B CN109150168 B CN 109150168B CN 201811181639 A CN201811181639 A CN 201811181639A CN 109150168 B CN109150168 B CN 109150168B
Authority
CN
China
Prior art keywords
signal
pipeline
module
digital
phase
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Active
Application number
CN201811181639.9A
Other languages
Chinese (zh)
Other versions
CN109150168A (en
Inventor
单长虹
田帆
王丽君
赵宇红
邓贤君
杨檬玮
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
University of South China
Original Assignee
University of South China
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by University of South China filed Critical University of South China
Priority to CN201811181639.9A priority Critical patent/CN109150168B/en
Publication of CN109150168A publication Critical patent/CN109150168A/en
Application granted granted Critical
Publication of CN109150168B publication Critical patent/CN109150168B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Classifications

    • HELECTRICITY
    • H03ELECTRONIC CIRCUITRY
    • H03LAUTOMATIC CONTROL, STARTING, SYNCHRONISATION OR STABILISATION OF GENERATORS OF ELECTRONIC OSCILLATIONS OR PULSES
    • H03L7/00Automatic control of frequency or phase; Synchronisation
    • H03L7/06Automatic control of frequency or phase; Synchronisation using a reference signal applied to a frequency- or phase-locked loop
    • H03L7/08Details of the phase-locked loop
    • H03L7/085Details of the phase-locked loop concerning mainly the frequency- or phase-detection arrangement including the filtering or amplification of its output signal
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F15/00Digital computers in general; Data processing equipment in general
    • G06F15/76Architectures of general purpose stored program computers
    • G06F15/78Architectures of general purpose stored program computers comprising a single central processing unit
    • G06F15/7807System on chip, i.e. computer system on a single chip; System in package, i.e. computer system on one or more chips in a single package
    • G06F15/7817Specially adapted for signal processing, e.g. Harvard architectures
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F15/00Digital computers in general; Data processing equipment in general
    • G06F15/76Architectures of general purpose stored program computers
    • G06F15/78Architectures of general purpose stored program computers comprising a single central processing unit
    • G06F15/7867Architectures of general purpose stored program computers comprising a single central processing unit with reconfigurable architecture
    • G06F15/7871Reconfiguration support, e.g. configuration loading, configuration switching, or hardware OS
    • G06F15/7878Reconfiguration support, e.g. configuration loading, configuration switching, or hardware OS for pipeline reconfiguration
    • HELECTRICITY
    • H03ELECTRONIC CIRCUITRY
    • H03LAUTOMATIC CONTROL, STARTING, SYNCHRONISATION OR STABILISATION OF GENERATORS OF ELECTRONIC OSCILLATIONS OR PULSES
    • H03L7/00Automatic control of frequency or phase; Synchronisation
    • H03L7/06Automatic control of frequency or phase; Synchronisation using a reference signal applied to a frequency- or phase-locked loop
    • H03L7/16Indirect frequency synthesis, i.e. generating a desired one of a number of predetermined frequencies using a frequency- or phase-locked loop
    • H03L7/18Indirect frequency synthesis, i.e. generating a desired one of a number of predetermined frequencies using a frequency- or phase-locked loop using a frequency divider or counter in the loop
    • HELECTRICITY
    • H03ELECTRONIC CIRCUITRY
    • H03LAUTOMATIC CONTROL, STARTING, SYNCHRONISATION OR STABILISATION OF GENERATORS OF ELECTRONIC OSCILLATIONS OR PULSES
    • H03L2207/00Indexing scheme relating to automatic control of frequency or phase and to synchronisation
    • H03L2207/50All digital phase-locked loop
    • YGENERAL TAGGING OF NEW TECHNOLOGICAL DEVELOPMENTS; GENERAL TAGGING OF CROSS-SECTIONAL TECHNOLOGIES SPANNING OVER SEVERAL SECTIONS OF THE IPC; TECHNICAL SUBJECTS COVERED BY FORMER USPC CROSS-REFERENCE ART COLLECTIONS [XRACs] AND DIGESTS
    • Y02TECHNOLOGIES OR APPLICATIONS FOR MITIGATION OR ADAPTATION AGAINST CLIMATE CHANGE
    • Y02DCLIMATE CHANGE MITIGATION TECHNOLOGIES IN INFORMATION AND COMMUNICATION TECHNOLOGIES [ICT], I.E. INFORMATION AND COMMUNICATION TECHNOLOGIES AIMING AT THE REDUCTION OF THEIR OWN ENERGY USE
    • Y02D10/00Energy efficient computing, e.g. low power processors, power management or thermal management

Landscapes

  • Engineering & Computer Science (AREA)
  • Computer Hardware Design (AREA)
  • Theoretical Computer Science (AREA)
  • General Engineering & Computer Science (AREA)
  • Physics & Mathematics (AREA)
  • General Physics & Mathematics (AREA)
  • Signal Processing (AREA)
  • Computing Systems (AREA)
  • Microelectronics & Electronic Packaging (AREA)
  • Stabilization Of Oscillater, Synchronisation, Frequency Synthesizers (AREA)

Abstract

流水线电路结构的全数字锁相环及锁相控制方法,所述的全数字锁相环包括数字鉴相器模块、流水线变模控制器模块、流水线数字滤波器模块、加扣脉冲控制电路模块和流水线分频器模块。利用电子设计自动化技术完成各个模块电路的设计。通过采用流水线技术对锁相环的电路结构进行优化,提高了锁相系统的运行速度,降低了系统功耗,通过动态调节系统参数实现对锁相环工作过程的动态控制,既能提高锁相速度,又可增强系统的稳定性。该流水线电路结构的全数字锁相环具有锁相速度快、功耗低、和系统稳定性高等优点,在系统芯片应用中可降低实际应用的成本,有巨大的市场潜力。

An all-digital phase-locked loop with a pipeline circuit structure and a phase-locked control method, wherein the all-digital phase-locked loop includes a digital phase detector module, a pipeline variable mode controller module, a pipeline digital filter module, a buckle pulse control circuit module and Pipeline divider block. Use electronic design automation technology to complete the design of each module circuit. By adopting pipeline technology to optimize the circuit structure of the phase-locked loop, the operating speed of the phase-locked system is improved, and the power consumption of the system is reduced. Speed, but also enhance the stability of the system. The all-digital phase-locked loop with pipeline circuit structure has the advantages of fast phase-locking speed, low power consumption, and high system stability, and can reduce the cost of practical application in system chip applications, and has huge market potential.

Description

流水线电路结构的全数字锁相环及锁相控制方法All-Digital Phase-Locked Loop with Pipeline Circuit Structure and Phase-Locked Control Method

技术领域technical field

本发明涉及电子信息技术领域,具体涉及一种应用于片上系统的流水线电路结构的全数字锁相环及锁相控制方法。The invention relates to the technical field of electronic information, in particular to an all-digital phase-locked loop and a phase-locked control method applied to a pipeline circuit structure of an on-chip system.

背景技术Background technique

锁相环在通信、无线电电子学、自动控制和电力系统自动化等领域得到了极为广泛的应用,随着半导体技术突飞猛进的发展,系统芯片的出现,锁相环已成为片上系统中的一个重要功能模块。现有全数字锁相环由于电路结构不合理存在功耗偏高的缺陷。而对于在各个领域片上系统应用的芯片来说,降低其功耗、缩短响应时间,提高系统的运行速度对系统性能将产生非常大的改善,因而为了减少片上系统的整体功耗,尤其是减少诸如移动设备的功耗,则需要减少系统芯片中各功能模块的功耗。Phase-locked loops have been widely used in the fields of communication, radio electronics, automatic control and power system automation. With the rapid development of semiconductor technology and the emergence of system chips, phase-locked loops have become an important function in SoCs. module. The existing all-digital phase-locked loop has the defect of high power consumption due to unreasonable circuit structure. For chips used in system-on-chip applications in various fields, reducing power consumption, shortening response time, and increasing system operating speed will greatly improve system performance. Therefore, in order to reduce the overall power consumption of system-on-chip, especially reduce Such as the power consumption of mobile devices, it is necessary to reduce the power consumption of each functional module in the system chip.

另外,全数字锁相环的抗扰性能与锁相速度、捕获范围和环路带宽密切相关,而且是相互矛盾的,因而通常设计时采用折中方式获得较好的抗扰性能,提高系统稳定性,但是在进行折中选择时势必对系统的质量产生不利的影响。现有全数字锁相环的电路结构的局限性以及系统参数的固定不变,使得在全数字锁相环应用的片上芯片的高性能和高稳定性不能同时实现。In addition, the anti-interference performance of the all-digital phase-locked loop is closely related to the phase-locked speed, capture range and loop bandwidth, and they are contradictory. Therefore, a compromise method is usually used in the design to obtain better anti-interference performance and improve system stability. However, it is bound to have an adverse effect on the quality of the system when making a compromise. The limitation of the circuit structure of the existing all-digital phase-locked loop and the fixed system parameters make it impossible to realize the high performance and high stability of the chip-on-chip applied in the all-digital phase-locked loop at the same time.

发明内容Contents of the invention

本发明的目的是克服现有技术的上述不足而提供一种流水线电路结构的全数字锁相环及锁相控制方法,使用流水线技术对锁相环的电路结构进行优化,提高锁相系统的运行速度,降低系统功耗。同时,通过对流水线数字滤波器参数的动态调节实现对全数字锁相环工作过程的动态控制,既提高了锁相速度,又增强了系统的稳定性。The purpose of the present invention is to overcome the above-mentioned deficiencies of the prior art and provide a full-digital phase-locked loop and a phase-locked control method with a pipeline circuit structure, use pipeline technology to optimize the circuit structure of the phase-locked loop, and improve the operation of the phase-locked system speed and reduce system power consumption. At the same time, the dynamic control of the working process of the all-digital phase-locked loop is realized by dynamically adjusting the parameters of the pipeline digital filter, which not only improves the phase-locking speed, but also enhances the stability of the system.

本发明的技术方案是:一种流水线电路结构的全数字锁相环,包括数字鉴相器模块、流水线变模控制器模块、流水线数字滤波器模块、加扣脉冲控制电路模块和流水线分频器模块,利用电子设计自动化技术完成各个模块电路的设计。The technical solution of the present invention is: an all-digital phase-locked loop with a pipeline circuit structure, including a digital phase detector module, a pipeline variable mode controller module, a pipeline digital filter module, a buckle pulse control circuit module and a pipeline frequency divider Modules, using electronic design automation technology to complete the design of each module circuit.

数字鉴相器模块由双D触发器实现,该数字鉴相器模块具有两个信号输入端及三个信号输出端,两个信号输入端分别为fin信号输入端及fout信号输入端,三个信号输出端分别为ua信号输出端、ah信号输出端及be信号输出端,数字鉴相器模块通过检测全数字锁相环输入信号fin与输出信号fout的上升沿,判断其相位误差和极性,并生成反映输入与输出信号之间的相位误差信号ua,以及极性信号,即超前信号ah和滞后信号be。The digital phase detector module is realized by double D flip-flops. The digital phase detector module has two signal input terminals and three signal output terminals. The two signal input terminals are respectively the fin signal input terminal and the fout signal input terminal. The signal output terminals are ua signal output terminal, ah signal output terminal and be signal output terminal respectively. The digital phase detector module judges the phase error and polarity by detecting the rising edge of the input signal fin and the output signal fout of the full digital phase locked loop. , and generate a phase error signal ua that reflects the input and output signals, and a polarity signal, that is, the leading signal ah and the lagging signal be.

流水线变模控制器模块包括时间数字转换模块TDC和变模控制器,流水线变模控制器模块为流水线数字滤波器提供可调的动态参数,接收数字鉴相器模块输出的相位误差信号ua,并根据该相位误差信号ua的大小来调节流水线变模控制器模块输出的模值km,具体的调节方式为:当相位误差较大时,输出较小的模值km,以便加快锁相速度;当相位误差较小时,输出较大的模值km,以减小环路锁定后的相位抖动。The pipeline variable mode controller module includes a time-to-digital conversion module TDC and a variable mode controller. The pipeline variable mode controller module provides adjustable dynamic parameters for the pipeline digital filter, receives the phase error signal ua output by the digital phase detector module, and According to the size of the phase error signal ua, the modulus km output by the pipeline variable mode controller module is adjusted. The specific adjustment method is: when the phase error is large, a smaller modulus km is output in order to speed up the phase locking speed; When the phase error is small, a larger modulus km is output to reduce the phase jitter after the loop is locked.

其中时间数字转换模块TDC包括20位计数器,20位计数器采用五级流水线设计,每一级计数器M包括寄存器J、加1器和用于暂存计数值的锁存器S,其中第一级计数器的位数为0-3位,第二级计数器位数为4-7位,第三级计数器的位数为8-11位,第四级计数器的位数为12-15位,第五级计数器位数为16-19位,采用超高速集成电路硬件描述语言完成对时间数字转换模块TDC的设计,再与变模控制器连接,得到流水线自动变模控制器模块;根据数字鉴相器模块输出的相位误差信号ua,为流水线数字滤波器模块中的可逆计数器提供可变模值的输出信号km。The time-to-digital conversion module TDC includes a 20-bit counter, and the 20-bit counter adopts a five-stage pipeline design. Each stage of the counter M includes a register J, an adder and a latch S for temporarily storing the count value. The first stage of the counter The digits of the counter are 0-3 digits, the digits of the second-stage counter are 4-7 digits, the digits of the third-stage counter are 8-11 digits, the digits of the fourth-stage counter are 12-15 digits, and the fifth-stage counters are 12-15 digits. The number of counters is 16-19 bits, and the design of the time-to-digital conversion module TDC is completed by using the ultra-high-speed integrated circuit hardware description language, and then connected with the variable-mode controller to obtain the pipeline automatic variable-mode controller module; according to the digital phase detector module The output phase error signal ua provides the output signal km with variable modulus value for the reversible counter in the pipeline digital filter module.

流水线数字滤波器模块由8位可逆计数器构成,该可逆计数器采用二级流水线设计,每一级计数器M包括寄存器J、加1器和用于暂存计数值的锁存器S。其中第一级计数器的位数为0-3位,第二级计数器为位数为4-7位,可逆计数器的模值是流水线变模控制器模块按照预设的控制算法自动生成的;该流水线数字滤波器模块接收来自数字鉴相器模块根据输入信号fin与输出反馈信号fout比较得到的超前信号ah和滞后信号be,根据超前信号ah或滞后信号be进行加计数或减计数,当计数值达到接收到的计数器的模值时,产生进位信号inc或借位信号dec,并分别送给加扣脉冲控制电路模块。The pipeline digital filter module consists of an 8-bit reversible counter, which adopts a two-stage pipeline design, and each stage of counter M includes a register J, an adder and a latch S for temporarily storing the count value. Among them, the number of digits of the first stage counter is 0-3 digits, the number of digits of the second stage counter is 4-7 digits, and the modulus value of the reversible counter is automatically generated by the pipeline variable modulus controller module according to the preset control algorithm; The pipeline digital filter module receives the leading signal ah and the lagging signal be obtained from the digital phase detector module according to the comparison between the input signal fin and the output feedback signal fout, and counts up or down according to the leading signal ah or the lagging signal be, when the count value When the received modulus value of the counter is reached, a carry signal inc or a borrow signal dec is generated, and sent to the plus and minus pulse control circuit module respectively.

加扣脉冲控制电路模块接收流水线数字滤波器模块发送的进位信号inc或借位信号dec,对其输出的数字序列信号进行脉冲的加扣处理,并将处理后的数字序列信号发送到流水线分频器模块;具体的实现方式为:当加扣脉冲控制电路模块输入端的进位信号inc为高电平时,在其输出的数字序列信号中插入一个脉冲;当加扣脉冲控制电路模块另一输入端的借位信号dec为高电平时,在其输出的数字序列信号中扣除一个脉冲,并将经过加扣脉冲处理后的数字序列信号发送到流水线分频器模块作进一步的调节。The plus and minus pulse control circuit module receives the carry signal inc or the borrow signal dec sent by the pipeline digital filter module, performs pulse plus and minus processing on the output digital sequence signal, and sends the processed digital sequence signal to the pipeline for frequency division device module; the specific implementation method is: when the carry signal inc at the input terminal of the buckling pulse control circuit module is high level, a pulse is inserted in the digital sequence signal output by it; When the bit signal dec is at a high level, a pulse is subtracted from the output digital sequence signal, and the digital sequence signal processed by adding the pulse is sent to the pipeline frequency divider module for further adjustment.

流水线分频器模块由24位计数器构成,其分频系数N可调;该24位计数器采用三级流水线设计,每一级计数器M包括寄存器J、加1器和用于暂存计数值的锁存器S;每一级为一个8位计数器,其中第一级计数器的位数为0-7位,第二级计数器位数为8-15位,第三级计数器的位数为16-23位;每当低一级的8位计数器产生进位信号时,触发高一级的8位计数器开始计数,以此进行累加计数;该分频系数N从外部输入端口设置,即根据该锁相环输入信号频率的不同,灵活设置分频系数的具体参数;该参数的设置是按照系统的时钟信号频率与系统输入信号频率的比值满足2N来选择的。The pipeline frequency divider module is composed of a 24-bit counter, and its frequency division factor N is adjustable; the 24-bit counter adopts a three-stage pipeline design, and each stage of the counter M includes a register J, an adder and a lock for temporarily storing the count value Register S; each level is an 8-bit counter, in which the number of bits of the first level counter is 0-7 bits, the number of bits of the second level counter is 8-15 bits, and the number of bits of the third level counter is 16-23 bit; whenever the 8-bit counter of the lower level generates a carry signal, the 8-bit counter of the higher level is triggered to start counting, so as to perform cumulative counting; the frequency division coefficient N is set from the external input port, that is, according to the phase-locked loop Depending on the frequency of the input signal, the specific parameters of the frequency division coefficient can be flexibly set; the setting of this parameter is selected according to the ratio of the system clock signal frequency to the system input signal frequency satisfying 2 N.

数字鉴相器模块的相位误差信号ua输出端与流水线变模控制器模块的输入端相接,超前信号ah和滞后信号be输出端分别与流水线数字滤波器模块的第一信号输入端及第二信号输入端相接,流水线变模控制器模块的模值信号km输出端与流水线数字滤波器模块的第三输信号入端相接,流水线数字滤波器模块的进位信号inc输出端及借位信号dec输出端分别与加扣脉冲控制电路模块的两个信号输入端相接,加扣脉冲控制电路模块的信号输出端与流水线分频器模块的第一信号输入端相接,根据时钟信号频率与系统输入信号频率确定的外部输入端口设置的分频系数N与流水线分频器模块的第二输入端相接,流水线分频器模块的输出信号fout为锁相环输出信号,并将其反馈到数字鉴相器模块作为数字鉴相器模块的其中一个输入。The output terminal of the phase error signal ua of the digital phase detector module is connected with the input terminal of the pipeline variable mode controller module, and the output terminals of the leading signal ah and the lag signal be are respectively connected with the first signal input terminal and the second signal terminal of the pipeline digital filter module. The signal input terminals are connected, the modulus signal km output terminal of the pipeline variable mode controller module is connected with the third input signal input terminal of the pipeline digital filter module, the carry signal inc output terminal of the pipeline digital filter module and the borrow signal The dec output ends are respectively connected with the two signal input ends of the buckle pulse control circuit module, the signal output end of the buckle pulse control circuit module is connected with the first signal input end of the pipeline frequency divider module, according to the clock signal frequency and The frequency division factor N set by the external input port of the system input signal frequency is connected with the second input terminal of the pipeline frequency divider module, and the output signal fout of the pipeline frequency divider module is a phase-locked loop output signal, and it is fed back to The digital phase detector module serves as one of the inputs of the digital phase detector module.

本发明根据流水线电路结构的全数字锁相环的系统结构框图,采用自顶而下的设计方法,基于电子设计自动化技术,采用VHDL语言对各模块进行编程,完成流水线电路结构的全数字锁相环顶层电路设计。According to the system structure diagram of the full digital phase-locked loop of the assembly line circuit structure, the present invention adopts a top-down design method, based on electronic design automation technology, uses VHDL language to program each module, and completes the full digital phase locking of the assembly line circuit structure Ring top circuit design.

在流水线电路结构的全数字锁相环顶层电路中,系统时钟信号clk分别与流水线变模控制器模块、流水线数字滤波器模块及加扣脉冲控制电路模块的输入端clk相接。In the top-level circuit of the all-digital phase-locked loop of the pipeline circuit structure, the system clock signal clk is connected to the input terminal clk of the pipeline variable mode controller module, the pipeline digital filter module and the buckle pulse control circuit module respectively.

系统复位信号reset分别与流水线变模控制器模块、流水线数字滤波器模块、加扣脉冲控制电路模块及流水线分频器模块的输入端reset相接。The system reset signal reset is respectively connected to the input terminal reset of the pipeline variable mode controller module, the pipeline digital filter module, the buckling pulse control circuit module and the pipeline frequency divider module.

使能信号en与流水线数字滤波器模块的输入端en相接。The enable signal en is connected to the input terminal en of the pipeline digital filter module.

系统输入信号fin与数字鉴相器模块输入端fin相接。The system input signal fin is connected to the input terminal fin of the digital phase detector module.

数字鉴相器模块的输出信号有三个,分别为ah、be及ua,其中ah、be分别与流水线数字滤波器模块的输入端ah、be相接,ua与流水线变模控制器模块的输入端ua相接。There are three output signals of the digital phase detector module, namely ah, be and ua, where ah and be are respectively connected to the input terminals ah and be of the pipeline digital filter module, and ua is connected to the input terminal of the pipeline variable mode controller module Ua is connected.

流水线变模控制器模块的输出端km与流水线数字滤波器模块的输入端km相接。The output terminal km of the pipeline variable mode controller module is connected with the input terminal km of the pipeline digital filter module.

流水线数字滤波器模块的两个输出端进位信号inc输出端及借位信号dec分别与加扣脉冲控制电路模块输入端inc、dec相接。The two output terminals of the pipeline digital filter module, the output terminal of the carry signal inc and the output terminal of the borrow signal dec, are respectively connected to the input terminals inc and dec of the buckling pulse control circuit module.

加扣脉冲控制电路模块的输出端idout与流水线分频器模块的输入端idout相接。The output terminal idout of the buckling pulse control circuit module is connected with the input terminal idout of the pipeline frequency divider module.

计算系统的时钟信号频率与系统输入信号频率的比值关系,设置分频系数N,将其作为流水线分频器模块的分频系数N输入端,流水线分频器模块的输出端fout为系统的输出信号端,同时又反馈到系统的输入端口作为数字鉴相器模块的输入端。Calculate the ratio relationship between the clock signal frequency of the system and the system input signal frequency, set the frequency division coefficient N, and use it as the input terminal of the frequency division coefficient N of the pipeline frequency divider module, and the output terminal fout of the pipeline frequency divider module is the output of the system The signal terminal is also fed back to the input port of the system as the input terminal of the digital phase detector module.

本发明提供的流水线电路结构的全数字锁相环的具体锁相控制过程如下:The specific phase-locked control process of the all-digital phase-locked loop of pipeline circuit structure provided by the present invention is as follows:

数字鉴相器模块通过检测锁相环输入信号fin和输出信号fout的上升沿,输出相应的相位超前信号ah或滞后信号be及相位误差信号ua。The digital phase detector module outputs the corresponding phase leading signal ah or lagging signal be and phase error signal ua by detecting the rising edge of the phase locked loop input signal fin and output signal fout.

流水线变模控制器模块对相位误差信号进行数字化和比较,当相位误差较大时,减小送入流水线数字滤波器模块的模值km;当相位误差较小的时,增大送入流水线数字滤波器模块的模值km。The pipeline variable mode controller module digitizes and compares the phase error signal. When the phase error is large, the modulus km sent to the pipeline digital filter module is reduced; when the phase error is small, the digital value sent to the pipeline is increased. The modulus km of the filter block.

同时,判断数字鉴相器模块输出的相位超前信号ah和相位滞后信号be的电平,当其输出的相位超前信号ah为高电平时,流水线变模控制器模块进行加计数,当加计数值达到流水线变模控制器模块模值km后,流水线数字滤波模块输出进位信号inc;当数字鉴相器模块输出的相位滞后信号be为高电平时,流水线变模控制器模块进行减计数,当减计数值达到模值km后,流水线数字滤波模块输出借位信号dec。At the same time, judge the level of the phase lead signal ah and the phase lag signal be output by the digital phase detector module. When the phase lead signal ah output by the digital phase detector module is at a high level, the pipeline variable mode controller module performs counting up. When the counting value After reaching the modulus km of the pipeline variable mode controller module, the pipeline digital filter module outputs the carry signal inc; when the phase lag signal be output by the digital phase detector module is at a high level, the pipeline variable mode controller module counts down. After the count value reaches the modulus km, the pipeline digital filter module outputs the borrow signal dec.

加扣脉冲控制电路模块根据流水线数字滤波模块输出的进位信号inc、借位信号dec,通过加上或减去一个系统时钟周期的时间调整该加扣脉冲控制电路模块的输出信号idout的相位。The buckling pulse control circuit module adjusts the phase of the output signal idout of the buckling pulse control circuit module by adding or subtracting a system clock cycle time according to the carry signal inc and the borrow signal dec output by the pipeline digital filter module.

流水线分频器模块根据加扣脉冲控制电路模块输出的数字信号序列,以及根据系统的时钟信号频率与系统输入信号频率的比值确定的分频系数N,输出流水线分频器模块的输出信号fout送入数字鉴相器模块,与下一周期输入信号fin共同作为数字鉴相器模块的输入,产生相应的相位超前信号ah或滞后信号be及相位误差信号ua,依此进行控制,逐渐减小相位误差,并最终实现锁相环的锁定。The pipeline frequency divider module outputs the output signal fout of the pipeline frequency divider module according to the digital signal sequence output by the buckle pulse control circuit module and the frequency division coefficient N determined according to the ratio of the system clock signal frequency to the system input signal frequency. into the digital phase detector module, together with the input signal fin of the next period as the input of the digital phase detector module, to generate the corresponding phase leading signal ah or lagging signal be and phase error signal ua, and control accordingly to gradually reduce the phase error, and finally realize the locking of the phase-locked loop.

在流水线电路结构的全数字锁相环中,通过多级流水线技术设计流水线变模控制器模块、流水线数字滤波器模块以及流水线分频器模块的电路结构,使得系统延时减少,提高了系统的工作速度,并减少了系统的总功耗。In the full digital phase-locked loop with pipeline circuit structure, the circuit structure of pipeline variable mode controller module, pipeline digital filter module and pipeline frequency divider module is designed through multi-stage pipeline technology, which reduces the system delay and improves the system performance. operating speed, and reduces the overall power consumption of the system.

流水线变模控制器模块中可逆计数器的模值随着相位误差的不同而变化,可以加快其锁定速度,且在相位锁定区间,会自动选择本系统所设置的最大模值,从而大大减小环路输出信号相位的抖动,提高了系统的稳定性;通过设置流水线分频器模块的分频系数N由外部输入端口设置,满足按照系统的时钟信号频率与系统输入信号频率的比值满足2N进行选择,使得当系统输入信号频率发生跳变时,该锁相环能实现迅速对相位误差进行调整,且锁定后同样自动选择最大模值,即根据其不同的工作过程对系统参数进行动态调节,从而解决提高锁定速度与稳定性之间的矛盾,提高系统的整体性能。The modulus value of the reversible counter in the pipeline variable mode controller module changes with the phase error, which can speed up its locking speed, and in the phase locking interval, it will automatically select the maximum modulus value set by the system, thereby greatly reducing the loop The jitter of the phase of the output signal of the road improves the stability of the system; by setting the frequency division coefficient N of the pipeline frequency divider module from the external input port, it is satisfied that the ratio of the system clock signal frequency to the system input signal frequency satisfies 2 N. selection, so that when the frequency of the system input signal jumps, the phase-locked loop can quickly adjust the phase error, and automatically select the maximum modulus after locking, that is, dynamically adjust the system parameters according to its different working processes. Thereby solving the contradiction between improving the locking speed and stability, and improving the overall performance of the system.

本发明与现有技术相比具有如下特点:Compared with the prior art, the present invention has the following characteristics:

本发明所提出的多级流水线电路结构的全数字锁相环,采用电子设计自动化技术完成系统设计,其性能特点在于:The all-digital phase-locked loop of the multi-stage assembly line circuit structure proposed by the present invention adopts electronic design automation technology to complete the system design, and its performance characteristics are:

1、通过流水线技术设置流水线变模控制器模块、流水线数字滤波器模块、及流水线分频器模块,对锁相环的电路结构进行了优化,提高了锁相系统的运行速度,降低了系统功耗。1. The pipeline variable mode controller module, pipeline digital filter module, and pipeline frequency divider module are set through pipeline technology, and the circuit structure of the phase-locked loop is optimized, which improves the operating speed of the phase-locked system and reduces the system power. consumption.

2、通过对流水线数字滤波器参数的动态调节实现了对锁相环工作过程的动态控制,既能提高锁相速度,又可增强系统的稳定性。2. Through the dynamic adjustment of the pipeline digital filter parameters, the dynamic control of the phase-locked loop working process is realized, which can not only improve the phase-locking speed, but also enhance the stability of the system.

3、该锁相环路具有锁相速度快、功耗低、和系统稳定性高等优点,在将其应用到系统芯片中时可降低实际应用的成本,有巨大的市场潜力。3. The phase-locked loop has the advantages of fast phase-locking speed, low power consumption, and high system stability. When it is applied to a system chip, it can reduce the cost of practical application and has huge market potential.

以下结合附图和具体实施方式对本发明的详细结构作进一步描述。The detailed structure of the present invention will be further described below in conjunction with the accompanying drawings and specific embodiments.

附图说明Description of drawings

附图1为流水线电路结构的全数字锁相环的系统结构框图;Accompanying drawing 1 is the system structural block diagram of the all-digital phase-locked loop of pipeline circuit structure;

附图2为采用多级流水线技术的计数器电路结构图;Accompanying drawing 2 is the counter circuit structural diagram that adopts multistage pipeline technology;

附图3为流水线变模控制器模块的电路结构图;Accompanying drawing 3 is the circuit structural diagram of pipeline variable mode controller module;

附图4为流水线电路结构的全数字锁相环的顶层电路图;Accompanying drawing 4 is the top-level circuit diagram of the all-digital phase-locked loop of pipeline circuit structure;

附图5为fin=50MHz时的波形仿真图;Accompanying drawing 5 is the waveform simulation diagram when fin=50MHz;

附图6为fin=50MHz向fin=25MHz跳变时的波形仿真图。Accompanying drawing 6 is the simulation diagram of the waveform when fin=50MHz jumps to fin=25MHz.

具体实施方式Detailed ways

流水线电路结构的全数字锁相环,包括数字鉴相器模块1、流水线变模控制器模块5、流水线数字滤波器模块2、加扣脉冲控制电路模块3和流水线分频器模块4。利用电子设计自动化技术完成各个模块电路的设计。An all-digital phase-locked loop with a pipeline circuit structure, including a digital phase detector module 1, a pipeline variable mode controller module 5, a pipeline digital filter module 2, a buckling pulse control circuit module 3 and a pipeline frequency divider module 4. Use electronic design automation technology to complete the design of each module circuit.

数字鉴相器模块1由双D触发器实现,该数字鉴相器模块具有两个信号输入端及三个信号输出端,两个信号输入端分别为fin信号输入端及fout信号输入端,三个信号输出端分别为ua信号输出端、ah信号输出端及be信号输出端,数字鉴相器模块1通过检测全数字锁相环输入信号fin与输出信号fout的上升沿,判断其相位误差和极性,并生成反映输入与输出信号之间的相位误差信号ua,以及极性信号,即超前信号ah和滞后信号be。The digital phase detector module 1 is realized by double D flip-flops. The digital phase detector module has two signal input terminals and three signal output terminals. The two signal input terminals are respectively the fin signal input terminal and the fout signal input terminal. The two signal output terminals are the ua signal output terminal, the ah signal output terminal and the be signal output terminal respectively. The digital phase detector module 1 judges the phase error and Polarity, and generate a phase error signal ua that reflects the input and output signals, and a polarity signal, that is, the leading signal ah and the lagging signal be.

流水线变模控制器模块5包括时间数字转换模块TDC5-1和变模控制器5-2,流水线变模控制器模块5为流水线数字滤波器2提供可调的动态参数,接收数字鉴相器模块1输出的相位误差信号ua,并根据该相位误差信号ua的大小来调节流水线变模控制器模块5输出的模值km,具体的调节方式为:当相位误差较大时,输出较小的模值km,以便加快锁相速度;当相位误差较小时,输出较大的模值km,以减小环路锁定后的相位抖动。The pipeline variable mode controller module 5 includes a time-to-digital conversion module TDC5-1 and a variable mode controller 5-2, the pipeline variable mode controller module 5 provides adjustable dynamic parameters for the pipeline digital filter 2, and receives the digital phase detector module 1 output phase error signal ua, and adjust the modulus km output by the pipeline variable mode controller module 5 according to the size of the phase error signal ua, the specific adjustment method is: when the phase error is large, output a smaller modulus The value km is used to speed up the phase locking speed; when the phase error is small, a larger modulus value km is output to reduce the phase jitter after the loop is locked.

其中时间数字转换模块TDC5-1包括20位计数器,20位计数器采用五级流水线设计,每一级计数器M包括寄存器J、加1器和用于暂存计数值的锁存器S。其中第一级计数器的位数为0-3位,第二级计数器位数为4-7位,第三级计数器的位数为8-11位,第四级计数器的位数为12-15位,第五级计数器位数为16-19位,如图2所示,其中I为计数器的输入信号,O为计数器的输出信号。采用超高速集成电路硬件描述语言完成对时间数字转换模块TDC5-1的设计,再与变模控制器5-2连接,得到流水线自动变模控制器模块5。根据数字鉴相器模块1输出的相位误差信号ua,为流水线数字滤波器模块2中的可逆计数器提供可变模值的输出信号km。The time-to-digital conversion module TDC5-1 includes a 20-bit counter, and the 20-bit counter adopts a five-stage pipeline design, and each stage of the counter M includes a register J, an adder and a latch S for temporarily storing the count value. Among them, the digits of the first stage counter are 0-3 digits, the digits of the second stage counter are 4-7 digits, the digits of the third stage counter are 8-11 digits, and the digits of the fourth stage counter are 12-15 digits. Bit, the number of digits of the fifth-stage counter is 16-19, as shown in Figure 2, where I is the input signal of the counter, and O is the output signal of the counter. The design of the time-to-digital conversion module TDC5-1 is completed by using the ultra-high-speed integrated circuit hardware description language, and then connected with the variable-mode controller 5-2 to obtain the pipeline automatic variable-mode controller module 5. According to the phase error signal ua output by the digital phase detector module 1, the reversible counter in the pipeline digital filter module 2 is provided with an output signal km of variable modulus.

流水线数字滤波器模块2由8位可逆计数器构成,该可逆计数器采用二级流水线设计,每一级计数器M包括寄存器J、加1器和用于暂存计数值的锁存器S。其中第一级计数器的位数为0-3位,第二级计数器为位数为4-7位,可逆计数器的模值是流水线变模控制器模块5按照预设的控制算法自动生成的。该流水线数字滤波器模块2接收来自数字鉴相器模块1根据输入信号fin与输出反馈信号fout比较得到的超前信号ah和滞后信号be,根据超前信号ah或滞后信号be进行加计数或减计数,当计数值达到接收到的计数器的模值时,产生进位信号inc或借位信号dec,并分别送给加扣脉冲控制电路模块3。The pipeline digital filter module 2 is composed of an 8-bit reversible counter. The reversible counter adopts a two-stage pipeline design. Each stage of the counter M includes a register J, an adder and a latch S for temporarily storing the count value. Wherein the number of digits of the first stage counter is 0-3 digits, the number of digits of the second stage counter is 4-7 digits, and the modulus value of the reversible counter is automatically generated by the pipeline variable modulus controller module 5 according to the preset control algorithm. The pipeline digital filter module 2 receives the leading signal ah and the lagging signal be obtained from the digital phase detector module 1 according to the comparison between the input signal fin and the output feedback signal fout, and counts up or down according to the leading signal ah or the lagging signal be, When the count value reaches the modulus value of the received counter, a carry signal inc or a borrow signal dec is generated, and sent to the add pulse control circuit module 3 respectively.

加扣脉冲控制电路模块3接收流水线数字滤波器模块2发送的进位信号inc或借位信号dec,对其输出的数字序列信号进行脉冲的加扣处理,并将处理后的数字序列信号发送到流水线分频器模块4。具体的实现方式为:当加扣脉冲控制电路模块3输入端的进位信号inc为高电平时,在其输出的数字序列信号中插入一个脉冲;当加扣脉冲控制电路模块3另一输入端的借位信号dec为高电平时,在其输出的数字序列信号中扣除一个脉冲,并将经过加扣脉冲处理后的数字序列信号发送到流水线分频器模块4作进一步的调节。Addition pulse control circuit module 3 receives the carry signal inc or borrow signal dec sent by the pipeline digital filter module 2, performs pulse addition processing on the digital sequence signal output by it, and sends the processed digital sequence signal to the pipeline Divider module 4. The specific implementation method is: when the carry signal inc of the input terminal of the buckle pulse control circuit module 3 is high level, a pulse is inserted in the digital sequence signal output by it; When the signal dec is at a high level, a pulse is subtracted from the output digital sequence signal, and the digital sequence signal processed by adding the pulse is sent to the pipeline frequency divider module 4 for further adjustment.

流水线分频器模块4由24位计数器构成,其分频系数N可调。该24位计数器采用三级流水线设计,每一级计数器M包括寄存器J、加1器和用于暂存计数值的锁存器S。每一级为一个8位计数器,其中第一级计数器的位数为0-7位,第二级计数器位数为8-15位,第三级计数器的位数为16-23位。每当低一级的8位计数器产生进位信号时,触发高一级的8位计数器开始计数,以此进行累加计数;该分频系数N从外部输入端口设置,即根据该锁相环输入信号频率的不同,灵活设置分频系数的具体参数。该参数的设置是按照系统的时钟信号频率与系统输入信号频率的比值满足2N来选择的。The pipeline frequency divider module 4 is composed of a 24-bit counter, and its frequency division factor N is adjustable. The 24-bit counter adopts a three-stage pipeline design, and each stage of the counter M includes a register J, an adder and a latch S for temporarily storing the count value. Each level is an 8-bit counter, wherein the number of bits of the first level counter is 0-7 bits, the number of bits of the second level counter is 8-15 bits, and the number of bits of the third level counter is 16-23 bits. Whenever the low-level 8-bit counter generates a carry signal, the high-level 8-bit counter is triggered to start counting, so as to perform cumulative counting; the frequency division coefficient N is set from the external input port, that is, according to the phase-locked loop input signal Depending on the frequency, the specific parameters of the frequency division coefficient can be flexibly set. The setting of this parameter is selected according to the ratio of the system clock signal frequency to the system input signal frequency satisfying 2 N.

数字鉴相器模块1的相位误差信号ua输出端与流水线变模控制器模块5的输入端相接,超前信号ah和滞后信号be输出端分别与流水线数字滤波器模块2的第一信号输入端及第二信号输入端相接,流水线变模控制器模块5的模值信号km输出端与流水线数字滤波器模块2的第三输信号入端相接,流水线数字滤波器模块2的进位信号inc输出端及借位信号dec输出端分别与加扣脉冲控制电路模块3的两个信号输入端相接,加扣脉冲控制电路模块3的信号输出端与流水线分频器模块4的第一信号输入端相接,根据时钟信号频率与系统输入信号频率确定的外部输入端口设置的分频系数N与流水线分频器模块4的第二输入端相接,流水线分频器模块4的输出信号fout为锁相环输出信号,并将其反馈到数字鉴相器模块1作为数字鉴相器模块1的其中一个输入。The output terminal of the phase error signal ua of the digital phase detector module 1 is connected to the input terminal of the pipeline variable mode controller module 5, and the output terminals of the leading signal ah and the lagging signal be are respectively connected to the first signal input terminal of the pipeline digital filter module 2 and the second signal input terminal are connected, the modulus signal km output terminal of the pipeline variable mode controller module 5 is connected with the third input signal input terminal of the pipeline digital filter module 2, and the carry signal inc of the pipeline digital filter module 2 The output end and the borrow signal dec output end are respectively connected with the two signal input ends of the buckle pulse control circuit module 3, and the signal output end of the buckle pulse control circuit module 3 is connected with the first signal input of the pipeline frequency divider module 4 The ends are connected, and the frequency division coefficient N set according to the external input port determined by the clock signal frequency and the system input signal frequency is connected with the second input end of the pipeline frequency divider module 4, and the output signal fout of the pipeline frequency divider module 4 is The phase locked loop outputs a signal and feeds it back to the digital phase detector module 1 as one of the inputs of the digital phase detector module 1 .

本发明根据流水线电路结构的全数字锁相环的系统结构框图,采用自顶而下的设计方法,基于电子设计自动化技术,采用VHDL语言对各模块进行编程,完成流水线电路结构的全数字锁相环顶层电路设计。According to the system structure diagram of the full digital phase-locked loop of the assembly line circuit structure, the present invention adopts a top-down design method, based on electronic design automation technology, uses VHDL language to program each module, and completes the full digital phase locking of the assembly line circuit structure Ring top circuit design.

在流水线电路结构的全数字锁相环顶层电路中,系统时钟信号clk分别与流水线变模控制器模块5、流水线数字滤波器模块2及加扣脉冲控制电路模块3的输入端clk相接。In the top-level circuit of the all-digital phase-locked loop of the pipeline circuit structure, the system clock signal clk is connected to the input terminal clk of the pipeline variable mode controller module 5, the pipeline digital filter module 2 and the buckling pulse control circuit module 3 respectively.

系统复位信号reset分别与流水线变模控制器模块5、流水线数字滤波器模块2、加扣脉冲控制电路模块3及流水线分频器模块4的输入端reset相接。The system reset signal reset is respectively connected to the input end reset of the pipeline variable mode controller module 5 , the pipeline digital filter module 2 , the buckling pulse control circuit module 3 and the pipeline frequency divider module 4 .

使能信号en与流水线数字滤波器模块2的输入端en相接。The enable signal en is connected to the input end en of the pipeline digital filter module 2 .

系统输入信号fin与数字鉴相器模块1输入端fin相接。The system input signal fin is connected to the input terminal fin of the digital phase detector module 1 .

数字鉴相器模块的输出信号有三个,分别为ah、be及ua,其中ah、be分别与流水线数字滤波器模块2的输入端ah、be相接,ua与流水线变模控制器模块5的输入端ua相接。There are three output signals of the digital phase detector module, namely ah, be and ua, wherein ah and be are respectively connected to the input terminals ah and be of the pipeline digital filter module 2, and ua is connected to the pipeline digital filter module 5's The input terminal ua is connected.

流水线变模控制器模块5的输出端km与流水线数字滤波器模块2的输入端km相接。The output terminal km of the pipeline variable mode controller module 5 is connected to the input terminal km of the pipeline digital filter module 2 .

流水线数字滤波器模块2的两个输出端进位信号inc输出端及借位信号dec分别与加扣脉冲控制电路模块3输入端inc、dec相接。The two output terminals of the pipeline digital filter module 2, the output terminal of the carry signal inc and the output terminal of the borrow signal dec, are respectively connected to the input terminals inc and dec of the buckling pulse control circuit module 3 .

加扣脉冲控制电路模块3的输出端idout与流水线分频器模块4的输入端idout相接。The output terminal idout of the buckling pulse control circuit module 3 is connected to the input terminal idout of the pipeline frequency divider module 4 .

计算系统的时钟信号频率与系统输入信号频率的比值关系,设置分频系数N,将其作为流水线分频器模块4的分频系数N输入端,流水线分频器模块4的输出端fout为系统的输出信号端,同时又反馈到系统的输入端口作为数字鉴相器模块1的输入端。Calculate the ratio relationship between the clock signal frequency of the system and the system input signal frequency, set the frequency division coefficient N, and use it as the input terminal of the frequency division coefficient N of the pipeline frequency divider module 4, and the output terminal fout of the pipeline frequency divider module 4 is the system The output signal end of the system is fed back to the input port of the system as the input end of the digital phase detector module 1 at the same time.

本发明提供的流水线电路结构的全数字锁相环的具体锁相控制过程如下:The specific phase-locked control process of the all-digital phase-locked loop of pipeline circuit structure provided by the present invention is as follows:

数字鉴相器模块1通过检测锁相环输入信号fin和输出信号fout的上升沿,输出相应的相位超前信号ah或滞后信号be及相位误差信号ua。The digital phase detector module 1 outputs the corresponding phase leading signal ah or lagging signal be and phase error signal ua by detecting the rising edge of the phase locked loop input signal fin and output signal fout.

流水线变模控制器模块5对相位误差信号进行数字化和比较,当相位误差较大时,减小送入流水线数字滤波器模块2的模值km;当相位误差较小的时,增大送入流水线数字滤波器模块2的模值km。The pipeline variable modulus controller module 5 digitizes and compares the phase error signal, and when the phase error is large, reduces the modulus km sent to the pipeline digital filter module 2; when the phase error is small, increases the input The modulus km of the pipeline digital filter block 2.

同时,判断数字鉴相器模块1输出的相位超前信号ah和相位滞后信号be的电平,当其输出的相位超前信号ah为高电平时,流水线变模控制器模块5进行加计数,当加计数值达到流水线变模控制器模块5模值km后,流水线数字滤波模块2输出进位信号inc;当数字鉴相器模块1输出的相位滞后信号be为高电平时,流水线变模控制器模块5进行减计数,当减计数值达到模值km后,流水线数字滤波模块2输出借位信号dec。Simultaneously, judge the level of the phase lead signal ah and the phase lag signal be that the digital phase detector module 1 outputs, when the phase lead signal ah of its output is high level, the pipeline modulus controller module 5 carries out counting up, when adding After the count value reaches the modulus value km of the pipeline variable mode controller module 5, the pipeline digital filter module 2 outputs the carry signal inc; when the phase lag signal be output by the digital phase detector module 1 is at a high level, the pipeline variable mode controller module 5 Perform down-counting, and when the down-counting value reaches the modulus km, the pipeline digital filtering module 2 outputs a borrow signal dec.

加扣脉冲控制电路模块3根据流水线数字滤波模块2输出的进位信号inc、借位信号dec,通过加上或减去一个系统时钟周期的时间调整该加扣脉冲控制电路模块3的输出信号idout的相位。The buckle pulse control circuit module 3 adjusts the output signal idout of the buckle pulse control circuit module 3 by adding or subtracting the time of one system clock cycle according to the carry signal inc and the borrow signal dec output by the pipeline digital filter module 2 phase.

流水线分频器模块4根据加扣脉冲控制电路模块输出的数字信号序列,以及根据系统的时钟信号频率与系统输入信号频率的比值确定的分频系数N,输出流水线分频器模块4的输出信号fout送入数字鉴相器模块1,与下一周期输入信号fin共同作为数字鉴相器模块1的输入,产生相应的相位超前信号ah或滞后信号be及相位误差信号ua,依此进行控制,逐渐减小相位误差,并最终实现锁相环的锁定。The pipeline frequency divider module 4 outputs the output signal of the pipeline frequency divider module 4 according to the digital signal sequence output by the buckle pulse control circuit module, and the frequency division coefficient N determined according to the ratio of the clock signal frequency of the system to the system input signal frequency fout is sent to the digital phase detector module 1, and together with the input signal fin of the next period as the input of the digital phase detector module 1, the corresponding phase leading signal ah or lagging signal be and phase error signal ua are generated, and the control is carried out accordingly. Gradually reduce the phase error, and finally achieve the locking of the phase-locked loop.

对流水线电路结构的全数字锁相环电路进行系统仿真,其仿真结果如图5-6所示,其中图5是频率为50MHz时的仿真波形图,图6为输入信号频率由50MHz跳变到25MHz的仿真波形图,图中en为系统使能信号,reset为系统复位信号,clk为系统时钟信号,fin为系统输入信号,fout为系统输出信号。Carry out system simulation on the full digital phase-locked loop circuit with pipeline circuit structure, the simulation results are shown in Figure 5-6, where Figure 5 is the simulation waveform diagram when the frequency is 50MHz, and Figure 6 is the input signal frequency jump from 50MHz to 25MHz simulation waveform diagram, in the figure en is the system enable signal, reset is the system reset signal, clk is the system clock signal, fin is the system input signal, and fout is the system output signal.

由锁相环仿真可知,从图5可以看出,在相位调节区间,锁相环中可逆计数器的模值km 随着相位误差的不同而变化,这样可以加快其锁定速度;在相位锁定区间,则会自动选择本系统所设置的最大模值km,故可大大减小环路输出信号相位的抖动,提高了系统的稳定性。From the simulation of the phase-locked loop, it can be seen from Figure 5 that in the phase adjustment interval, the modulus km of the reversible counter in the phase-locked loop varies with the phase error, which can speed up its locking speed; in the phase lock interval, It will automatically select the maximum modulus km set by the system, so it can greatly reduce the jitter of the loop output signal phase and improve the stability of the system.

从图6可以看出,当输入频率发生跳变时,锁相环能够在输入信号频率发生跳变后的第一个周期内快速锁定信号的频率,并迅速对相位误差进行调整,大约经过2.5μs便可锁定,且锁定后同样自动选择最大的km值。该锁相环能够根据其不同的工作过程对系统参数进行动态调节,从根本上解决了提高锁定速度与稳定性之间的矛盾,提高了锁相系统的整体性能。It can be seen from Figure 6 that when the input frequency jumps, the phase-locked loop can quickly lock the frequency of the signal in the first period after the frequency jump of the input signal, and quickly adjust the phase error. After about 2.5 It can be locked within μs, and the maximum km value is also automatically selected after locking. The phase-locked loop can dynamically adjust system parameters according to its different working processes, fundamentally solves the contradiction between improving the locking speed and stability, and improves the overall performance of the phase-locked system.

取系统的时钟信号频率为200MHZ,系统的输入信号频率为50MHZ时,分别对传统锁相环和流水线锁相环进行了系统仿真,并对仿真结果进行时序分析和功耗分析。具体结果分析如表1所示:When the clock signal frequency of the system is 200MHZ, and the input signal frequency of the system is 50MHZ, the system simulation is carried out on the traditional phase-locked loop and the pipeline phase-locked loop respectively, and the timing analysis and power consumption analysis are carried out on the simulation results. The specific result analysis is shown in Table 1:

表1 clk=200 MHZ,fin=50 MHZ结果比较Table 1 clk=200 MHZ, fin=50 MHZ result comparison

延时/(ns)Delay/(ns) 功耗/(μW)Power consumption/(μW) 传统ADPLLTraditional ADPLL 3.4243.424 117390117390 流水线ADPLLPipelined ADPLL 2.1462.146 116760116760

从表1可以看出,首先,与传统的锁相环相比,流水线电路结构锁相环的系统延时减少了1.278ns。其次,时钟频率为200MHZ时,其系统的总功耗比传统的锁相环减少了630μW。由此可见,具有流水线电路结构的全数字锁相环可以减少系统延时,提高系统的工作速度,并可减少系统的总功耗。It can be seen from Table 1 that, first of all, compared with the traditional PLL, the system delay of the PLL with pipeline circuit structure is reduced by 1.278ns. Secondly, when the clock frequency is 200MHZ, the total power consumption of the system is reduced by 630μW compared with the traditional PLL. It can be seen that the all-digital phase-locked loop with pipeline circuit structure can reduce the system delay, improve the working speed of the system, and reduce the total power consumption of the system.

Claims (1)

1.流水线电路结构的全数字锁相环的锁相控制方法,其特征在于:1. the phase-locked control method of the all-digital phase-locked loop of pipeline circuit structure, it is characterized in that: 所述流水线电路结构的全数字锁相环包括数字鉴相器模块、流水线变模控制器模块、流水线数字滤波器模块、加扣脉冲控制电路模块和流水线分频器模块,利用电子设计自动化技术完成各个模块电路的设计;The all-digital phase-locked loop of the pipeline circuit structure includes a digital phase detector module, a pipeline variable mode controller module, a pipeline digital filter module, a buckling pulse control circuit module and a pipeline frequency divider module, and is completed by electronic design automation technology Design of each module circuit; 数字鉴相器模块由双D触发器实现,该数字鉴相器模块具有两个信号输入端及三个信号输出端,两个信号输入端分别为fin信号输入端及fout信号输入端,三个信号输出端分别为ua信号输出端、ah信号输出端及be信号输出端,数字鉴相器模块通过检测全数字锁相环输入信号fin与输出信号fout的上升沿,判断其相位误差和极性,并生成反映输入与输出信号之间的相位误差信号ua,以及极性信号,即超前信号ah和滞后信号be;The digital phase detector module is realized by double D flip-flops. The digital phase detector module has two signal input terminals and three signal output terminals. The two signal input terminals are respectively the fin signal input terminal and the fout signal input terminal. The signal output terminals are ua signal output terminal, ah signal output terminal and be signal output terminal respectively. The digital phase detector module judges the phase error and polarity by detecting the rising edge of the input signal fin and the output signal fout of the full digital phase locked loop. , and generate a signal ua reflecting the phase error between the input and output signals, and a polarity signal, that is, the leading signal ah and the lagging signal be; 流水线变模控制器模块包括时间数字转换模块TDC和变模控制器,流水线变模控制器模块为流水线数字滤波器提供可调的动态参数,接收数字鉴相器模块输出的相位误差信号ua,并根据该相位误差信号ua的大小来调节流水线变模控制器模块输出的模值km,具体的调节方式为:当相位误差较大时,输出较小的模值km,以便加快锁相速度;当相位误差较小时,输出较大的模值km,以减小环路锁定后的相位抖动;The pipeline variable mode controller module includes a time-to-digital conversion module TDC and a variable mode controller. The pipeline variable mode controller module provides adjustable dynamic parameters for the pipeline digital filter, receives the phase error signal ua output by the digital phase detector module, and According to the size of the phase error signal ua, the modulus km output by the pipeline variable mode controller module is adjusted. The specific adjustment method is: when the phase error is large, a smaller modulus km is output in order to speed up the phase locking speed; When the phase error is small, a larger modulus km is output to reduce the phase jitter after the loop is locked; 其中时间数字转换模块TDC包括20位计数器,20位计数器采用五级流水线设计,每一级计数器M包括寄存器J、加1器和用于暂存计数值的锁存器S,其中第一级计数器的位数为0-3位,第二级计数器位数为4-7位,第三级计数器的位数为8-11位,第四级计数器的位数为12-15位,第五级计数器位数为16-19位,采用超高速集成电路硬件描述语言完成对时间数字转换模块TDC的设计,再与变模控制器连接,得到流水线自动变模控制器模块;根据数字鉴相器模块输出的相位误差信号ua,为流水线数字滤波器模块中的可逆计数器提供可变模值的输出信号km;The time-to-digital conversion module TDC includes a 20-bit counter, and the 20-bit counter adopts a five-stage pipeline design. Each stage of the counter M includes a register J, an adder and a latch S for temporarily storing the count value. The first stage of the counter The digits of the counter are 0-3 digits, the digits of the second-stage counter are 4-7 digits, the digits of the third-stage counter are 8-11 digits, the digits of the fourth-stage counter are 12-15 digits, and the fifth-stage counters are 12-15 digits. The number of counters is 16-19 bits, and the design of the time-to-digital conversion module TDC is completed by using the ultra-high-speed integrated circuit hardware description language, and then connected with the variable-mode controller to obtain the pipeline automatic variable-mode controller module; according to the digital phase detector module The output phase error signal ua provides the output signal km of variable modulus for the reversible counter in the pipeline digital filter module; 流水线数字滤波器模块由8位可逆计数器构成,该可逆计数器采用二级流水线设计,每一级计数器M包括寄存器J、加1器和用于暂存计数值的锁存器S;其中第一级计数器的位数为0-3位,第二级计数器为位数为4-7位,可逆计数器的模值是流水线变模控制器模块按照预设的控制算法自动生成的;该流水线数字滤波器模块接收来自数字鉴相器模块根据输入信号fin与输出反馈信号fout比较得到的超前信号ah和滞后信号be,根据超前信号ah或滞后信号be进行加计数或减计数,当计数值达到接收到的计数器的模值时,产生进位信号inc或借位信号dec,并分别送给加扣脉冲控制电路模块;The pipeline digital filter module is composed of an 8-bit reversible counter. The reversible counter adopts a two-stage pipeline design. Each stage of the counter M includes a register J, an adder and a latch S for temporarily storing the count value; the first stage The number of digits of the counter is 0-3 digits, the number of digits of the second stage counter is 4-7 digits, the modulus value of the reversible counter is automatically generated by the pipeline variable mode controller module according to the preset control algorithm; the pipeline digital filter The module receives the leading signal ah and the lagging signal be obtained from the digital phase detector module according to the comparison between the input signal fin and the output feedback signal fout, and counts up or down according to the leading signal ah or the lagging signal be. When the count value reaches the received When the modulus value of the counter is generated, a carry signal inc or a borrow signal dec is generated and sent to the plus and minus pulse control circuit module respectively; 加扣脉冲控制电路模块接收流水线数字滤波器模块发送的进位信号inc或借位信号dec,对其输出的数字序列信号进行脉冲的加扣处理,并将处理后的数字序列信号发送到流水线分频器模块;具体的实现方式为:当加扣脉冲控制电路模块输入端的进位信号inc为高电平时,在其输出的数字序列信号中插入一个脉冲;当加扣脉冲控制电路模块另一输入端的借位信号dec为高电平时,在其输出的数字序列信号中扣除一个脉冲,并将经过加扣脉冲处理后的数字序列信号发送到流水线分频器模块作进一步的调节;The plus and minus pulse control circuit module receives the carry signal inc or the borrow signal dec sent by the pipeline digital filter module, performs pulse plus and minus processing on the output digital sequence signal, and sends the processed digital sequence signal to the pipeline for frequency division device module; the specific implementation method is: when the carry signal inc at the input terminal of the buckling pulse control circuit module is high level, a pulse is inserted in the digital sequence signal output by it; When the bit signal dec is at a high level, a pulse is subtracted from the output digital sequence signal, and the digital sequence signal processed by adding the pulse is sent to the pipeline frequency divider module for further adjustment; 流水线分频器模块由24位计数器构成,其分频系数N可调;该24位计数器采用三级流水线设计,每一级计数器M包括寄存器J、加1器和用于暂存计数值的锁存器S;每一级为一个8位计数器,其中第一级计数器的位数为0-7位,第二级计数器位数为8-15位,第三级计数器的位数为16-23位;每当低一级的8位计数器产生进位信号时,触发高一级的8位计数器开始计数,以此进行累加计数;该分频系数N从外部输入端口设置,即根据该锁相环输入信号频率的不同,灵活设置分频系数的具体参数;该参数的设置是按照系统的时钟信号频率与系统输入信号频率的比值满足2N来选择的;The pipeline frequency divider module is composed of a 24-bit counter, and its frequency division factor N is adjustable; the 24-bit counter adopts a three-stage pipeline design, and each stage of the counter M includes a register J, an adder and a lock for temporarily storing the count value Register S; each level is an 8-bit counter, in which the number of bits of the first level counter is 0-7 bits, the number of bits of the second level counter is 8-15 bits, and the number of bits of the third level counter is 16-23 bit; whenever the 8-bit counter of the lower level generates a carry signal, the 8-bit counter of the higher level is triggered to start counting, so as to perform cumulative counting; the frequency division coefficient N is set from the external input port, that is, according to the phase-locked loop The frequency of the input signal is different, and the specific parameters of the frequency division coefficient can be flexibly set; the setting of this parameter is selected according to the ratio of the system clock signal frequency to the system input signal frequency satisfying 2 N ; 数字鉴相器模块的相位误差信号ua输出端与流水线变模控制器模块的输入端相接,超前信号ah和滞后信号be输出端分别与流水线数字滤波器模块的第一信号输入端及第二信号输入端相接,流水线变模控制器模块的模值信号km输出端与流水线数字滤波器模块的第三输信号入端相接,流水线数字滤波器模块的进位信号inc输出端及借位信号dec输出端分别与加扣脉冲控制电路模块的两个信号输入端相接,加扣脉冲控制电路模块的信号输出端与流水线分频器模块的第一信号输入端相接,根据时钟信号频率与系统输入信号频率确定的外部输入端口设置的分频系数N与流水线分频器模块的第二输入端相接,流水线分频器模块的输出信号fout为锁相环输出信号,并将其反馈到数字鉴相器模块作为数字鉴相器模块的其中一个输入;The output terminal of the phase error signal ua of the digital phase detector module is connected with the input terminal of the pipeline variable mode controller module, and the output terminals of the leading signal ah and the lag signal be are respectively connected with the first signal input terminal and the second signal terminal of the pipeline digital filter module. The signal input terminals are connected, the modulus signal km output terminal of the pipeline variable mode controller module is connected with the third input signal input terminal of the pipeline digital filter module, the carry signal inc output terminal of the pipeline digital filter module and the borrow signal The dec output ends are respectively connected with the two signal input ends of the buckle pulse control circuit module, the signal output end of the buckle pulse control circuit module is connected with the first signal input end of the pipeline frequency divider module, according to the clock signal frequency and The frequency division factor N set by the external input port of the system input signal frequency is connected with the second input terminal of the pipeline frequency divider module, and the output signal fout of the pipeline frequency divider module is a phase-locked loop output signal, and it is fed back to The digital phase detector module is used as one of the inputs of the digital phase detector module; 该流水线电路结构的全数字锁相环采用自顶而下的设计方法,基于电子设计自动化技术,采用VHDL语言对各模块进行编程,完成流水线电路结构的全数字锁相环顶层电路设计;The full digital phase-locked loop of the pipeline circuit structure adopts a top-down design method, based on electronic design automation technology, uses VHDL language to program each module, and completes the top-level circuit design of the full digital phase-locked loop of the pipeline circuit structure; 在流水线电路结构的全数字锁相环顶层电路中,系统时钟信号clk分别与流水线变模控制器模块、流水线数字滤波器模块及加扣脉冲控制电路模块的输入端clk相接;In the top-level circuit of the all-digital phase-locked loop of the pipeline circuit structure, the system clock signal clk is connected to the input terminal clk of the pipeline variable mode controller module, the pipeline digital filter module and the buckle pulse control circuit module respectively; 系统复位信号reset分别与流水线变模控制器模块、流水线数字滤波器模块、加扣脉冲控制电路模块及流水线分频器模块的输入端reset相接;The system reset signal reset is respectively connected with the input terminal reset of the pipeline variable mode controller module, the pipeline digital filter module, the buckle pulse control circuit module and the pipeline frequency divider module; 使能信号en与流水线数字滤波器模块的输入端en相接;The enable signal en is connected to the input terminal en of the pipeline digital filter module; 系统输入信号fin与数字鉴相器模块输入端fin相接;The system input signal fin is connected to the input terminal fin of the digital phase detector module; 数字鉴相器模块的输出信号有三个,分别为ah、be及ua,其中ah、be分别与流水线数字滤波器模块的输入端ah、be相接,ua与流水线变模控制器模块的输入端ua相接;There are three output signals of the digital phase detector module, namely ah, be and ua, where ah and be are respectively connected to the input terminals ah and be of the pipeline digital filter module, and ua is connected to the input terminal of the pipeline variable mode controller module ua connected; 流水线变模控制器模块的输出端km与流水线数字滤波器模块的输入端km相接;The output terminal km of the pipeline variable mode controller module is connected with the input terminal km of the pipeline digital filter module; 流水线数字滤波器模块的两个输出端进位信号inc输出端及借位信号dec分别与加扣脉冲控制电路模块输入端inc、dec相接;The two output terminals of the pipeline digital filter module, the carry signal inc output terminal and the borrow signal dec, are respectively connected to the input terminals inc and dec of the buckle pulse control circuit module; 加扣脉冲控制电路模块的输出端idout与流水线分频器模块的输入端idout相接;The output terminal idout of the buckle pulse control circuit module is connected with the input terminal idout of the pipeline frequency divider module; 计算系统的时钟信号频率与系统输入信号频率的比值关系,设置分频系数N,将其作为流水线分频器模块的分频系数N输入端,流水线分频器模块的输出端fout为系统的输出信号端,同时又反馈到系统的输入端口作为数字鉴相器模块的输入端;Calculate the ratio relationship between the clock signal frequency of the system and the system input signal frequency, set the frequency division coefficient N, and use it as the input terminal of the frequency division coefficient N of the pipeline frequency divider module, and the output terminal fout of the pipeline frequency divider module is the output of the system The signal terminal is also fed back to the input port of the system as the input terminal of the digital phase detector module; 数字鉴相器模块通过检测锁相环输入信号fin和输出信号fout的上升沿,输出相应的相位超前信号ah或滞后信号be及相位误差信号ua;The digital phase detector module outputs the corresponding phase leading signal ah or lagging signal be and phase error signal ua by detecting the rising edge of the phase locked loop input signal fin and output signal fout; 流水线变模控制器模块对相位误差信号进行数字化和比较,当相位误差较大时,减小送入流水线数字滤波器模块的模值km;当相位误差较小的时,增大送入流水线数字滤波器模块的模值km;The pipeline variable mode controller module digitizes and compares the phase error signal. When the phase error is large, the modulus km sent to the pipeline digital filter module is reduced; when the phase error is small, the digital value sent to the pipeline is increased. The modulus km of the filter module; 同时,判断数字鉴相器模块输出的相位超前信号ah和相位滞后信号be的电平,当其输出的相位超前信号ah为高电平时,流水线变模控制器模块进行加计数,当加计数值达到流水线变模控制器模块模值km后,流水线数字滤波模块输出进位信号inc;当数字鉴相器模块输出的相位滞后信号be为高电平时,流水线变模控制器模块进行减计数,当减计数值达到模值km后,流水线数字滤波模块输出借位信号dec;At the same time, judge the level of the phase lead signal ah and the phase lag signal be output by the digital phase detector module. When the phase lead signal ah output by the digital phase detector module is at a high level, the pipeline variable mode controller module performs counting up. When the counting value After reaching the modulus km of the pipeline variable mode controller module, the pipeline digital filter module outputs the carry signal inc; when the phase lag signal be output by the digital phase detector module is at a high level, the pipeline variable mode controller module counts down. After the count value reaches the modulus km, the pipeline digital filter module outputs the borrow signal dec; 加扣脉冲控制电路模块根据流水线数字滤波模块输出的进位信号inc、借位信号dec,通过加上或减去一个系统时钟周期的时间调整该加扣脉冲控制电路模块的输出信号idout的相位;The buckle pulse control circuit module adjusts the phase of the output signal idout of the buckle pulse control circuit module by adding or subtracting the time of one system clock cycle according to the carry signal inc and the borrow signal dec output by the pipeline digital filter module; 流水线分频器模块根据加扣脉冲控制电路模块输出的数字信号序列,以及根据系统的时钟信号频率与系统输入信号频率的比值确定的分频系数N,输出流水线分频器模块的输出信号fout送入数字鉴相器模块,与下一周期输入信号fin共同作为数字鉴相器模块的输入,产生相应的相位超前信号ah或滞后信号be及相位误差信号ua,依此进行控制,逐渐减小相位误差,并最终实现锁相环的锁定。The pipeline frequency divider module outputs the output signal fout of the pipeline frequency divider module according to the digital signal sequence output by the buckle pulse control circuit module and the frequency division coefficient N determined according to the ratio of the system clock signal frequency to the system input signal frequency. into the digital phase detector module, together with the input signal fin of the next period as the input of the digital phase detector module, to generate the corresponding phase leading signal ah or lagging signal be and phase error signal ua, and control accordingly to gradually reduce the phase error, and finally realize the locking of the phase-locked loop.
CN201811181639.9A 2018-10-11 2018-10-11 All-digital phase-locked loop of pipeline circuit structure and phase-locked control method Active CN109150168B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201811181639.9A CN109150168B (en) 2018-10-11 2018-10-11 All-digital phase-locked loop of pipeline circuit structure and phase-locked control method

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201811181639.9A CN109150168B (en) 2018-10-11 2018-10-11 All-digital phase-locked loop of pipeline circuit structure and phase-locked control method

Publications (2)

Publication Number Publication Date
CN109150168A CN109150168A (en) 2019-01-04
CN109150168B true CN109150168B (en) 2023-08-29

Family

ID=64811549

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201811181639.9A Active CN109150168B (en) 2018-10-11 2018-10-11 All-digital phase-locked loop of pipeline circuit structure and phase-locked control method

Country Status (1)

Country Link
CN (1) CN109150168B (en)

Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US6404247B1 (en) * 1995-11-13 2002-06-11 Industrial Technology Research Institute All digital phase-locked loop
CN101160722A (en) * 2005-04-18 2008-04-09 Nxp股份有限公司 Circuit arrangement, in particular phase-locked loop, as well as corresponding method
WO2008139064A2 (en) * 2007-04-06 2008-11-20 Centre National D'etudes Spatiales (C.N.E.S.) Clock extraction device with digital phase lock, requiring no external control
US8674731B1 (en) * 2013-01-22 2014-03-18 Applied Micro Circuits Corporations Fractional phase-locked loop with dynamic divide ratio adjustment

Patent Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US6404247B1 (en) * 1995-11-13 2002-06-11 Industrial Technology Research Institute All digital phase-locked loop
CN101160722A (en) * 2005-04-18 2008-04-09 Nxp股份有限公司 Circuit arrangement, in particular phase-locked loop, as well as corresponding method
WO2008139064A2 (en) * 2007-04-06 2008-11-20 Centre National D'etudes Spatiales (C.N.E.S.) Clock extraction device with digital phase lock, requiring no external control
US8674731B1 (en) * 2013-01-22 2014-03-18 Applied Micro Circuits Corporations Fractional phase-locked loop with dynamic divide ratio adjustment

Non-Patent Citations (1)

* Cited by examiner, † Cited by third party
Title
一种可编程全数字锁相环的设计与实现;李凤华;刘丹丹;单长虹;;计算机测量与控制(01);全文 *

Also Published As

Publication number Publication date
CN109150168A (en) 2019-01-04

Similar Documents

Publication Publication Date Title
US10707854B2 (en) Clock screening with programmable counter-based clock interface and time-to-digital converter with high resolution and wide range operation
CN102832914B (en) A kind of digital pulse width modulator circuit
CN109818613B (en) Reference clock frequency multiplier circuit and method based on numerical control delay duty cycle calibration
CN104202048B (en) Broadband totally-integrated phase-locked loop frequency synthesizer
CN104038215B (en) A kind of ∑ △ fractional frequencies synthesizer automatic frequency calibration circuit
TWI477946B (en) Calibration device and related method for phase difference between data and clock
CN104954016A (en) Rapidly-adaptive all-digital phase-locked loop and design method thereof
TW200427224A (en) Clock multiplier
CN111884631A (en) A Digital Pulse Width Modulation Module Using Hybrid Structure
CN107565956B (en) VCO frequency band switching circuit and loop switching method applied in dual loop clock data recovery circuit
TWI556584B (en) Phase detecting apparatus and phase adjusting method
CN105959001B (en) Become frequency domain all-digital phase-locked loop and locking phase control method
CN116582131A (en) Digital-to-time converter circuit architecture with gain adjustment and integral nonlinear calibration
CN106972867A (en) A kind of filter calibration device, filter calibration method and digital receiver
CN104391464B (en) A kind of hardware equivalent synchronized sampling unit based on FPGA
CN106301357A (en) All-digital phase-locked loop
CN109714046B (en) All-digital phase-locked loop with variable phase accumulator circuit structure and phase-locked control method
CN109150168B (en) All-digital phase-locked loop of pipeline circuit structure and phase-locked control method
CN103986460B (en) SoC chip internal clock generation circuit using unlocking indicating phase-locked loop
CN110581708B (en) Frequency Locked Loop Full Digital Frequency Synthesizer
CN109905128B (en) Self-adaptive high-speed SAR-ADC conversion time full utilization circuit and method
CN113452365B (en) Automatic frequency correction circuit and correction method suitable for under-sampling phase-locked loop
CN208508904U (en) A kind of delay locked loop system of digital successive approximation register of nearly threshold voltage
CN208386516U (en) The all-digital phase-locked loop of pipelined circuit
CN110166045B (en) A Snapshot Circuit for Extracting Signal Change Edges

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
GR01 Patent grant
GR01 Patent grant