Abstract:
A comparator circuit for comparing a differential input signal to a reference signal. A differential MOS transistor pair is provided having respective gates for receiving the positive and negative components of the differential input signal. A tail current source is coupled to the common sources of the transistor pair, with the current magnitude being related to the reference signal magnitude. The first and second transistors are made differently, typically by making the sizes different, so that the gate-source voltages differ when the transistor currents are equal. A comparator stage provides a digital output which changes state when the transistor currents are equal, with the difference in gate-source voltage representing the comparator trip voltage, a trip voltage related to the magnitude of the reference signal.

Description:
This application claims the benefit of provisional application 60/185,077 filed on Feb. 25, 2000. 
    
    
     BACKGROUND OF THE INVENTION 
     1. Field of the Invention 
     The present invention relates generally to data conversion circuitry and in particular to a continuous time comparator circuit which compares a differential analog input to a reference voltage. 
     2. Description of Related Art 
     In many analog circuits, particularly where analog to digital conversion is required, an analog input voltage must be compared to a fixed reference voltage. Moreover, in high speed and high precision circuits, signals which are being processed are kept in differential form. Thus, for example, if a signal Vin is to be processed, the signal is divided into what is referred to in the present application as a positive (or first) component (Vinp) and a negative (or second) component (Vinn). Signal Vin is thus represented by the difference between the positive and negative components. In that case, to compare Vin and a reference Vref, it is necessary for the comparison circuitry to compare Vinp and Vinn with Vref. In some applications, Vref is also in differential form and includes a positive component Vrefp and a negative component Vrefn. In that event, the comparator circuitry must compare the difference between Vinp and Vinn with the difference between Vrefn and Vrefp. The same result can be achieved by comparing the difference of Vrefn and Vinn with the difference of Vrefp and Vinp. Also, the same result can be achieved by summing Vinn and Vrefp and summing Vinp and Vrefn and comparing the two sums. 
     Referring to the drawings, FIG. 1 is circuit diagram of a prior art comparator circuit for comparing a differential input Vin with a differential reference voltage Vref. Two differential transistor pair are used, including a first pair made up of transistors  10 A and  10 B and a second pair made up of transistors  12 A and  12 B. The two pair share a load with includes resistors R 1  and R 2 . The voltage drop across resistor R 1  is compared to the voltage drop across resistor R 2  by a comparator stage  18  which provides a digital output which is high, near voltage VDD, when input voltage Vin is greater than reference Vref, and which is low, near VSS, when the input voltage is less than Vref. 
     The voltage drop across resistor R 1  is the sum of currents I 1  and I 3  and the voltage drop across resistor R 2  is the sum of the currents I 2  and I 4 . Thus, the voltage drop across R 1  is related to the sum of Vinp and Vrefn and the voltage drop across R 2  is related to the sum of Vinn and Vrefp. As noted above, by comparing these two sums, the relative magnitudes of Vin and Vref can be ascertained. This operation is carried out by comparator stage  18  where output Vo is indicative of the relative magnitudes. 
     The two differential stages of the FIG. 1 comparator circuit operate to convert input voltages to currents, a conversion which is non-linear in nature. In addition, the addition of the currents are non-linear. Thus, the common mode voltage of Vref, the average of Vrefp and Vrefn, must be equal to the common mode voltage of Vin, the average of Vinp and Vinn or the FIG. 1 circuit will not operate properly. In many instances, however, the Vin is the output of a previous stage where the differential voltage of Vin is very accurate, but the common mode voltage accuracy is significantly more relaxed. In such cases, the common mode voltage of Vin can be a few hundred millivolts away from the nominal value thereby severely degrading the accuracy of the comparator circuit. 
     FIGS. 2A and 2B show another type of comparator circuit which only utilizes a single differential pair made up of transistors  20 A and  20 B. A pair of input capacitors C 1  and C 2 , together with the inputs of the differential pair, are connected to a transistor switch array (not depicted). The comparator circuit switches between an initialize state and a compare state. Thus, the FIGS.  2 A/ 2 B circuit differs in this respect from the continuous-time comparator circuit of FIG.  1 . 
     In the initialize state, shown in FIG. 2A, the switch array causes first terminals of capacitors C 1  and C 2  to be connected to Vrefp and Vrefn, respectively and the second terminals to be connected to ground. Thus, a voltage related to Vrefp and Vrefn is placed on capacitors C 1  and C 2 , respectively. In addition, the inputs of differential pair  20 A/ 20 B are grounded. 
     In the compare state, shown in FIG. 2B, all of the closed transistor switches are opened. Soon thereafter, the switch array causes the first terminals of capacitors to be connected to Vinp and Vinn, respectively, and the second terminals to be connected to the respective inputs of the differential stage. The voltage applied to the gate of differential transistor  20 A will thus be related to the difference between Vrefp and Vinp and the voltage applied to the gate of transistor  20 B will thus be related to the difference between Vrefn and Vinn. The differential stage will amplify the difference between the two values stored on capacitors C 1  and C 2 . The amplified difference is forwarded to a comparator stage  24  which produces a value Vo related to the relative magnitudes of Vref and Vin. 
     Although the FIGS.  2 A/ 2 B comparator circuit is free from the common mode voltage dependency of the FIG. 1 circuit, the FIGS.  2 A/ 2 B circuit possesses a serious drawback other than not being continuously operable. The Vinp and Vinn terminals are disturbed every time the capacitors C 1  and C 2  are connected to and disconnected from the terminals because the terminals must provide the current used to charge and discharge the capacitors. If Vin is being processed by other circuits, inaccurate results may be obtained since Vin has been affected by the switched capacitor circuit. The same degradation can occur on the Vref terminals as they also have to supply charge and discharge currents. Perhaps more importantly, a charge created by the switching signals for the switch array (not depicted) will tend to feed through by way of the switch capacitances thereby disturbing both Vin and Vref. 
     The present invention overcomes many of the shortcomings of the prior art comparator circuits previously described. A continuous-time comparator circuit is disclosed having a single differential stage and which is not subject to the common mode requirements associated with certain prior art comparator circuits noted above. These are other advantages of the present invention will become apparent to those skilled in the art upon a reading of the following Detailed Description of the Invention together with the drawings. 
     SUMMARY OF THE INVENTION 
     A comparator circuit and related method are disclosed for comparing a differential input signal with a reference signal. The comparator circuit includes first and second MOS transistors connected as a differential pair and having gates connected to receive first and second components, respectively, of the differential input signal. The first and second transistors have respective transistors constants, K 1  and K 2 , that differ. Typically, the ratio of K 2 /K 1  is at least 1.1 and preferably closer to 2-3. 
     A tail current source is connected to the sources of the first and second MOS transistors, with the current source output current being related to the reference signal. Preferably, the current output is related to the square of the reference signal. A comparator stage is included that is configured to provide a digital output indicative of the relative magnitude of the reference signal and differential input signal. The comparator stage preferably compares the relative magnitude of the drain-source currents of the first and second MOS transistors. 
    
    
     BRIEF DESCRIPTION OF THE DRAWINGS 
     FIG. 1 is a schematic diagram of a conventional dual differential stage comparator circuit. 
     FIGS. 2A and 2B are diagrams illustrating the construction and operation of a conventional switched capacitor comparator circuit. 
     FIG. 3 is a circuit diagram of one embodiment of a comparator circuit in accordance with the present invention. 
    
    
     DETAILED DESCRIPTION OF THE INVENTION 
     Referring again to the drawings, FIG. 3 is a schematic diagram of one embodiment of a comparator circuit in accordance with the present invention. In this embodiment, a differential input signal Vin, having a positive component Vinp and a negative component Vinn, is compared to a single ended reference voltage Vref or a fraction of Vref. The comparator circuit includes a differential stage made up of differential transistor pair M 1  and M 2 . 
     As will be explained in greater detail, transistors M 1  and M 2  are sized differently so that when the current flow through the transistors is equal, the gate voltages of the transistors differ by a controlled voltage, referred to as the trip voltage Vtrip. The trip voltage Vtrip is made a function of the device size of transistors M 1  and M 2  (or other transistor variable) and the bias current I(Vref). 
     I(Vref), with the designation indicating that the current is a function of Vref, is produced by the tail current source made up of transistor M 3 . When the currents through M 1  and M 2  become equal, the voltage drops across load resistors RA and RB become equal, assuming that the resistors are equal, so that a comparator stage  30  output Vo will change state. The trip voltage Vtrip is made to be a linear function of Vref so that comparator output Vo is indicative of the relative magnitude of inputs Vinp and Vinn and Vref or some fraction of Vref. 
     The drain-source current IDS of a transistor operating in the saturation region can be expressed as follows: 
     
       
           IDS=K ( Vgs−Vt ) 2   (1) 
       
     
     where K is a transistor constant defined in equation (2) below, Vgs is the gate-source voltage and Vt is the transistor threshold voltage. 
     The transistor constant K is as follows: 
     
       
           K= (μ s    Cox Z )/2 L   (2) 
       
     
     where μ s  is the surface mobility of the majority carriers in the induced channel, Cox is the capacitance per unit area of the gate electrode, Z is the channel width and L is the channel length. 
     The trip point Vtrip of the FIG. 3 comparator circuit is where the transistor current for transistor M 1 , IDS 1 , is equal to the transistor current for transistor M 2 , IDS 2 . When the two currents are equal, inspection shows that IDS 1  and IDS 2  will be equal to ½ the tail current source output I(Vref). 
     Assuming that IDS 1  and IDS 2  are equal, the trip point Vtrip for the comparator circuit is as follows: 
     
       
           V trip= Vgs 1− Vgs 2  (3) 
       
     
     Solving equation (1) for Vgs and assuming that IDS 1  and IDS 2  are both equal to I(Vref)/2, equation (3) can be rewritten as follows:              Vtrip   =           I        (   Vref   )         2      K1         -         I        (   Vref   )         2      K2                   (   4   )                                
     where K 1  and K 2  are the constants for transistors M 1  and M 2 , respectively. 
     It can be seen from equation (4) that if transistors M 1  and M 2  are matched (K 1 =K 2 ), the trip point is zero, with the trip point increasing for greater differences. Referring to equation (2), the preferred manner to making K 1  and K 2  differ is to make the channel widths Z different. This can be done, by way of example, by connecting two standard transistors in parallel thereby doubling the channel width Z. 
     Equation (4) can be rewritten as follows:              Vtrip   =       b              I        (   Vref   )         2      K1                   (   5   )                                
     where b is defined in equation (6) below. 
     The value of b is as follows:                b     =     1   -     1     a                 (   6   )                                
     where the value of a is defined in equation (7).              a   =     K2   K1             (   7   )                                
     From equation (5) it can be seen for a given difference in K 1  and K 2 , the trip point Vtrip can be made a function of the bias current I(Vref) and thus the reference voltage Vref as follows:                I        (   Vref   )       =         2      K1     b            (   Vtrip   )     2               (   8   )                                
     As indicated by equation (8), the trip point Vtrip can be set to Vref or fraction of Vref by controlling the values of K 1  and K 2  and by producing an appropriate bias voltage I(Vref). The manner in which I(Vref) is produced will now be described. 
     Referring again to FIG. 3, an amplifier circuit  26  is shown having a non-inverting input connected to a reference voltage source Vref. The output of amplifier  26  is connected to a gate of transistor M 12 , with the source of M 12  connected to the inverting input of amplifier  26 . Negative feedback of amplifier  26  forces the source voltage of transistor M 12  to be equal to Vref. Thus, the current flow through resistor RC connected in series with transistor M 12 , current Iref, is as follows:              Iref   =     Vref   RC             (   9   )                                
     Note that VSS is assumed to be at ground potential in order to simplify the analysis, but VSS can be at some voltage other than ground. Transistor M 10 , which forms the input half of a current mirror, conducts current Iref so that matching transistor M 11  which forms the output half of the current mirror also conducts current Iref. A second current mirror includes an input transistor M 4  connected in series with transistor M 11 . Thus, transistor M 11  conducts Iref as does resistor RD connected in series between transistors M 4  and M 11 . 
     Transistors M 6  and M 7  form a differential pair and, as will be explained, operate as a voltage level shifting circuit. Transistor M 5 , the output half of the current mirror made up of transistors M 4  and M 5 , has twice the channel width of transistor M 4  and thus conducts twice the current, namely,  2 Iref. Load transistors M 8  and M 9  form a current mirror so that the tail current source is split evenly between transistors M 6  and M 7 . 
     The gate of transistor M 7  is connected directly back to what can be considered the output of the differential stage located between transistors M 7  and M 8 . Because of this feedback connection, the voltage gain of the stage is unity. However, as will be explained, transistors M 6  and M 7  are sized differently so that the input of the stage at the gate of transistor M 6 , voltage V 1 , is not equal to the output voltage V 2  at the gate of transistor M 7 . The output of the level shifting circuit, voltage V 2 , is connected to the gate of tail current source transistor M 3 . The relationship between voltage Vref and I(Vref) will now be explained, as will the relationship between the comparator circuit trip voltage Vtrip and Vref. 
     Equation (9) and inspection of the FIG. 3 circuit shows that voltage V 1  is as follows:              V1   =         RD   RC          (   Vref   )       +   Vgs4             (   10   )                                
     where Vgs 4  is the gate-source voltage of transistor M 4 . 
     Inspection of the FIG. 3 circuit also shows that the voltage V 2  is as follows: 
       V 2= V 1+ Vgs 7− Vgs 6  (11) 
     where Vgs 7  and Vgs 6  are the gate-source voltages for transistors M 7  and M 6 , respectively. 
     The value of I(Vref) can also be determined based upon equation (1) where the gate-source voltage of transistor M 3  is V 2 , as follows: 
     
       
           I ( V ref)= K 3( V 2− Vt ) 2   (12) 
       
     
     where K 3  and Vt are the transistor constant and threshold voltage for transistor M 3 , respectively. 
     By combining equations (10) and (11) and substituting the result into equation (12), equation (12) can be rewritten as follows:                I        (   Vref   )       =       K3        (         RD   RC          (   Vref   )       +   Vgs4   +   Vgs7   -   Vgs6   -   Vt     )       2             (   13   )                                
     Solving equation (1) for the various gate-source voltages and substituting the results into equation (13) results in the following:                I        (   Vref   )       =       K3        (         RD   RC          (   Vref   )       +       Iref          (         1   K4       +       1   K7       -       1   K6         )         )       2             (   14   )                                
     Equation (14) can be simplified by adjusting the transistor constant values K as follows:                    1   K4       +       1   K7         =       1   K6               (   15   )                                
     Using equation (15), equation (14) can be reduced further as follows:                I        (   Vref   )       =       K3        (       RD   RC        Vref     )       2             (   16   )                                
     It can be seen by comparing equations (16) and (8) that equation (16) can be placed in the same form as equation (8) be setting K 3  to the following:              K3   =       2      K1     b             (   17   )                                
     Substituting the new value of K 3  according to equation (17), equation (16) can be rewritten as follows:                I        (   Vref   )       =     2        K1   b            (       RD   RC        Vref     )     2               (   18   )                                
     Examination of equations (18) and (8) shows that Vtrip is as follows:              Vtrip   =       RD   RC          (   Vref   )               (   19   )                                
     Thus, the trip point Vtrip can be adjusted by changing the magnitude of the reference voltage Vref and, further, can be made any fraction of the selected value of Vref by changing the resistor ratio of RD and RC. 
     As can be seen by equations (17) and (6), the transistor constant K 3  of transistor M 3  is a function of the ratio of the transistor constants for transistor M 2  and M 1 , that is, K 2 /K 1 . This ratio, as indicated by equation (2), is typically set by altering the ratio of the channel width Z of transistor M 2  to the channel width Z of transistor M 1 . In order to maintain a reasonable value for K 3 , which is usually determined by the channel width Z of transistor M 3 , the ratio should be at least 1.1, and preferably 2 or more. 
     Thus, a novel comparator circuit has been disclosed. Although one embodiment has been described in some detail, it is to be understood that certain changed can be made by those skilled in the art without departing from the spirit and scope of the invention as defined by the appended claims.