# Patent

## Title
Autoconfigurable phase-locked loop which automatically maintains a constant damping factor and adjusts the loop bandwidth to a constant ratio of the reference frequency

## Abstract

A phase-locked loop (PLL) includes a state machine programmed to automatically produce a set of control signals to select a charge-pump current and integrating capacitance value to automatically adjust a loop bandwidth of the PLL. A charge-pump DAC generates a charge-pump current of magnitude controlled by the state machine control signals. An integrator integrates the charge-pump output current to produce an integrated charge-pump output signal. The integrator has a plurality of capacitors switchably selected by control signals from the state machine to produce an integrating capacitance value. A voltage controlled oscillator (VCO) produces a PLL output frequency in response to the integrated charge-pump output signal.

## Background
CROSS-REFERENCE TO RELATED APPLICATIONS
This application claims the priority benefit of U.S. provisional patent application No. 61/498,922, filed Jun. 20, 2011, which is assigned to the assignee hereof and incorporated herein by reference in its entirety.


BACKGROUND
1. Field
The various circuit embodiments described herein relate in general to phase-locked loops (PLLs), and, more specifically, to PLLs and methods for making and using the same in which the loop bandwidth scales with PLL the reference frequency while maintaining a constant damping factor, FREF, without a requirement that the value of the reference frequency, FREF, be known.
2. Background
An example of a typical phase-locked loop circuit (PLL) 10 is shown in FIG. 1, to which reference is now made. The PLL 10 has a digital phase-frequency detector (DPFD) 12, herein sometimes referred to as a “phase detector,” that receives a reference frequency (FREF) signal on a first input line 14 and a feedback signal on a second input line 16. The DPFD 12 determines whether the phase of the feedback signal leads or lags the phase of the reference frequency, FREF, to command either an up or down signal on output lines 18 and 20, respectively. The up command, for example, indicates that the phase of the feedback signal leads the phase of the reference frequency, FREF, and the down command indicates that the phase of the feedback signal lags the phase of the reference frequency, FREF.
The signal on the up output line 18 controls a switch 22 to apply current from a first current source 24 to an integrator 26 to increase the voltage on the input 27 of the transconductance amplifier 28. The signal on the down output line 20 controls a switch 30 to sink current through a second current source 32 from the integrator 26 to a reference potential, or ground, to decrease the voltage on the input of the transconductance amplifier 28. The integrator 26 has a first capacitor 34 between the input 27 to the transconductance amplifier 28 and a reference potential or ground. In addition, the integrator 26 has a resistor 36 and a second capacitor 38 in series between the input to the transconductance amplifier 28 and the reference potential, or ground.
The transconductance amplifier 28 produces an output current, IVCO, on line 40 to control the frequency of a voltage-controlled oscillator (VCO) 42. The VCO 42 produces a base output frequency on line 44 that is proportional to the input voltage to the transconductance amplifier 28, which, as described above, is proportional to the amount of lead or lag of the phase of the feedback voltage on line 16 with respect to the reference frequency, FREF. The base output frequency from the VCO 42 on line may be divided by a number, for example QDIV, by a frequency divider 46 to provide a PLL frequency output, FOUT, on output line 48. The base frequency output from the VCO 42 on line 44 may also be divided by a number, for example, MDIV, to provide a frequency output on feedback line 16 to the second input of the DPFD 12 for comparison with the reference frequency, FREF. The base frequency output from the VCO 42 can also be feedback to the DPFD 12 by another means to make a comparison with the reference frequency, FREF.
One of the problems, however, especially for a chip manufacturer, is that often the value of the reference frequency, FREF, that customers may employ in the operation of the PLL is not known. Consequently, the design of a single PLL that is suitable for diverse purposes can be very difficult. Moreover, PLLs are often designed to operate over a large reference frequency range. For example in some applications, the reference frequency, FREF, may be anywhere in a range between 2 MHz and 30 MHz.
This can be appreciated from an analysis of the loop behavior of the circuit 10 of FIG. 1, which can be modeled by the phase-domain model 50 of FIG. 2, to which reference is now additionally made. In the phase-domain model 50 of FIG. 2, the phase of the input signal, φREF, is applied on line 52 to an adder 54, the output of which is applied to a loop filter 56. The loop filter 56 models the transistor level response of the feedback loop of the circuit 10 of FIG. 1. The output of the loop filter 56 is applied to a transconductance amplifier 58, which produces an output that is applied to an integrating capacitor 60 and to a delay block 62. The transconductance amplifier 58 along with the integrating capacitor 60 models the behavior of the transconductor circuit 28, VCO 42, and feedback divider 47 of FIG. 1. The delay supplied by the delay block models the sample and hold delay of the DPFD 12, which in the example illustrated is chosen to be equal to 0.6 times the time period of the FREF signal. The output of the delay block 62 is subtracted in the adder 54 from the input phase reference signal, φREF, on line 52. To complete the model of the loop behavior, KVCO is simulated from the given oscillator architecture.
FIG. 3, to which reference is now additionally made, is a graph of closed loop gain in dB verses frequency for two input reference frequencies of 2 megahertz and 30 megahertz. Thus, for a range of reference frequencies, FREFs, between 2 MHz and 30 MHz (the actual value being unknown)+NDIV (the actual value being unknown) the following issues occur.
A typical PLL is designed with a loop-bandwidth of less than FREF/10 in order to get a stable response from the PLL across all process and voltage corners. Higher loop-bandwidth translates to faster settling time for the PLL 10. However, the absolute value of the bandwidth can be chosen based on the particular application in which the PLL is used. The zero 66 of the loop-filter which is formed by resistor 36 and capacitor 38 is usually chosen to be a factor 1/K1 of the loop-bandwidth. The absolute value of the factor 1/K1 can change with the intended application. As an example, in this embodiment the factor is set at K1=3, so zero 66 is parked near 66 KHz. The pole 68, which is formed by resistor 36 and the series combination of capacitor 34 and capacitor 38, is usually chosen to be a factor K2 of the loop-bandwidth. In this embodiment the value of K2 is chosen to be 3 so pole 68 is set at 600 KHz.
With the above combination of loop-filter pole and zero, the bandwidth comes close to desired value of 200 KHz as shown by curve 67 of FIG. 3. The value of the charge-pump is chosen in conjunction of loop-gain such that the loop is stable and loop-peaking is met for the application. Now if a traditional PLL, which is designed for FREF=2 MHz and output of 400 MHz, is used with input FREF=30 MHz, then it does not work, because for 30 MHz PLL, the desired loop-bandwidth would be 3 MHz and in that case both designed zero 66 and pole 68 will come inside the loop-bandwidth as shown in FIG. 4. As a result the PLL loop frequency response becomes the curve 72 shown in FIG. 3 which has over 20 dB of peaking. This implies that system has gone unstable.
Another challenge is that it is desirable for the output frequency, FOUT, be in a range between 100 MHz and 500 MHz. The applicable formulae are:



  
    LG
    =
    
      
        
          I
          CP
        
        ⁢
        
          K
          v
        
        ⁢
        
          K
          LPF
        
      
      M
    
  




  
    
      ω
      n
    
    =
    
      
        
          
            I
            CP
          
          ⁢
          
            K
            v
          
        
        
          MC
          1
        
      
    
  




  
    ζ
    =
    
      
        1
        2
      
      ⁢
      
        
          
            
              I
              CP
            
            ⁢
            
              K
              v
            
            ⁢
            
              C
              1
            
          
          M
        
      
      ⁢
      
        R
        1
      
    
  




  
    
      ω
      u
    
    =
    
      
        
          I
          CP
        
        ⁢
        
          K
          v
        
        ⁢
        
          R
          1
        
      
      M
    
  



