Metastable tolerant latch

Abstract: A flip-flop having a master section (74) including two switching transistors (40, 48) is provided with output loading transistors (76, 78) to drive the two transistors (40, 48) into saturation in the event of a metastable condition causing input is present. By driving the switching transistors (40, 48) into saturation they become inactive and background noise cannot cause propagation of the metastable condition to subsequent flip-flop stages.

Description: BACKGROUND OF THE INVENTION I. Field of the Invention. The present invention relates generally to latches and flip-flops, and more particularly relates to a flip-flop capable of suppressing and compensating for metastable conditions. II. Description of the Related Art. Flip-flops are often used by system designers to synchronize signals operating at different frequencies to a local clock. However, since the signals are asynchronous to the local clock, the setup and hold time specifications associated with the flip-flop are sure to be violated. When the setup and hold time is violated, the output response of the flip-flop is uncertain. The output may assume a "metastable" state, defined as the time period during which the output of a digital logic device is not at logic level 1 or logic level 0, but instead resides at an output level between logic level 0 and logic level 1. The voltage ranges corresponding to different logic levels are specified by the manufacturer of the device. For bipolar TTL technology, for example, the metastable region might lie between 0.8 volts and 2.0 volts. The metastable problem occurs when the signal being input to the flip-flop is undergoing a transition from one logic level to the other simultaneously with the active edge of the local clock pulse, causing the latch section of the flip-flop to latch at an intermediate voltage level. Since the input data is changing while it is being clocked, the system designer does not care if the flip-flop goes to either a high or low logic level in this instance, just so long as the output does not "hang-up" in the metastable region. Neither level would be valid since the setup and hold was violated; so the actual result in this case is immaterial. Eventually, the output of the flip-flop will stabilize at a valid logic level; however, logic circuitry following the flip-flop depends upon the delay specification (stated time period from the clock pulse to a valid output) being met. A metastable output may cause this logic circuitry to fail. Thus, the metastable characteristics of the flip-flop used to synchronize an asynchronous data stream can influence overall system reliability. Therefore, a need has arisen for a flip-flop which corrects for metastable output conditions. SUMMARY OF THE INVENTION In accordance with the present invention, the disclosed flip-flop suppresses and effectively compensates for the occurrence of metastable phenomena. The present invention provides a flip-flop circuit including, first and second input terminals and a clock input terminal, first and second output terminals, and first and second transistors each having first and second electrodes and a control electrode for controlling the conductance of the transistor between its first and second electrodes, the first and second input terminals being respectively connected to the control electrodes of the first and second transistors, the transistors being cross connected in that the there is a first feedback path from the first electrode of the first transistor to the control electrode of the second transistor and a second feedback path from the first electrode of the second transistor to the control electrode of the first transistor, the clock input terminal being connected to the second electrodes of the transistors, and the first and second output terminals being respectively connected to points on the second and first feedback paths, characterised in that the circuit includes means responsive to the voltage at the first electrode of the second transistor to interrupt the first feedback path at a point before the connection to the second output terminal and means responsive to the voltage at the first electrode of the first transistor to interrupt the second feedback path at a point before the connection to the first output terminal. In a preferred embodiment the means may comprise output loading transistors coupled to the output terminals to ensure clamping of the cross coupled transistors. In a still further embodiment these transistors may be schottky transistors . Output glitch removal or suppressing circuitry may be added to the present invention to enhance its beneficial aspects. BRIEF DESCRIPTION OF THE DRAWING FIGURES For a more complete understanding of the present invention and the advantages thereof, reference is now made to the following description taken in conjunction with the accompanying drawings in which: FIGURE 1 illustrates a D flip-flop being used to synchronize an asynchronous data stream; FIGURE 2a-b illustrate timing diagrams of conditions under which a metastable output may occur; FIGURE 3 illustrates a previously developed implementation of a flip-flop; FIGURE 4 illustrates the flip-flop of the present invention; and FIGURE 5 illustrates a glitch removal circuit for use with the present invention. DETAILED DESCRIPTION OF THE PREFERRED EMBODIMENTS The preferred embodiment of the present invention is best understood by referring to FIGUREs 1-5 of the drawings, like numerals being used for like and-corresponding parts of the various drawings. FIGURE 1 illustrates the use of a D flip-flop to synchronize an asynchronous data stream. A D flip-flop 10 has a data input 11 receiving an asynchronous data stream 12. The output of a system clock 14 is also received by the clock input 15 of the D flop-flop 10. A synchrous data output 16 is transmitted from the terminal 17. In operation, the output 16 of the D flip-flop 10 is equal to the value of the asynchronous data stream 12 at the beginning of the clock pulse. In other words, the D flip-flop 10 outputs synchronized output data 16 which is equal to the asynchronous data stream 12 sampled at the system clock rate. The output of the D flip-flop 10 is valid after a specified time delay from the active edge of the clock pulse. Referring now to FIGURE 2a-b, the problem of metastability is illustrated. The metastability problem occurs when the asynchronous data stream 12 is undergoing a transition between two logic levels fails the set up or hold time constraints with respect to the active edge of the system clock 14. As shown in FIGURE 2a, the data stream is undergoing a logic low to logic high transition. The shaded region 18 represents the time period during which the asynchronous data stream 12 has not scttled into a valid logic level. In order to ensure a valid output, the input data must be stable at a valid logic level for a time period represented by the setup time 20 and hold time 22 requirements. The setup time requirement 20 represents the time prior to the active edge of the clock pulse 24 during which the input data should be stable at a valid logic level. The hold time 22 represents the time period during which the input data must remain stable after the active edge of the clock pulse 24. If the input data is not stable between the setup and hold times 20 and 22, the value of the output 16 is uncertain. While the output 16 may lock into a logical high or logical low value, it may also "hang up" at a voltage in the metastable region which is neither a logical high nor a logical low. Under conditions in which the setup and hold requirements 20 and 22 are met, a valid output will appear after a propagation time delay 26. However, if the output hangs up in the metastable region, an additional metastable time delay 28 is necessary before the output 16 assumes a valid logic level. It should be noted that since asynchronous data stream 12 is being sampled at a point between logic levels, either a logical high or logical low output is valid. It should also be noted that while the metastable time delay characteristic represents a time during which most metastable signals will lock into either a high or low logic level in most cases, it would still be possible for the output to hang up for periods greater than the metastable time delay 28. FIGURE 2b illustrates a signal which violates the setup and hold requirements during a logic high to logic low transition. Once again, when the setup time requirement 20 and the hold time requirement 22 are not met, the output 16 may enter the metastable region. In most cases, the output 16 will lock into either a logic high or logic low level within a time indicated by the propagation time delay 26 and the metastable time delay 28. FIGURE 3 illustrates a previously developed flip-flop circuit 30. The input 11 is connected to a bifurcating input section 31 which produces an inverted input 32 and non-inverted input 34, which are connected to a master latch section 35. The non-inverted input 34 is connected to the cathode of a first diode 36. The anode of the first diode 36 is connected to the base 38 of a first transistor 40 and to a resistor 42. The other lead of the resistor 42 is connected to a pullup resistor 44, the collector 46 of a second transistor 48, and a non-inverting output 50. The other lead of the pullup resistor 44 is connected to the power supply voltage, V cc 52. The inverting input 32 is connected to a cathode of a second diode 54. The anode of the second diode 54 is connected to the base 56 of the second transistor 48 and to a resistor 58. The other lead of the resistor 58 is connected to the collector 60 of the transistor 40, to a pullup resistor 62 and to an inverting output 64. The other lead of the pullup resistor 62 is connected to the power supply voltage, V cc 52. The emitters 66 and 68 of the transistors 40 and 48, respectively, are connected to an inverted clock 70, which is the inverted signal of the system clock 15. The non-inverted output 50 and inverted output 64 are connected to a slave latch output section 72. The system clock 15 is inverted in order to produce a falling edge in response to the active edge of the system clock. If the flip-flop is designed such that the falling edge is the active edge, no such inversion is necessary. The master section 35 comprises a latching circuit for locking in the values of the inverted and non-inverted inputs 32 and 34 at the time of the clock pulse. The slave output section 72 prevents false outputs from occurring when the inverted clock 70 is in a high state, by latching the outputs 50 and 64 at valid states. The slave output section can be implemented using two NAND gates, each having the output of the other as one input. The other inputs are supplied by the outputs 50 and 64 of the master section 35. The resistor combinations 42 and 44, and 58 and 62, are proportioned to divide the power supply voltage in a desired ratio. The resistors 42 and 58 should not be so large as to prevent the collectors 46 and 60 from drawing current therethrough. Under normal operating conditions, wherein the setup and hold time requirements are met, the input from the asynchronous data stream 11 is bifurcated into an inverted input 32 and a non-inverted input 34. Assuming, for illustration, that the input has a value of a logical 1, then the non-inverted input 34 has a logic high voltage and the inverted input 32 has a logical low voltage. Hence, the voltage at the base 38 of the first transistor 40 is substantially higher than the voltage at the base 56 of the second transistor 48. As the inverted clock signal 70 changes from a high to a low voltage, the first transistor 40 turns on when the voltage differential between the base 38 and the inverted clock signal 70 exceeds the base-emitter threshold voltage, V be , of about .7 volts. Hence, if the base 38 is at 3.8 volts, the transistor 40 will turn on when the inverted clock 70 is at a voltage of 3.1 volts. The transistor 40 will conduct from collector 60 to emitter 66, drawing current away from the base 56 of the transistor 48. Thus, the second transistor 48 is prevented from turning on while the first transistor 40 is conducting. The metastability problem occurs when the asynchronous data stream is undergoing a transition during the active edge of the system clock signal 15.If the inverted input 32 and non-inverted input 34 have an equal voltage as the inverted clock signal 70 is decreasing, it is possible that both transistors 40 and 48 will turn on simultaneously. For example, if the bases 38 and 56 both have a voltage of 1.8 volts at precisely the time that the inverted clock signal 70 is at 1.1. volts, then both transistors will conduct simultaneously. Since neither transistor will be able to turn the other off, both inverted and non-inverted outputs 64 and 50 will have the same value, resulting in a metastable output. The transistors 40 and 48 will remain on until the system is perturbed by noise on one of the lines. At that point, one transistor will begin conducting more strongly than the other and will eventually draw enough current lorm the other transistor so as to turn the other transistor off. The present invention prevents metastable conditions occurring at the master portion from affecting the slave portion. The invention can be better understood by the following conceptual example, as applied to the prior art latch of FIGURE 3. Let Δ V T be defined as the voltage difference between D and D to have valid switching i.e., no metastable condition for ΔD = |D ˙ D | ≥ V T . In this condition, no metastable conditions exists, so the master will behave normally, and valid data will be clocked in and seen at the flip-flops output. If D = D , i.e., (ΔD = 0), and the master latch is clocked, transistors 40 and 48 will conduct simultaneously. Since the latch is symmetrical, and transistors 40 and 48 are matched, both will conduct equal currents. Therefore the collectors of 40 and 48 will both fall at the same time. Due to the equilibrium both transistors will not saturate, and the collectors of 40 and 48 will remain at some equal potential. Noise may cause this potential to vary causing the collectors of 40 and 48 to rise and fall in opposite phases over some voltage range and may eventually enter a valid condition. There are two problems that can occur under these conditions. First, if transistors 40 and 48's collectors fall near the range of the threshold voltage level of the slave latch, a metastable occurrence is possible in the slave latch, and will be seen at the flip-flops output. Secondly, when 40 and 48 remain at some equal potential while the clock is low, 40 and 48 are in their active region of operation. Any noise on D and D could cause random switching of the master latch, and oscillation may result. If this should occur, metastable recovery time of the flip-flop would increase greatly. The length of time transistors 40 and 48 remain active varies and can be as long as the total length of time the CLK 70 remains low. The problem of violating setup and hold times can not be avoided, but if the master does go metastable without affecting the slave portion, the user would receive valid data, and the troublesome problems occurring from metastability would be resolved as far as the system is concerned. Referring now to FIGURE 4, a master section of a flip-flop in accordance with the present invention, which prevents the flip-flop from remaining in a metastable state, is illustrated. The master section 74 of the present invention has similar construction to the master section 35 of the D flip-flop 30 previously described in connection with FIGURE 3, with the addition of transistors 76 and 78 coupled between the collectors of transistors 40 and 48 and resistors 100 and 102. As depicted, transistor 76 has its emitter connected to the collector of transistor 48 and to the base of transistor 78. The collector of 76 is provided as Q output 1. Transistor 78 has its emitter connected to the collector of transistor 40 and to the base of transistor 76. The collector of 78 is provided as the Q output 2. The respective bases of transistors 76 and 78 are also connected through pull up resistors 100 and 102 respectively to power supply voltage, V cc 52. With this embodiment, oscillation problems are corrected in the following manner. If D = D , i.e., (Δ D = 0), the collectors of 40 and 48 will fall together as is known in the art. However in the present invention transistors 40 and 48 will both saturate, clamping their bases at the same voltage level. Since the collectors of the transistors 40 and 46 are at equal potentials a V be cannot be generated across 76 or 78 and 76 and 78 will remain off. This holds output 1 and output 2 at a constant value. If noise is present on 40 and 48'S bases, no oscillation can occur, due to 40 and 48 being clamped. This is a major advantage over the floating latch of Fig. 3. Note that the voltage at output 1 and output 2 will be equal, and will be set by the voltage dividers 44 and 42, 62 and 58. If we choose the resistors such that the voltage at output 1 and output 2 will not effect the slave latch, the flip-flop's output will remain fixed. Note that if ΔD = |D - D | ≥ V T , the metastable tolerant latch will operate normally and valid data will be seen at the output as in the regular floating latch. The above discusses operation of the present inventive latch under two normal operational conditions, i.e., ΔD = |D - D | ≧ V T , and when ΔD = 0. Another condition known to create metastable conditions is when ΔD = |D - D | < V T ; ΔD ≠ 0. Referring again to FIGURE 4, if D is greater than D by some small potential, 40 will begin to turn on earlier than 48 causing 40's collector to fall faster than 48's. This in turn will cause 76 to remain off, and output 1 voltage will remain at the potential determined by resistors 42 and 44. Since 76 is off, the feedback path from 48's collector through 76 and 40's base is broken and no oscillation in the latch can occur. This also holds true for the case when D > D by some small potential. In the case where ΔD < V T , ΔD ≠ 0 the following should be considered. Say D is greater than D by some small potential. As before 40's collector will fall before 48's thereby shutting off 76. The problem occurs when D is greater than D by just the right amount to cause 40's collector to fall below 48's collector by a V be , thereby tending to turn on 78. This would cause output 2 to start to fall. If however, D is not greater than D by the right amount, 48 may begin to turn on and tend to turn off 78 which would cause output 2 to rise again. In simpler terms a glitch is generated. The minima of the glitch is determined by ΔD. It can be shown that the glitch can be removed by added circuitry. If we can remove this glitch, in the "eyes" of the slave latch, this is in effect the same as if the master did not go metastable, and no metastable occurrence will be seen at the output. To remove this glitch the circuit of FIGURE 5 can be implemented. The glitch removal circuit depicted in Fig. 5 can be connected between respective outputs 50 and 64 of master portion 74 and respective input 80 and 82 of slave portion 72. Glitch removal circuit 79 includes OR gate 92 having one input adapted to receive the Q output of master portion 74, and another input having delay elements 88 and 90, such as inverters, serially connected to Q output 50. Similarly connected between Q output 64 of master portion 74 and input 82 of slave portion 72 is OR gate 104 having delay element 100 and 102 connected to one input and the other input connected directly to Q output 64. Although the master section 74 of the present invention has been shown as an emitter-coupled cross latch, the invention works with any type latch which may assume an equilibrium state causing a metastable output. TECHNICAL ADVANTAGES OF THE INVENTION From the foregoing the construction of a flip-flop circuitry for preventing and correcting for the occurrence of metastable conditions has been disclosed. A technical advantage of the disclosed apparatus is that invalid metastable conditions can be prevented from propagating to the flip-flop output. This allows the flip-flop to hold steady until the next valid clock signal. Another technical advantage of the invention is that the output stage of the master can be clamped during a metastable occurrence at a voltage level insufficient to affect the slave portion of a master-slave flip-flop configuration. Another attendant advantage is that a valid output can be ensured after a definite time period, despite the occurrence of metastable conditions. The present invention is applicable to all types of flip-flops, including TTL, ECL, MOS, CMOS, and other technologies, and can be used with other flip-flop configurations, such as R-S flip-flops. While the present invention has been discussed in connection with a flip-flop, any circuit which uses a latch to lock in data values is subject to metastability problems. Memory cells, flip-flops, registers, discrete latches, and other devices are all subject to the metastability problems which may benefit from the present invention.

