This invention relates in general to digital timing circuits, and more particularly to a frequency doubler for receiving an input clock signal and generating an output signal at twice the input frequency and having a fifty percent duty cycle.
Frequency doubling of clock signals is utilized in computer systems for initiating events such as, for example, updating data at the mid-point of a clock signal pulse. For instance, memory cells within random access memories (RAMs) are frequently required to be precharged, read, recharged, and then written to, all within a single local clock cycle. This procedure is known in the art as a "read, modify, write" operation. Accordingly, a frequency doubled clock signal is required to be generated, for initiating the precharge, read, recharge and write operations simultaneously with the double frequency clock signal level transitions. Thus, the generated double frequency clock signal is required to be characterized by rising level transitions simultaneous with the rising and falling transitions of the main clock signal, and falling transitions simultaneous with the mid-points of each half-cycle of the main clock signal.
According to the prior art, frequency doubling was achieved by cascading a plurality of inverters, and connecting the output of the last cascaded inverter to one input of an EXCLUSIVE OR gate. The input clock signal was applied to the second input of the EXCLUSIVE OR gate and to the input of the cascaded inverters. By accurately specifying the delay generated by the cascaded inverters, having regard to the input signal clock frequency, the signal applied to the first EXCLUSIVE OR gate input is delayed from the input clock signal by one quarter cycle, (i.e. a 90.degree. phase shift), causing the EXCLUSIVE OR gate to generate the appropriate double frequency output clock signal, as described above.
The fundamental disadvantage of such prior art frequency doublers is that the components which comprise the inverters are typically both temperature and voltage sensitive. Thus, the time delay provided by the cascaded inverters varies in an unpredictable manner in response to variations in temperature and supply voltage. Hence, the double frequency clock signal output from the EXCLUSIVE OR gate is characterized by a duty cycle which has a tendency to vary such that the positive and negative output clock signal transitions do not occur simultaneously with the mid-points of the input clock signal half-cycles. This can result in erroneous operation of the "read, modify, write" procedure discussed above.
According to the present invention, a plurality of cascaded inverters are provided forming a tapped delay line, for receiving and delaying an input clock signal by a predetermined amount. First terminals of a plurality of signal gates are connected to respective outputs of predetermined ones of the inverters. The other terminals of the signal gates are connected together and to a first input of an EXCLUSIVE OR gate. The second input of the EXCLUSIVE OR gate receives the undelayed input clock signal as described above with reference to the prior art.
The duty cycle of the double frequency signal output from the EXCLUSIVE OR gate is monitored by a control circuit, and in the event the duty cycle is greater that fifty percent, the control circuit generates a signal for enabling a predetermined one of the transmission gates in order to decrease the amount of delay in the delay line. Conversely, in the event the duty cycle is less than fifty percent, the control circuit generates a signal for enabling a different predetermined one of the transmission gates for increasing the amount of delay, thereby restoring the output signal duty cycle to fifty percent.
The output signal transitions are maintained at the mid-points of the input clock signal half-cycles, thereby overcoming the disadvantage of prior art frequency doublers wherein the pulse width and duty cycle varied in an unpredictable manner.
The circuit according to the present invention utilizes inexpensive and simple logic components in combination with a comparator, digital counter and decoder. The circuit can be advantageously implemented on a semiconductor chip, such as a CMOS circuit, in a straightforward manner.
A better understanding of the invention will be obtained with reference to the detailed description below in conjunction with the following drawings, in which:
FIG. 1 is a schematic diagram of a frequency doubler according to a preferred embodiment of the present invention, and
FIG. 2 is a timing waveform diagram illustrating the operation of the circuit in FIG. 1.
With reference to FIG. 1, an input clock signal CLKIN is applied to a plurality of cascaded inverters, arranged as a succession of delay elements, 1A, 1B to 8A, 8B. The clock signal is delayed by respective ones of the delay elements and applied to a signal lead 20 via a predetermined enabled one of a plurality of signal transmission gates 9 to 16.
Lead 20 is connected to a first input of an EXCLUSIVE OR gate 21, the second input of which is connected for receiving the input clock signal CLKIN. The output of EXCLUSIVE OR gate 21 is connected to an output terminal OUT.
The output of EXCLUSIVE OR gate 21 is also connected via an inverter 22 to the clock input (CK) of a flip-flop 23. The input clock signal CLKIN is applied to the data input (D) of the flip-flop 23, which generates a delayed or phase shifted version of the input clock signal, denoted CLKIND, from the Q output thereof in response to receiving a trigger signal on the CK input thereof, from the output of EXCLUSIVE OR gate 21. The Q output generates an inverted version of the delayed clock signal, denoted as CLKIND.
The CLKIND signal is applied to a first input of an OR gate 24, the second input of which is connected for receiving the input clock signal CLKIN. Gate 24 generates a precharge signal PRE which is connected to the gate input of a MOS transistor 25.
The input clock signal CLKIN is inverted via a further inverter 26 and applied to a first input of an AND gate 27, the second input of which is connected for receiving the CLKIND signal. Gate 27 generates a trigger pulse CPCK, described in greater detail below.
A second AND gate 28 receives the CLKIN signal on a first input thereof and the inverted delayed clock signal CLKIND on the second input thereof, and in response generates a signal TA representative of the pulse width of the first half cycle of the output signal OUT from EXCLUSIVE OR gate 21. The TA signal is applied to the gate input of a second MOS transistor 29.
Transistors 25 and 29 are connected in series between a source of positive voltage +V and ground. A node connecting the transistors carries a signal IN CMPA for application to the non-inverting input of a comparator 30.
An additional AND gate 31 receives the clock signal CLKIN on a first input thereof and the delayed clock signal CLKIND on the second input thereof and generates a further signal TB indicative of the pulse width of the second half cycle of the output signal from EXCLUSIVE OR gate 21.
The PRE signal output from OR gate 24 is also applied to the gate input of a further MOS transistor 32, and the TB signal output from AND gate 31 is applied to the gate input of yet another MOS transistor 33 connected in series with transistor 32 between the source of positive voltage +V and ground. A node connecting transistors 32 and 33 carries a signal denoted IN CMPB for application to the inverting input of comparator 30.
The output of comparator 30 carries a signal denoted as CMPOUT. The CMPOUT signal is applied to an up/down control input (UP/DN) of a 3-bit digital counter 34. Counter 34 can, of course, be a 4-bit (or greater) counter with only three outputs being utilized. The trigger pulse CPCK generated by AND gate 27 is applied to a clock input (CLK) of counter 34. The Q0-Q2 outputs of counter 34 are connected to A, B and C control inputs of a 3-to-8 bit decoder 35 for generating and applying enable signals D1-D8 to respective ones of transmission gates 9 to 16 discussed above.
Thus, in operation, the OR gate 24 in conjunction with AND gates 27, 28 and 31, generate the aforementioned precharge (PRE), trigger clock (CPCK) and pulse width (TA and TB) control signals in response to performing the designated logic operations on the input clock signal CLKIN, its complement CLKIN, the delayed version of CLKIN denoted as CLKIND, and its complement CLKIND.
With reference to FIG. 2, in the event the pulse width of the negative portion of the output signal OUT is longer than the pulse width of the positive portion, the generated TB signal output from AND gate 31 is characterized by a positive pulse which is of longer duration (i.e. wider) than the positive TA pulse output from AND gate 28. Therefore, the inverting input of comparator 30 is grounded via transistor 33 and the non-inverting input thereof is connected to +V in response to NOR gate 24 generating a positive PRE pulse for enabling transistor 25. As a result, comparator 30 generates a logic high signal CMPOUT which is applied to the UP/DN input of counter 34. In response to receiving the logic high CMPOUT signal and the CPCK trigger pulse, counter 34 increments the count value applied to the Q0-Q2 outputs. This 3-bit count value is decoded via decoder 35 such that a predetermined one of the outputs D1-D8 generates a signal for enabling a predetermined one of the gates 9-16.
Thus, for example, if transmission gate 12 had been previously enabled, and the digital count value from counter 34 is incremented, decoder 35 generates an enable signal on the D5 output thereof for enabling transmission gate 13 instead of gate 12, thereby increasing the input clock signal delay applied to the first input of EXCLUSIVE OR gate 21. By increasing the delay, the duration of the first half cycle of the output clock signal OUT, is increased, as shown in FIG. 2.
Conversely, if the first half cycle of the output clock signal is longer than the second half cycle, comparator 30 generates a logic low CMPOUT signal, causing the digital count value from counter 34 to be decremented upon receipt of the CPCK pulse. Hence, decoder 35 decodes the decremented 3-bit count value and enables gate 11 instead of gate 12, thereby decreasing the input clock signal delay applied to the first input of EXCLUSIVE OR gate 21. By decreasing the delay, the duration of the first half-cycle of the OUT signal is decreased.
Accordingly, in the event of temperature or voltage induced variations in the delay time provided by the cascaded delay elements (i.e. pairs of inverters 1A, 1B to 8A, 8B), the output signal (OUT) duty cycle is monitored and the correct delay line tap is enabled for maintaining fifty percent duty cycle of the output signal OUT regardless of such temperature and voltage variations.
A person understanding the present invention may conceive of further embodiments or variations therein, all of which are believed to be within the sphere and scope of the present invention as defined by the claims appended hereto.