where:

    LG is the loop gain
    ICP is the charge-pump current
    Kv is the gain of the VCO 42
    KLPF is the response of the loop low-pass filter 56
    M is the frequency divisor in the feedback loop
    ωn is the natural frequency of the loop
    C1 is the capacitance of the loop zero capacitor 60
    ζ is the loop damping factor
    R1 is the resistance of the loop zero resistor 36
    ωu is the frequency of the unity gain cross-over point


For the case where the loop frequency, FREF, is 2 MHz, the loop bandwidth is 200 KHz, and the zero is at 50 KHz, the charge-pump current, ICP, is chosen so that the damping factor, ζ, is approximately 1 for an output frequency, FOUT, of 400 MHz. This can be seen in the graph of loop gain verses frequency of FIG. 5, to which reference is now additionally made. The curve 80 shows the 400 MHz frequency response and curve 82 shows a 100 MHz frequency response. Over an output frequency range between 100 MHz and 500 MHz, with ICP held constant and MDIV varying from 50 to 250, it can be seen that the loop gain has an increase factor of five, and is only marginally stable. Thus, even though the reference frequency, FREF, may be known, loop may become unstable. Therefore, in order to maintain loop stability, the traditional approach requires the user to specify information about the reference frequency, FREF, to enable the charge-pump current, ICP, to be scaled with respect to the frequency divider, MDIV.
Nevertheless, even though a reference frequency, FREF, may be specified, as a practical matter, most PLL designs are optimized for only a few reference frequencies, FREFs. For other reference frequencies, FREFs, the damping factor, ζ, may still change. Changes in the damping factor, ζ, may cause overshoot and stress the device.
What is needed, therefore, is a PLL and method for making and using it in which the loop bandwidth scales with the reference frequency, FREF, whereby it is not necessary to actually know the reference frequency, FREF. Also needed is an autoconfigurable phase-locked loop which automatically maintains a constant damping factor and adjusts the loop bandwidth to a constant ratio of the reference frequency.
SUMMARY
According to one embodiment disclosed herein, a phase-locked loop (PLL) includes a frequency detector for detecting a frequency of an unknown reference frequency and a phase detector for generating up and down command signals in response to phase differences between the unknown reference frequency and a frequency related to a base PLL output frequency. A circuit is provided for producing control signals in dependence upon the frequency detected by the frequency detector. A charge-pump DAC generates a charge-pump current and is connected to receive the up and down command signals and control signals from the circuit for producing control signals to produce a charge-pump output current of magnitude selected by the control signals from the circuit for producing control signals. An integrator integrates the charge-pump output current and has a plurality of capacitors switchably selected by control signals from the circuit for producing control signals to produce an integrating capacitance value. A voltage controlled oscillator (VCO) produces the base PLL output frequency in response to the integrated charge-pump output signal. In one embodiment, the circuit for producing control signals is a state machine that is programmed to automatically produce a set of control signals to select a charge-pump current and integrating capacitance value to automatically adjust a loop bandwidth of the PLL.
According to another embodiment disclosed herein, a phase-locked loop (PLL) includes means for automatically adjusting a loop bandwidth without requiring knowledge of a reference frequency of the PLL. The means for automatically adjusting the loop bandwidth includes a circuit for measuring a frequency related to the reference frequency, a state machine for producing logic states corresponding to the frequency related to the reference frequency, a first digital-to-analog converter connected to adjust capacitances in the PLL according to the logic states of the state machine, and a second digital-to-analog converter connected to modify a charge-pump current to an integrator of the PLL according to the logic states of the state machine. The PLL 1 automatically maintains a constant damping factor.
According to yet another embodiment disclosed herein a method is provided for automatically adjusting a loop bandwidth of a phase-locked loop (PLL). The method includes detecting a frequency of an unknown reference frequency and generating up and down command signals in response to phase differences between the unknown reference frequency and a PLL output frequency. Control signals are developed, depending on the detected frequency. In one embodiment, the control signals are developed by a state machine. A charge-pump current of magnitude established by the control signals is generated, and an integrated charge-pump current is produced using capacitors selected according to the control signals. The frequency of a voltage controlled oscillator (VCO) is adjusted, based on the integrated charge-pump current to producing the PLL output frequency.