Claims: A flip-flop circuit including, first and second input terminals (34,32) and a clock input terminal (70), first and second output terminals (OUT 1, OUT 2), and first and second transistors (40,48) each having first and second electrodes (60,66,46,68) and a control electrode (38,56) for controlling the conductance of the transistor between its first and second electrodes, the first and second input terminals (34,32) being respectively connected to the control electrodes of the first and second transistors (40,48), the transistors being cross connected in that there is a first feedback path from the first electrode (60) of the first transistor (40) to the control electrode (56) of the second transistor (48) and a second feedback path from the first electrode (46) of the second transistor (48) to the control electrode (38) of the first transistor (40), the clock input terminal (70) being connected to the second electrodes (66,68) of the transistors, and the first and second output terminals (OUT 1, OUT 2) being respectively connected to points on the second and first feedback paths, characterised in that the circuit includes means (78) responsive to the voltage at the first electrode (46) of the second transistor (48) to interrupt the first feedback path at a point before the connection to the second output terminal (OUT 2) and means (76) responsive to the voltage at the first electrode (60) of the first transistor (40) to interrupt the second feedback path at a point before the connection to the first output terminal (OUT 1). The flip-flop circuit according to Claim 1, wherein said means comprises first and second load transistors (76,78) each having a control electrode and second electrodes, and two voltage divider networks (42,44 and 58,62) for selectively connecting the first electrode of each one of said first and second transistors (40,48) to the control electrode of the other of said first and second transistors and to a respective one of the output terminals (OUT1,OUT2), said control electrodes of said first and second load transistors being connected to a reference voltage, the first electrode of the controlled current path of each of said first and second load transistors (76,78) being connected to a respective first electrode of one of said first and second transistors (40,48) and connected to the control electrode of the other load transistor, the second electrode of each of said first and second load transistors (76,78) being connected to one of the output terminals (OUT1,OUT2) and to said voltage divider networks (42,44 and 58,62). The flip-flop circuit according to Claim 2, wherein said voltage divider networks comprise: a first resistor (44) connecting a reference voltage (V cc ) to said second electrode of said first load transistor (76), to said output terminal (OUT1) connected to said second electrode of said first load transistor (76) and to a first terminal of a second resistor (42); a first diode (36) connecting a first input signal line (34) to a second terminal of said second resistor (42) and to said control electrode of said first transistor (40); a third resistor (62) connecting the reference voltage (V cc ) to said second electrode of said second load transistor (78), to said output terminal (OUT2) connected to said second electrode of said second load transistor (78) and to a first terminal of a fourth resistor (58); and a second diode (54) connecting a second input signal line (32) to a second terminal of said fourth resistor (58) and to said control electrode of said second transistor (48). A flip-flop circuit according to Claim 1, 2 or 3, wherein the control electrode of one of said first and second transistors (40,45) is connected to receive an inverted input signal and the control electrode of the other of said transistors is connected to receive a non-inverted input signal. A flip-flop circuit according to Claims 2, wherein said first and second load transistors (76,78) are schottky transistors. A flip-flop circuit according to Claim 5, wherein said means holds the voltages on the output terminals (OUT1,OUT2) at a constant value in response to the input signals being of equal voltages. A flip-flop circuit according to any one of the preceding Claims further including a slave latch circuit (72) connected to said output terminals (OUT1,OUT2). A flip-flop circuit according to Claims 7, further including first and second glitch suppression circuits (Fig.5) respectively coupling said output terminals (OUT1,OUT2) to said slave latch circuit (72). A flip-flop circuit according to Claim 6, wherein said constant value is a valid logic level. A flip-flop circuit according to Claim 9, wherein said valid logic level is a high logic level. A flip-flop circuit according to Claim 9, wherein said valid logic level is a low logic level.

Inventors: GREENBERG CRAIG B, MAXEY JAY A, OVENS KEVIN M, GREENBERG, CRAIG B., MAXEY, JAY A., OVENS, KEVIN M.
Applicants: TEXAS INSTRUMENTS INC, TEXAS INSTRUMENTS INCORPORATED
Application year: 1989
Main classification: H03K3
IPC codes: H03K3