Circuit for generating a reference voltage and detecting an undervoltage of a supply voltage and corresponding method

Abstract: A circuit for generating a reference voltage and detecting a drop in a supply voltage, comprising at least one threshold comparator (12) having an input terminal (IN) and an output terminal, and a voltage divider (14) connected between a first supply voltage reference (Vs) and a second voltage reference (GND) and connected to the input terminal (IN) of the comparator (12), further provides for the output terminal (OUT) of said comparator (12) to be connected to the input terminal (IN) through at least one feedback network comprising at least one current generator (CG1). The feedback network further comprises a buffer block (13) having an input terminal connected to said comparator (12) and a first output terminal (DO) connected to a switch (SW) which is connected between a circuit node (X2) of said voltage divider (14) and the second voltage reference (GND).

Description: Field of the Invention This invention relates to a circuit for generating a reference voltage and detecting a drop in a supply voltage. More specifically, the invention relates to a circuit for generating a reference voltage and detecting a drop in a supply voltage, which circuit comprises at least one threshold comparator having an input terminal and an output terminal, and a voltage divider connected between a first supply voltage reference and a second voltage reference and connected to the input terminal (IN) of the comparator. The invention also concerns a method of generating a reference voltage and simultaneously detecting a drop in a supply voltage to an electronic circuit which is connected between a first supply voltage reference and a second voltage reference. The utility of such circuits is a varius and extensive one. It's enough to say that all electronic devices which include circuit portions of the analog type arranged to cooperate with circuit portions of the digital type, and are confronted with large variations in their supply voltage, must be able to generate internally a fixed reference voltage for their digital circuitry. Furthermore, an ability to detect a drop in the supply voltage is important to all those devices wherein a decrease in that voltage may affect the normal performance of the entire system, unless timely detected. An example of these devices is represented by the switches employed to power solenoid valves in automated production lines. The invention relates, particularly but not solely, to a circuit of the bandgap type, and for convenience of illustration, reference will made hereinafter to this type of structure. Prior Art Most of the known circuits which generate a reference voltage use a structure of the bandgap type which is based on the principle of the thermal dependence of both the voltage drop across the base-emitter junction, V BE , and the thermal voltage VT (V T =K*T/q) of a bipolar transistor. These two voltage values have a negative and a positive thermal coefficient, respectively, i.e. they are respectively increased and decreased with the device temperature. Thus, by an appropriate weighted sum, it is possible to obtain from them a voltage generating circuit which has a null thermal coefficient, i.e. is unaffected by variations in temperature. The principle of operation of a voltage generator of the bandgap type is described, for example, by P.R. Gray and R.G. Meyer in "Circuiti Integrati Analogici - Analisi e Progetto", Chapter 4, pages 353 foll., published in 1987 by McGraw Hill Libri Italia srl. A schematic of that circuit operation is shown in Figure 1. The generator circuit 1 of the bandgap type comprises a bipolar transistor T having its collector terminal C connected to both a first supply voltage reference Vs, via a current generator G, and the base terminal, and having its emitter terminal E connected to a second voltage reference, such as a signal ground GND. The base terminal B is connected, in turn, to a first input I1 of an adder 2, whose second input I2 is connected to the cascade of a voltage VT generator 3 and a scale reducer 4 for a coefficient K. Present on the output terminal O1 of the adder 2 is a bandgap voltage V BG , which is given by: V BG = V BE + K*V T where the value of coefficient K is selected to minimize the dependence of the generated voltage V BG on temperature. Several circuit arrangements are provided by the literature for implementing a voltage generator which can operate on the principle illustrated in Figure 1. Two of them are shown in Figures 1A and 1B. The generator circuit 1 of the bandgap type comprises first N1 and second N2 bipolar transistors, first R1 and second R2 resistive elements, and a current mirror circuit 5 plus a feedback network RR. The bipolar transistors, N1 and N2, have their base terminals B1 and B2 connected together to form an output terminal O1 of the circuit 1, and their collector terminals C1 and C2 connected to said current mirror 5. The first transistor N1, moreover, has its emitter terminal E1 connected to a circuit node X via the first resistive element R1. This circuit node X, in turn, is connected to the emitter terminal E2 of the second transistor N2 and to the second voltage reference GND via the second resistive element R2. The feedback network RR is connected between the collector terminal C2 and the base terminal B2 of the second transistor N2. The feedback network RR may simply comprise a wire lead 6, as shown in Figure 1A, or be formed of a further bipolar transistor NR having its base terminal BR connected to the collector terminal C2, its emitter terminal ER connected to the base terminal B2, and its collector terminal CR connected to the first supply voltage reference Vs, as shown in Figure 1B. A current is flowed through the resistive element R2 which is given by the ratio of the potential difference between the base-emitter voltage V BE of the transistors N1 and N2 to the value of the resistive element R1. In this way, a voltage V' is obtained which is proportional to the thermal voltage V T , as per the following relation: V' = K*V T = 2 · R2 R1 · V T · ln(n) A so-called bandgap voltage signal V BG is, therefore, obtained at the output terminal O1 which is equal to the sum of the base-emitter voltage V BE plus the voltage V'. All this according to theoretical relation (1). The constant K is only dependent on the ratio of the resistive elements R1 and R2, and on the ratio of the areas of the transistors N1 and N2, and accordingly, can be selected to make the bandgap output voltage V BG as much as possible independent of temperature. The bandgap voltage V BG obtained in this way is usually a constant quantity for all silicon processes and its value is 1.25V. Coming now to the problem of how to detect a drop in the supply voltage, conventional circuits provide this information by comparing a reference voltage to the supply voltage as suitably reduced by a scale factor. The operation principle of the most comprehensive and widely used solution is illustrated by Figure 2. The detection circuit 7 shown therein comprises a generating circuit 1 of the badgap type which supplies a constant reference voltage signal V BG and is connected to a first inverting (-) input of a comparator 8. The circuit 7 further comprises a trigger circuit 9 connected ahead of the generator 1. A second non-inverting (+) input of the comparator 8 is connected to the first supply voltage reference Vs by a resistive divider 10 which comprises first R3 and second R4 resistive elements. The first resistive element R3 is connected between the first supply voltage reference Vs and the non-inverting (+) input terminal of the comparator 8, while the second resistive element R4 is connected between that terminal and the second voltage reference GND. The output terminal O2 of the comparator 8 is the output terminal of the circuit 7. The generating circuit 1 must be stable when the power supply varies, that is, in technical language, exhibit good line rejection. This generating circuit 1 has two points of operation at the values of V BG =0 and V BG =1.25V. The first point of operation is, however, an unstable one and a small variation in the conditions of equilibrium would be sufficient to bring the whole circuit to the second point of operation, which is the one sought. This function is served by the trigger circuit 9 introducing these small variations into the conditions of operation and biasing the generating circuit 1 toward the point of operation at 1.25V. The detection circuit 7 then compares a reference voltage value of 1.25V to the value of the supply voltage, as conveniently reduced by a scale factor through the resistive divider 10. In addition, the trigger circuit 9 included in the supply voltage drop detecting circuit 7 must remain active all the time if the device is to operate properly. This may represent a big problem, especially in low-consumption circuit applications. The underlying technical problem of this invention is to provide a circuit for generating a reference voltage and detecting a drop in a supply voltage, which has such constructional and functional features as to enable both functions to be implemented in a simple and compact single structure, and can overcome the limitations and/or drawbacks with which prior art circuits have been beset. Summary of the Invention The solutive idea on which the present invention stands is one of using a single structure of the bandgap type to both generate a reference voltage and detect a drop in a supply voltage, which structure can be switched automatically between these two functions. Based on this solutive idea, the technical problem is solved by a circuit as previously indicated and as defined in the characterizing portion of Claim 1. The problem is also solved by an automatic switching method of the type previously indicated and defined in the characterizing portion of Claim 11. The features and advantages of a circuit according to the invention will be apparent from the following description of an embodiment thereof, given by way of example and not of limitation with reference to the accompanying drawings. Brief Description of the Drawings In such drawings: Figure 1 is a schematic illustrating the operation of a generating circuit of the bandgap type according to the prior art; Figures 1A and 1B show possible embodiments of the generating circuit in Figure 1; Figure 2 shows schematically a prior art circuit for detecting a drop in a supply voltage; Figure 3 is a schematic illustrating the principle of the inventive circuit; Figure 4 is a more detailed diagram of the circuit shown in Figure 3; Figure 5 is a qualitative illustration of the patterns of certain signals present in the circuit of Figure 3; Figure 6 shows a possible embodiment of the circuit in Figure 3. Detailed Description Referring in particular to Figure 3, generally shown at 11 is the circuit of this invention for generating a reference voltage and detecting a drop in a supply voltage. The circuit 11 comprises a threshold comparator 12 having an input terminal IN and an output terminal OUT. The input terminal IN of the comparator 12 is connected to a first circuit node X1, and the output teerminal OUT thereof is connected to the input terminal of a buffer block 13 having first DO and second AO output terminals. The first circuit node X1 is a midpoint of a resistive divider 14 connected between a first supply voltage reference Vs and a second voltage reference such as a signal ground GND. The resistive divider 14 comprises, in series, a first resistive element R3 connected between the first supply voltage reference Vs and the first circuit node X1, a second resistive element R4 connected between the first circuit node X1 and a second circuit node X2, and a third resistive element R5 connected between the second circuit node X2 and the second voltage reference GND. Also connected to the circuit node X1, between the node X1 and the second voltage reference GND, is a current generator CG1 which is controlled by a signal generated on the second output terminal Ao of the buffer block 13. The comparator 12 is a comparator which has an internal threshold equal to V TH and its output voltage V OUT tied to the input voltage V IN by the following relation: V OUT = G * (V IN - V TH ) where, G is the gain of the comparator 12. In the particular embodiment of the comparator 12 shown in figures 3, 4 and 6, the overall gain G of the comparator 12 is negative, i.e., when V IN is below V TH , V OUT is positive, and when V IN is above V TH , V OUT is negative. In particular, the threshold comparator 12 can be embodied by a bandgap type of structure as shown in Figure 4, for example. The comparator 12 comprises first N1 and second N2 bipolar transistors, first R1 and second R2 resistive elements, and a current-mirror biasing circuit 15. The bipolar transistors N1 and N2 have their base terminals B1 and B2 connected together and to the circuit node X1, while also forming the input terminal IN, and their collector terminals C1 and C2 connected to the current mirror 15. The collector terminal C2 of the second transistor N2 is the output terminal OUT of the comparator 12. Also, the first transistor N1 has its emitter terminal E1 connected to a third circuit node X3 via the first resistive element R1. This circuit node X3, in turn, is connected to the emitter terminal E2 of the second transistor N2 and to the second voltage reference GND via the second resistive element R2. The use of a bandgap type of structure allows a stable voltage VBG to be obtained at the input terminal IN of the comparator 12. The bandgap voltage VBG is the same as the threshold voltage of the comparator 12, and is of 1.25V for all silicon processes. The operation of the circuit 11 as a detector of supply voltage drops will now be discussed. The generating circuit of the bandgap type which embodies the comparator 12 is characterized by the output voltage V OUT switching to a low value as the input voltage VIN exceeds the internal threshold value V BG . This input voltage VIN is, however, proportional to the supply voltage Vs according to a coefficient which is defined by the resistive divider consisting of the resistors R3 and R4 alone. In fact, in a condition of decreased supply voltage, the voltage at the first circuit node X1 would be less than the threshold voltage V BG , thereby raising the output voltage of the comparator 12, and hence, the voltage at the first output terminal DO of the buffer block 13. Under these conditions, the switch SW would be closed and the resistor R5 shorted to ground GND. Basically, the block comprising the transistors N1 and N2 and resistors R1 and R2 has the behavior of a comparator whose outputs are the collector currents of the transistors N1 and N2, while the switching voltage is actually the bandgap voltage V BG . Upon the voltage at the node X1 reaching the threshold value V BG , the comparator 12 output will switch over. Under this condition, the threshold of the supply voltage is given by the following relation. V UVH = ( 1 + R3/R4) * V BG Advantageously, according to the invention, the switching is speeded up by the positive feedback introduced by the resistor R5 and by the switch SW being open. This positive feedback originates a hysteresis phenomenon which prevents intermittent oscillations at the output terminal DO in the event that the supply voltage is not fully stabilized. The value of the hysteresis voltage V HY introduced by the resistor R5 is given by: V HY = R3·R5 R4·(R4+R5) ·V BG Figure 5 shows the waveforms of the bandgap voltage V BG and the voltage V DO at the output terminal DO of the buffer block 13 as a function of the supply voltage Vs. The overall operation of the inventive circuit is as follows. The output OUT of the bandgap circuit forming the comparator 12 is cut off from the input IN by a negative feedback introduced by the circuit loop comprising the buffer block 13 and current generator CG1. This loop would be open at lower supply voltages than the threshold value V UVH given by formula (4); under this condition, the voltage at the first circuit node X1 is proportional to the supply voltage linearly therewith. The feedback loop would instead be closed when the supply voltage Vs rises above the value of the voltage V UVH ; under this condition, the voltage at the circuit node X1 is held firmly at the value of the bandgap voltage VBG by the current tapped off by the generator CG1 under control by the signal present on the second output terminal AO of the buffer block 13. Thus, a circuit has been provided which can generate a stable reference voltage equal to V BG and detect a drop in the supply voltage, signalling it by means of the voltage V DO which appears at the first: output terminal DO of the buffer block 13. A possible embodiment of the circuit 11 according to the invention is shown in Figure 6. The various circuit portions illustrated by the diagram of Figure 4 can be easily recognized therein. In particular, the current mirror 15 is formed of a pair of p-channel MOS transistors P1 and P2, respectively having their source terminals S1 and S2 connected to the first supply voltage reference Vs and their gate terminals G1 and G2 connected to each other. The transistor P1 has its drain terminal D1 connected to the gate terminal G1 and the collector terminal C1 of the first bipolar transistor N1. The transistor P2 has its drain terminal D2 connected to the collector terminal C2 of the second bipolar transistor N2, which forms the output terminal OUT of the comparator 12. The buffer block 13 is comprised of a further p-channel MOS transistor P3, an n-channel MOS transistor N4, and a pair of resistive elements R6 and R7. The transistor P3 has its source terminal connected to the first supply voltage reference Vs, its gate terminal G3 connected to the output terminal OUT, and its drain terminal D3 connected to a fourth circuit node X4. The gate terminal G3 of the transistor P3 is the input terminal of the buffer block 13. The fourth circuit node X4 is connected to the second voltage reference GND via the resistor R6, and is connected to the gate terminal G4 of the transistor N4, which has its source terminal connected to the second voltage reference GND and its drain terminal connected to the first supply voltage reference Vs via the resistor R7. The drain terminal D4 of the transistor N4 is the first output terminal DO of the buffer block 13, while the fourth circuit node X4 is the second output terminal AO of the buffer block 13. This output terminal AO is connected to the generator CG1 formed of a further n-channel MOS transistor N5. The transistor N5 has its gate terminal G5 connected to the fourth circuit node X4, its drain terminal D5 connected to the input terminal IN of the comparator 12, and its source terminal S5 connected to the second voltage reference GND. Lastly, the switch SW is formed of a further n-channel MOS transistor N6 having its source terminal S6 connected to the second voltage reference GND, its drain terminal D6 connected to the second circuit node X2, and its gate terminal G6 connected to the first output terminal DO of the buffer block 13. Proper operation of the circuit shown in Figure 6 requires that the transistors N4 and N5 be carefully dimensioned. In fact, when the supply voltage Vs reaches the detection threshold V UVH as given by formula (4), the voltage at the first circuit node X1 will be approaching the value of the steady-state bandgap voltage V BG ; under this condition, the transistor P3 supplies a current which turns on the transistors N4 and N5. For higher supply voltages than threshold V UVH , the transistor N5, whose function is that of holding the voltage present on the first circuit node X1 at the same value as the steady-state voltage V BG =1.25V, behaves as a current generator and draws from the node X1 the excess current from the resistor R3. Under the same conditions, the transistor N4, whose function is that of holding the voltage present on the output terminal DO at a low value, behaves as a switch. Actually, it will be appreciated that the circuit node DO switches to a supply voltage value Vs above the value at which the transistor N3 begins to draw current from the first node X1. The voltage difference ΔV between the theoretical detection threshold and the real one is given by: ΔV = [V UVH - V GS6 (I R4 )]· R3 R7 · W5·L4 W4·L5 where, V UVH is the theoretical detection threshold; V GS6 (I R4 ) is the voltage between the gate terminal and the source terminal of the transistor N6 as biased by the current I R4 flowing through the resistor R4; and W4, L4 and W5, L5 are the widths and lengths, respectively, of the transistors N4 and N5. Therefore, the real detection threshold obtained by means of the circuit 11 of this invention will be the closer to the theoretical threshold V UVH sought, the smaller is the value of the voltage difference ΔV from formula (6). This difference can evidently be minimized by using a very wide transistor N4 and a very long transistor N5. Suitable dimensions for such transistors N4 and N5 are those given below: W4/L4 = 100u/3u W5/L5 = 20u/20u. The solution proposed in Figure 6 has been simulated by the Applicant, based on its implementation with BCD technology on silicon. Conventional devices for generating a reference voltage and detecting a drop in supply voltage, which are formed by separate bandgap structures and a trigger circuit to perform the function of detecting a drop in the supply voltage, have the following operational parameters: I A = 350 µa A = 0.40 mm 2 where, IA is the current drain and A is the area occupied. By contrast, the circuit of this invention has the following operational parameters: IA = 200 µa A = 0.20 mm 2 that is, values nearly halved from those of conventional circuits, for the same circuit accuracy as the process parameters in its making vary. In addition, the supply voltage rejection is of 90 dB up to a frequency of 100 Hz, to drop by 20 dB/decade up to a frequency of 1 MHz, and eventually retain a steady value of 10 dB at frequencies above that. Major advantages of a circuit for generating a reference voltage and detecting a drop in a supply voltage according to the inventiion are the following: reduced current consumption and circuit area requirements, by having the functions of generating a reference voltage and detecting a drop in the supply voltage combined in a single structure; improved supply voltage drop threshold, and the use of a single trimming circuit to enhance the reference voltage accuracy; all this by the use of a single structure of the bandgap type. Many different alternative circuit solutions would, of course, be effective to implement the inventive circuit: for example, a bandgap type of structure could be used which is dependent on the supply voltage reference and comprised, therefore, of pnp bipolar transistors.