BRIEF DESCRIPTION OF THE DRAWINGS
FIG. 1 is an electrical schematic diagram showing an example of a typical phase-locked loop (PLL) circuit.
FIG. 2 is an electrical schematic diagram of a phase-domain model that models the loop behavior of the PLL of FIG. 1.
FIG. 3 is a graph of loop gain in dB verses frequency in megahertz for reference frequencies of 2 megahertz and 30 megahertz.
FIG. 4 is a graph of frequency illustrating the pole and zero of the PLL of FIG. 1 in relation to stable and unstable 3 dB crossover points.
FIG. 5 is a graph of loop gain verses frequency of a PLL, comparing frequency responses of 100 MHz and 400 MHz in the PLL of FIG. 1.
FIG. 6 is an electrical schematic diagram showing an example of an autoconfigurable phase-locked loop (PLL) circuit that automatically adjusts the loop bandwidth and maintains a constant damping factor.
FIG. 7 is an electrical schematic diagram showing an example of a frequency detector circuit for providing input states to the state machine of FIG. 6.
FIG. 8 is a state table showing an example of various states of a state machine for controlling a charge-pump DAC and capacitor DACs for reference frequencies of 2 MHz and 30 MHz, and output frequencies of 100 MHz, 400 MHz, and 600 MHz.
FIG. 9 is an electrical schematic diagram showing an example of a charge-pump DAC that may be employed in the autoconfigurable phase-locked loop (PLL) circuit of FIG. 6.
FIG. 10 shows the quantization error of the charge-pump DAC of FIG. 9.
FIG. 11 is an electrical schematic diagram showing an example of a capacitor-DAC circuit that may be employed in the autoconfigurable phase-locked loop (PLL) circuit of FIG. 6.
FIGS. 12 and 13 are graphs respectively showing step and frequency response in the PVT corners.



In the various figures of the drawing, like reference numbers are used to denote like or similar parts.
DETAILED DESCRIPTION
FIG. 6 is an electrical schematic diagram showing an example of an autoconfigurable phase-locked loop (APLL) circuit 90 that automatically adjusts the loop bandwidth and maintains a constant damping factor. The APLL circuit 90 receives the reference frequency, FREF, on input line 14 to a user programmable pre-divider circuit 92 to produce an internal reference frequency FREF_INT on line 94. The internal reference frequency FREF_INT is connected to a digital phase-frequency detector (DPFD) 12 as well as a frequency detector 96. The DPFD 12 develops up and down charge-pump command DAC signals on respective lines 18 and 20 in the manner described above with reference to FIG. 1, depending on whether the phase of the feedback signal on line 16 leads or lags the phase of the internal reference frequency FREF_INT.
A charge-pump DAC circuit 98, described in greater detail with reference to FIG. 9 below, has an output on line 27 that is integrated by an integrator 100 to increase or decrease the input voltage on the transconductance amplifier 28. The charge-pump DAC 98 includes a number of switches that may be connected in various combinations to provide selected charge-pump currents, depending on the value of the internal reference frequency, FREF_INT.
The integrator 100 includes a first capacitor-DAC circuit 102 in series with the resistor 36 between the line 27 and a reference potential, or ground node 103. The integrator 100 also has a second capacitor-DAC circuit 104 connected directly between the line 27 and the reference potential or ground node. Details of the first and second capacitor-DAC circuits 102 and 104 are shown in greater detail in FIG. 11 below. The capacitor-DAC 102 and the capacitor DAC 104 each comprise a number of capacitors that may be connected in various combinations to provide selected capacitances, also depending on the value of the internal reference frequency, FREF_INT. These selections are accomplished by detecting the frequency of the internal reference frequency, FREF_INT, in the frequency detector 96, which is described in greater detail with reference to FIG. 7 below.
In a manner similar to that described with reference to FIG. 1 above, the transconductance amplifier 28 produces an output current, IVCO, on line 40 to control the frequency of a voltage-controlled oscillator (VCO) 42. The VCO 42 produces a base output frequency on line 44 that is proportional to the input voltage to the transconductance amplifier 28, which, as described above, is proportional to the amount of lead or lag of the phase of the feedback voltage on line 16 with respect to the internal reference frequency, FREF_INT. The output from the VCO 42 on line 44 may be divided by a number, for example QDIV, by a frequency divider to provide a frequency output, FOUT, on output line 48. The output from the VCO 42 on line 44 may also be divided by a number, for example, MDIV, to provide a frequency output on feedback line 16 to the second input of the DPFD 12 for comparison with the internal reference frequency, FREF_INT.
To automatically adjust the PLL in dependence on the frequency of the reference frequency, FREF, that is applied, the output of the frequency detector 96 on line 106 presents a number of logic states to a state machine 108, which develops control signals to the charge-pump DAC 98, the capacitor DAC 102, and the capacitor DAC 104 on respective lines 110, 112, and 114. Thus, the state machine 108 configures the digital logic circuits of the charge-pump DAC 98 and the capacitor DAC circuits 102 and 104 so that the currents in the charge-pump DAC 98 and the capacitors of the capacitor DACs 102 and 104 are selected to compensate for the particular reference frequency, FREF, applied to the APLL 90 to automatically maintain the loop bandwidth over the range of reference frequencies that may be expected to be employed.
Using traditional PLL parameters,



  
    
      ω
      n
    
    =
    
      
        
          
            I
            CP
          
          ⁢
          
            K
            v
          
        
        
          MC
          1
        
      
    
  




  
    ζ
    =
    
      
        1
        2
      
      ⁢
      
        
          
            
              I
              CP
            
            ⁢
            
              K
              v
            
            ⁢
            
              C
              1
            
          
          M
        
      
      ⁢
      
        R
        1
      
    
  




  
    Thus
    ,
    
      

    
    ⁢
    
      
        ω
        
          3
          ⁢
          
            
          
          ⁢
          dB
        
      
      =
      
        
          
            I
            CP
          
          ⁢
          
            K
            v
          
          ⁢
          
            R
            1
          
        
        M
      
    
  