Claims: A circuit for generating a reference voltage and detecting a drop in a supply voltage, which circuit comprises at least one threshold comparator (12) having an input terminal (IN) and an output terminal, and a voltage divider (14) connected between a first supply voltage reference (Vs) and a second voltage reference (GND) and connected to the input terminal (IN) of the comparator (12), characterized in that the output terminal (OUT) of said comparator (12) is connected to the input terminal (IN) through at least one controlled negative feedback network comprising at least one current generator (CG1), and further characterized in that the output terminal (OUT) is coupled to a switch (N4) that controls a signal indicating a drop in the supply voltage. A circuit according to Claim 1, characterized in that said at least one feedback network comprises a buffer block (13) having an input terminal connected to said comparator (12) and a first output terminal (DO) connected to a switch (SW) which is connected between a circuit node (X2) of said voltage divider (14) and the second voltage reference (GND). A circuit according to Claim 2, characterized in that said current generator (CG1) is connected between the input terminal (IN) of the comparator (12) and the second voltage reference (GND) and is controlled by a signal generated on a second output terminal (AO) of the buffer block (13). A circuit according to Claim 1, characterized in that said comparator (12) is of the bandgap type and connected between the first supply voltage reference (Vs) and the second voltage reference (GND). A circuit according to Claim 2, characterized in that said voltage divider (14) comprises, in series, at least first (R3), second (R4) and third (R5) resistive elements, with the first resistive element (R3) being connected between the first supply voltage reference (Vs) and a first circuit node (X1) connected to the input terminal (IN) of said comparator (12), the second resistive element (R4) connected between said first circuit node (X1) and said circuit node (X2), and the third resistive element (R5) connected between said circuit node (X2) and the second voltage reference (GND). A circuit according to Claim 4, wherein the buffer block (13) comprises a series of a first MOS transistor (P3) and a first resistive element (R6), and a series of a second MOS transistor (N4) and a second resistive element (R7), which are connected between the supply voltage reference (Vs) and the second voltage reference (GND), characterized in that the drain terminal (D3) of the first MOS transistor (P3) is connected to the gate terminal (G4) of the second MOS transistor (N4). A circuit according to Claim 6, characterized in that said current generator (CG1) comprises a further MOS transistor (N5), and that said second transistor (N4) has a width-to-length ratio (W/L) much higher than the width-to-length ratio (W/L) of said further transistor (N5). A circuit according to Claims 2 and 6, characterized in that said switch (SW) comprises a MOS transistor (N6) having its gate terminal connected to the first output terminal (DO) of the buffer block (13), its drain terminal (D6) connected to the circuit node (X2) of said resistive divider (14), and its source terminal connected to the second voltage reference (GND). A method of generating a reference voltage and simultaneously detecting a drop in a supply voltage to an electronic circuit (1) which is connected between a first supply voltage reference (Vs) and a second voltage reference (GND) through a voltage divider (14), and comprises a single threshold comparator (12) having an input terminal (IN) and an output terminal (OUT) connected to each other through at least one controlled negative feedback network which includes a buffer block (13) having an output terminal (DO) used to indicate the drop in the supply voltage, the buffer block (13) connected between said output terminal (OUT) and a current generator (CG1) connected between the input terminal (IN) of the comparator (12) and the second voltage reference (GND) and being controlled by a signal (V AO ) generated on an output terminal (AO) of the comparator (12), the voltage (V IN ) at the input terminal being held constant by tapping off excess current being supplied to said input terminal (IN) when the voltage at the input terminal (IN) of the comparator (12) exceeds the treshold (VBG) of the comparator, in order to thereby obtain a stable reference voltage. A method according to Claim 9, characterized in that said comparator (12) is of the bandgap type and connected between the first supply voltage reference (Vs) and the second voltage reference (GND). A method according to Claim 10, characterized in that a switch (SW) is provided in the feedback line, and that: the feedback network switch (SW) closes automatically as the input voltage (V IN ) exceeds a threshold voltage value (V BG ) of the comparator (12), thereby generating a reference voltage (V IN ) ; and said switch (SW) opens automatically as the input voltage (VIN) drops below the threshold voltage value (V BG ), thereby indicating a drop in the supply voltage (Vs). A method according to Claim 11, characterized in that, during the switch (SW) opening, a hysteresis phenomenon is brought about which is effective to prevent oscillations of a voltage (V DO ) on the output terminal (DO) of the buffer block (13) in the presence of a supply voltage which is less than fully stabilized. A method according to Claim 12, characterized in that said switch (SW) is controlled by the signal present on the output terminal (DO) of the buffer block (13), which switches from a low value when the voltage at the input terminal (IN) of the comparator (12) is higher than an internal threshold value (V BG ) over to a high value when the voltage at the input terminal (IN) is lower than the internal threshold value (V BG ).

Inventors: GARIBOLDI ROBERTO, PULVIRENTI FRANCESCO, GARIBOLDI, ROBERTO, PULVIRENTI, FRANCESCO
Applicants: CONS RIC MICROELETTRONICA, ST MICROELECTRONICS SRL, CO.RI.M.ME., STMICROELECTRONICS S.R.L.
Application year: 1995
Main classification: G05F3
IPC codes: G05F3, G01R19, G05F1, H02J1, G11C5