where:

    ωn is the natural frequency of the loop
    ICP is the charge-pump current=k2IB 
    IB is the input bias current
    Kv is the gain of the VCO
    M is the feedback divisor
    C1 is the loop zero capacitance
    R1 is the loop zero resistance
    ζ is the loop damping factor
    ω3 dB is the 3 dB cross point for the loop ( ̃2ζωn)
    If we can generate
    1) the charge-pump current, ICP, to be proportional to FOUT, that is ICP=k2IB*M*FREF_INT=k2IB*FOUT, and
    2) C1 proportional to 1/FREF_INT, that is C1=CU/FREF_INT then,





  
    
      ζ
      eff
    
    =
    
      
        
          1
          2
        
        ⁢
        
          
            
              
                k
                2
              
              ⁢
              
                I
                B
              
              ⁢
              
                MF
                REF_INT
              
              ⁢
              
                K
                v
              
              ⁢
              
                C
                U
              
            
            
              MF
              REF_INT
            
          
        
        ⁢
        
          R
          1
        
      
      =
      
        
          
            
              R
              1
            
            ⁢
            k
            ⁢
            
              
                
                  I
                  B
                
                ⁢
                
                  K
                  v
                
                ⁢
                
                  C
                  U
                
              
            
          
          2
        
        ≈
        1
      
    
  




  
    
      ω
      n
    
    =
    
      
        
          
            
              
                k
                2
              
              ⁢
              
                I
                B
              
              ⁢
              
                MF
                REF_INT
              
              ⁢
              
                K
                v
              
            
            M
          
          ×
          
            
              F
              REF_INT
            
            
              C
              U
            
          
        
      
      =
      
        
          kF
          REF_INT
        
        ⁢
        
          
            
              
                I
                B
              
              ⁢
              
                K
                v
              
            
            
              C
              U
            
          
        
      
    
  




  
    
      ω
      
        3
        ⁢
        
          
        
        ⁢
        dB
      
    
    =
    
      
        kI
        B
      
      ⁢
      
        K
        v
      
      ⁢
      
        R
        1
      
      ⁢
      
        F
        REF_INT
      
    
  



where

    CU is the total filter capacitor
    ζeff is the effective damping of the loop
    Thus, f3 dB∞FREF_INT 


To find FOUT:

    ICP(μA)=IB(3.75 mA)*M*FREF_INT (MHz)
    Fout=M*FREF_INT=500 mA with ICP=1.875 μA
    Fout=M*FREF_INT=100 mA with ICP=0.375 μA
    C1=120 pF/FREF_INT (MHz)
    Fout=500 MHz, FREF_INT=2 MHz with M=250 and C1=50 pF
    Fout=100 MHz, FREF_INT=30 MHz with M=3 and C1=3.3 pF


An example of a frequency detector circuit 96 to provide input states to the state machine 108 in FIG. 6 is shown with additional reference now to FIG. 7. The example of a suitable frequency detector circuit 96 uses a monostable multivibrator circuit 120; however, it should be noted that the monostable multivibrator 120 is only an example of a signal source that is inexpensive to realize, and that many other circuit implantations could be equally advantageously employed.
In the example illustrated, the monostable multivibrator circuit 120 may be designed to oscillate at a 10 MHz frequency. It should be noted that 10 MHz has been selected as a convenient frequency against which the internal reference frequency, FREF_INT, can be compared; however, any other suitable frequency can be selected.
A current source 122 supplies a constant charging current, IOSC, from a constant analog voltage supply, VDDA, to a capacitor 124. The node 126 between the current source 122 and capacitor 124 is connected to the inverting input of a comparator 128, and a bandgap voltage supply 130 is connected to the noninverting input of the comparator 128 to supply a stable voltage VBG thereto. The comparator 128 is referenced to a constant digital voltage source, VDDD.
The output from the comparator 128 is fed back to a switch 132 across the capacitor 124. The output of the comparator 128 is also supplied to an inverter 134 to provide the 10 MHz output frequency on output line 136. The inverter 134 is also referenced to the constant digital voltage supply, VDDD. Thus, in operation, when the charge on the capacitor 124 reaches the threshold of the comparator 128 established by the bandgap voltage VBG, the output of the comparator 128 will change states, closing the switch 132 to discharge the capacitor 124. The frequency of the monostable multivibrator can therefore be established by adjusting the size of the capacitor 124 and magnitude of its charging current, which determines the rate at which the capacitor 124 is charged.
Thus, with a monostable multivibrator of the type that provides a relatively stable output frequency, FOUT, an estimate of the reference frequency, FREF, may be made. To make this estimate, the 10 MHz output from the inverter 134 is connected to a counter 140, which counts 64 cycles of the 10 MHz signal (in 6.4 μs). At the same time, the internal reference frequency, FREF, is applied to a counter 142. The counters 140 and 142 are reset whenever the user changes the input or output frequency of the PLL, functionally indicated by box 146. It should be noted that the 10 MHz frequency of the monostable multivibrator 120 and the count of the counter 140 are selected to enable the range of internal reference frequencies, FREF_INT, that are expected to be employed to be counted.
The outputs from the counters 140 and 142 are connected to a frequency calculator 144, which determines the number of cycles of the internal reference frequency, FREF, that occur during the 64 cycles of the 10 MHz signal from the monostable multivibrator 120. The frequency calculator 144 produces output states representing the number of cycles of the internal reference frequency, FREF, occurring during this period on output lines 106 to the state machine 108.
It will be recognized that the bandgap voltage supply 130 and the capacitor 124 have a very low temperature coefficient. Most of the frequency variation will come from the current source 122, IOSC. The jitter/FOSC ripple in VDDA can be determined from:



  
    
      I
      OSC
    
    =
    
      
        
          C
          OSC
        
        ⁢
        
          V
          BG
        
      
      T
    
  




  
    
      f
      OSC
    
    =
    
      
        I
        OSC
      
      
        
          C
          OSC
        
        ⁢
        
          V
          BG
        
      
    
  




  
    
      Δ
      ⁢
      
        
      
      ⁢
      
        f
        OSC
      
    
    =
    
      
        Δ
        ⁢
        
          
        
        ⁢
        
          I
          OSC
        
      
      +
      
        Δ
        ⁢
        
          
        
        ⁢
        
          C
          OSC
        
      
      +
      
        Δ
        ⁢
        
          
        
        ⁢
        
          V
          BG
        
      
    
  




  
    
      Δ
      ⁢
      
        
      
      ⁢
      
        f
        OSC
      
    
    =
    
      
        
          
            
              ±
              10
            
            ⁢
            %
          
          ⁢
          
            
          
          ±
          
            5
            ⁢
            %
          
        
        ±
        
          1
          ⁢
          %
        
      
      =
      
        
          ±
          20
        
        ⁢
        %
      
    
  



To determine FOUT,

    ICP(μA)=IB(3.75 mA)*M*FREF_INT (MHz)
    If Fout=M*FREF_INT=500 MHz,
    this implies that ICP=1.875 μA
    If Fout=M*FREF_INT=100 MHz
    This implies that ICP=0.375 uA
    C1=120 pF/FREF_INT (MHz)
    For Fout=500 MHz, FREF_INT=2 MHz, M=250 and C1=50 pF
    For Fout=100 MHz, FREF_INT=30 MHz, M=3 and C1=3.3 pF


Using this information, the various outputs from the state machine 108 in response to the frequencies determined by the frequency calculator 144 can be determined. Examples of some of the various states of the state machine 108 may assume to supply the control signals are shown in the table 160 of FIG. 8, to which reference is now additionally made. Thus, the outputs from the state machine 108 adjusts the capacitances of the capacitors in the charge-pump DAC 98, the capacitor DAC 102, and the capacitor DAC 104 in accordance with the states shown in the table 160 of FIG. 8.
One construction of a charge-pump DAC 180 that may be used to provide the state-machine controlled capacitances is shown in FIG. 9, to which reference is now additionally made. The charge-pump DAC 180 receives up and down command signals from the digital phase-frequency detector (DPFD) 12 (see FIG. 6) on complementary input lines 18, 18z and 20, 20z respectively. The output is derived on output line CP_OUT 27.
Current is normally sourced to or sunk from the charge-pump circuit 180 by respective current sources 182 and 184, in the example illustrated, each supplying 250 nA. In addition, a number of additional current sources are switchably connectable to the charge-pump on both the supply side and sink side, to selectively supply additional current to the current supplied by the current sources 182 and 184. In the example illustrated, for example, current sources 186, 188, 190, and 192 are provided to selectively supply additional currents of 125 nA, 250 nA, 0.5 μA, and 1 μA to the charge-pump. Likewise, current sources 194, 196, 198, and 200 are provided to selectively sink additional currents of 125 nA, 250 nA, 0.5 μA, and 1 μA from the charge-pump.
The current sources 186, 188, 190, and 192 are controlled by signals from the state machine 108 by selectively switching on and off PMOS switch devices 310-311, 313-314, 316-317, and 319-320 respectively associated therewith. Likewise, the current sources 194, 196, 198, and 300 are controlled by signals from the state machine 108 by selectively switching off and on PMOS switch devices 322-323, 325-326, 328-329, and 331-332 respectively associated therewith. Since the current is either sourced or sunk from the charge-pump, the switches in the “up” side of the circuit are operated oppositely from the switches in the “down” side of the circuit.
The quantization error of the charge-pump DAC 180 is shown in FIG. 10, to which reference is now additionally made. In FIG. 10 the output frequencies, FOUT, of the PLL with the various charge-pump values described above are shown for reference frequencies of 2 MHz and 30 MHz. Curve 151 shows the quantization error for an output frequency of 100 MHz with a 2 MHz reference frequency, and curve 153 shows the quantization error for an output frequency of 100 MHz with a 30 MHz reference frequency. It can be seen that the peaking of the 100 MHz output for a 2 MHz reference frequency is about 3.143, and the loop bandwidth is about 199.5 KHz. On the other hand, the peaking of the 100 MHz output for a 30 MHz reference frequency is about 3.143, and the loop bandwidth is about 2.995 MHz. The loop resistor 36 is constant, and in the example illustrated, is about 70 KΩ.
In the example illustrated:

    ICP(0.38μA-2.2 μA) DAC and its Q-noise
    ICP_DAC=0-3 μA (4 bit)
    ICP error is 1−LSB=0.2 μA
    Max error is ICP=0.375 μA+Ierr=0.575 μA
    C1(4-60 pF) and its quantization noise
    C1_DAC=0-64 pF (5 bit)
    C1-DAC error is 1−LSB=2 pF
    Max error is C1-DAC=4 pF+Ierr=6 pF


An example of a capacitor DAC 102 that can be used in the autoconfigurable phase-locked loop (PLL) circuit 90 of FIG. 6 is shown in FIG. 11 to which reference is now additionally made. The capacitor DAC circuit 102 may be instantiated to provide selectable capacitances for both capacitor DAC circuits 102 and 104 in the circuit of FIG. 6, the capacitor DAC circuit 104 being shown as a variable capacitor in FIG. 11 for simplicity. The capacitor circuit 102 in FIG. 11 includes a number of capacitors 342-346 that may be selectively connected to a circuit output node 348 by a number of PMOS switches 350-351, 353-354, 356-357, 359-360, and 362-363. The various PMOS switches 350-351, 353-354, 356-357, 359-360, and 362-363 are controlled by outputs from the state machine 108 to selectively connect one or more of the capacitors 342-346 in parallel to provide a controllable capacitance.
Once an autoconfigurable phase-locked loop (PLL) circuit of the type described here is designed for a FREF_INT, the loop can automatically adjust itself to be stable over a range of reference frequencies, FREF_INT, from 2 MHz with an output frequency of 400 MHz. Moreover, once the loop is designed to have a stable charge-pump current, ICP, the loop state machine 108 will automatically adjust the charge-pump current, ICP, for other reference frequencies, FREF, and other output frequencies, FOUT.
For example,

    
    
        a. For FOUT=400 MHz, ICP=1.5 μA (designed Nominal value)
        b. For FOUT′=600 MHz, ICP′=1.5 μA*600/400=2.25 μA
    
    


The loop state machine similarly scales C1. That is once the loop is designed for one internal reference frequency, FREF_INT, and one output frequency, FOUT, then the state machine scales it for all other values. For example, the loop can be designed for FREF_INT=2 MHz with FOUT=400 MHz.
Auto Configuration algorithm



  
    
      I
      CP
    
    =
    
      
        
          I
          B
        
        *
        
          MF
          REF_INT
        
      
      =
      
        
          I
          B
        
        *
        
          F
          OUT
        
      
    
  




  
    
      C
      1
    
    =
    
      
        C
        U
      
      /
      
        F
        REF_INT
      
    
  




  
    
      
        I
        
          CP
          ⁢
          
            
          
          ⁢
          1
        
      
      
        I
        
          CP
          ⁢
          
            
          
          ⁢
          0
        
      
    
    =
    
      
        
          F
          
            OUT
            ⁢
            
              
            
            ⁢
            1
          
        
        
          F
          
            OUT
            ⁢
            
              
            
            ⁢
            0
          
        
      
      =
      
        
          
            C
            
              CYC
              ⁢
              
                
              
              ⁢
              1
            
          
          
            C
            
              CYC
              ⁢
              
                
              
              ⁢
              0
            
          
        
        =
        κ
      
    
  




  
    
      
        C
        
          fil
          ⁢
          
            
          
          ⁢
          1
        
      
      
        C
        
          fil
          ⁢
          
            
          
          ⁢
          0
        
      
    
    =
    
      
        
          F
          
            REF_INT
            ⁢
            
              
            
            ⁢
            0
          
        
        
          F
          
            REF_INT
            ⁢
            
              
            
            ⁢
            1
          
        
      
      =
      η
    
  



With the minimum charge-pump current, ICP_min,=0.25 μA and the minimum capacitance for C1, C1_min=4 pF, if ICP changes from 0.375 to 2.25 therefore the ratio is 6. Thus, a 3-bit state machine may be used, and to minimize variations in ω3 dB and ζ a 4-bit DAC may be used. If C1 changes from 4 pF to 60 pF, a 4 bit state machine may be used, and to minimize variation in ω3 dB and ζ a 5 bit DAC may be used.
The circuit is also relatively insensitive to PVT variations:

FOSC∝IOSC=n·IB 

This implies:





  
    C
    CYC
  
  =
  
    
      
        F
        REF_INT
      
      
        F
        OSC
      
    
    ∝
    
      1
      
        nI
        B
      
    
  




and

ICP∝k2·IB·MFREF_INT 

If IB becomes “βIB” from a PVT variation, then the charge-pump current, ICP, and oscillator frequency, FOSC, will increase by the same factor. Thus, the effective internal reference frequency, FREF_INT_eff, will appear as FREF_INT/β.



  
    
      ω
      
        3
        ⁢
        
          
        
        ⁢
        dB
      
    
    =
    
      
        kI
        B
      
      ⁢
      
        K
        v
      
      ⁢
      
        R
        1
      
      ⁢
      
        F
        REF_INT
      
    
  




  
    
      ω
      
        3
        ⁢
        
          
        
        ⁢
        dB_eff
      
    
    =
    
      k
      ⁢
      
        
      
      ⁢
      
        β
        ·
        
          I
          B
        
      
      ⁢
      
        K
        v
      
      ⁢
      
        R
        1
      
      ⁢
      
        
          F
          REF_INT
        
        β
      
    
  



Thus, the effective value of ω3 dB does not change with process variation in the bias current. The algorithm works as ratio of numbers, which is accurate over process variation. Graphs of step and frequency response in the corners are shown respectively in FIGS. 12 and 13.
Electrical connections, couplings, and connections have been described with respect to various devices or elements. The connections and couplings may be direct or indirect. A connection between a first and second electrical device may be a direct electrical connection or may be an indirect electrical connection. An indirect electrical connection may include interposed elements that may process the signals from the first electrical device to the second electrical device.
Although the invention has been described and illustrated with a certain degree of particularity, it should be understood that the present disclosure has been made by way of example only, and that numerous changes in the combination and arrangement of parts may be resorted to without departing from the spirit and scope of the invention, as hereinafter claimed.

## Claims

1. A phase-locked loop (PLL), comprising:
a frequency detector circuit for estimating a frequency of a reference frequency signal by counting a number of cycles of the reference frequency signal over a fixed period of time;
a phase detector for generating up and down command signals in response to phase differences between the reference frequency signal and a frequency signal related to a base PLL output frequency signal;
a circuit for producing control signals in dependence upon the frequency detected by said frequency detector;
a charge-pump DAC for generating a charge-pump output current, said charge-pump DAC being connected to receive said up and down command signals and control signals from said circuit;
an integrator for integrating said charge-pump output current, said integrator including a plurality of capacitors switchably selected by said control signals from said circuit for producing control signals to adjust an integrating capacitance value; and
a voltage controlled oscillator (VCO) for producing the base PLL output frequency signal in response to said integrated charge-pump output current;
wherein the frequency detector circuit includes an oscillator configured to produce a clock signal having a fixed frequency, a first counter coupled to the clock signal configured to count for a fixed number of cycles of the clock signal to form a fixed time period, and a second counter coupled to the reference frequency signal configured to count a number of cycles of the reference frequency signal during the fixed time period, such that an output of the second counter is proportional to the frequency of the reference frequency signal.

2. The PLL of claim 1, in which the oscillator is a monostable multivibrator circuit.