clock doubler circuits and methods use counters to define the positions of the output clock edges. A plurality of counters are each clocked by a count clock relatively much faster than the input clock. A first counter counts for one input clock period, and the counted value is stored. The stored value is divided by two to provide the number of counts in half of the input clock period. The divided value is provided to a second counter that counts from zero to the divided value. Thus, the second counter generates a pulse halfway through the input clock period. Other counters running at the same clock rate can be used to generate pulses at other times in the input clock cycle, as desired. The pulses from the counters are used to provide output clock edges at predetermined times during the input clock cycle.
|
23. A method of providing from an input clock signal an output clock signal having a frequency twice that of the input clock signal, the method comprising:
counting a first number of counts between successive first edges of the input clock signal;
dividing the first number to provide a divided number;
counting a second number of counts following each first edge of the input clock signal and comparing the second number with the divided number;
providing a first pulse on a first signal in response to each first edge of the input clock signal;
providing a second pulse on a second signal based on results of comparing the second number with the divided-by-two number; and
providing a pulse on the output clock signal whenever a pulse is provided on one of the first and second signals.
14. A system providing from an input clock signal an output clock signal having a frequency twice that of the input clock signal, the system comprising:
means for counting a first number of counts between successive first edges of the input clock signal;
means for dividing the first number to provide a divided number;
means for counting a second number of counts following each first edge of the input clock signal and comparing the second number with the divided number;
means for providing a first pulse on a first signal in response to each first edge of the input clock signal;
means for providing a second pulse on a second signal based on results of comparing the second number with the divided-by-two number; and
means for providing a pulse on the output clock signal whenever a pulse is provided on one of the first and second signals.
1. A system comprising a clock doubler circuit, the clock doubler circuit comprising:
an input clock terminal;
an output clock terminal;
a first counter circuit having a clock terminal coupled to the input clock terminal and a plurality of output terminals;
a divide-by-two register having a plurality of data input terminals coupled to the output terminals of the first counter circuit, a clock terminal coupled to the input clock terminal, and a plurality of output terminals;
a second counter circuit having a clock terminal coupled to receive a clock update signal from the first counter circuit, a plurality of data input terminals coupled to the output terminals of the divide-by-two register, and a plurality of output terminals; and
an output clock generator having a plurality of input terminals coupled to the output terminals of the second counter circuit and an output terminal coupled to the output clock terminal of the clock doubler circuit.
2. The system of
a first oscillator circuit having an input terminal coupled to the input clock terminal and further having an output terminal; and
a first counter having an input terminal coupled to the output terminal of the first oscillator circuit and further having a plurality of output terminals coupled to the data input terminals of the divide-by-two register.
3. The system of
a second oscillator circuit having an input terminal coupled to the input clock terminal and further having an output terminal, the second oscillator circuit being implemented to oscillate with the same frequency as the first oscillator circuit;
a second counter having an input terminal coupled to the output terminal of the second oscillator circuit and further having a plurality of output terminals;
a first pulse generator circuit having a first set of input terminals coupled to the output terminals of the second counter and an output terminal coupled to a first one of the input terminals of the output clock generator; and
a second pulse generator circuit having a first set of input terminals coupled to the output terminals of the second counter, a second set of input terminals coupled to the output terminals of the divide-by-two register, and an output terminal coupled to a second one of the input terminals of the output clock generator.
5. The system of
6. The system of
a logical OR gate having input terminals coupled to the output terminals of the second counter and further having an output terminal;
a pass transistor coupled between the input clock terminal and the output terminal of the first pulse generator circuit, the pass transistor having a gate terminal coupled to the output terminal of the logical OR gate; and
a pull-down coupled to the output terminal of the first pulse generator circuit, the pull-down having a gate terminal coupled to the output terminal of the logical OR gate.
7. The system of
8. The system of
a reset input terminal; and
a flip-flop having a data input terminal coupled to the reset input terminal, a set terminal coupled to the data input terminal, a clock terminal coupled to the input clock terminal of the clock doubler circuit, and an output terminal coupled to reset input terminals of the first counter circuit, the register, and the second counter circuit.
9. The system of
11. The system of
13. The system of
15. The system of
17. The system of
19. The system of
the first number has 2 to the power of K possible values, K being an integer;
the divided number has 2 to the power of (K-1) possible values; and
the second number has 2 to the power of (K-1) possible values.
22. The system of
24. The method of
25. The method of
26. The method of
27. The method of
28. The method of
the first number has 2 to the power of K possible values, K being an integer;
the divided number has 2 to the power of (K-1) possible values; and
the second number has 2 to the power of (K-1) possible values.
29. The method of
31. The method of
|
The invention relates to clock doubler circuits. More particularly, the invention relates to counter-based clock doubler circuits and methods optionally having duty cycle correction and offset capabilities.
Clock signals are used in virtually every IC and electronic system to control timing. For example, every time a rising edge occurs on a clock signal, all the flip-flops in a circuit might change state. Clearly, the higher the frequency of the clock signal, the faster the circuit operates. Therefore, where performance is an issue, circuit designers usually prefer to use the fastest available clock that can be supported by the delays on the logic paths through the circuit. In other words, the performance of a circuit is, typically limited by the logic delays on the slowest logic path. However, sometimes the longest path delay through the circuit is significantly shorter than the period of the available clock, and the frequency of the available clock becomes the limiting factor.
To overcome this limitation, circuit designers can double the frequency of a clock signal using a phase-lock loop (PLL) or delay-lock loop (DLL) circuit. However, PLLs are analog in nature and take a long time to simulate, and a design that works in one manufacturing process may stop working when manufactured using another process. Therefore, PLLs are very difficult to design, and often are not feasible in a given circuit or system. DLLs can also be very complicated and difficult to design. Additionally, DLLS typically consume a great deal of silicon area. Therefore, clock doubling is often not feasible using known circuits and methods.
Therefore, it is desirable to provide circuits and methods that enable a circuit designer to double the frequency of an input clock without using a PLL or DLL, using a fairly simple circuit that consumes a relatively small amount of silicon area. Preferably, such circuits and methods can optionally be implemented using the logic resources included in a programmable logic device (PLD).
The invention provides clock doubler circuits and methods that use counters to define the desired positions of the output clock edges. A clock doubler circuit accepts an input clock signal and provides an output clock signal having a frequency twice that of the input clock signal. A clock doubler circuit according to an embodiment of the invention includes a plurality of counter circuits, each clocked by a count clock relatively much faster than the input clock signal. In some embodiments, each counter includes a small oscillator circuit implemented in the same fashion and generating a count clock for the counter. Thus, each counter uses a count clock having the same clock frequency.
A first counter is periodically enabled to count for one input clock period, and the counted value is stored in a register. Thus, the stored value represents the number of counts in one input clock period. The stored value is then divided (e.g., by two), the divided value representing the number of counts in a given fraction (e.g., half) of the input clock period. The divided value is then provided to a second counter that counts (for example) from zero to the divided value. Thus, the second counter generates a pulse at a predetermined time in the input clock period (e.g., halfway through the input clock period). Other counters running at the same clock rate can be used to generate pulses at other times in the input clock cycle, as desired. The pulses from the counters are used to provide output clock edges at predetermined times during the input clock cycle.
Some embodiments include a duty cycle correction feature, wherein the duty cycle of the output clock signal is independent of the duty cycle of the input clock signal. For example, the output clock signal can have a 50 percent duty cycle, or a 25 percent duty cycle. In some embodiments, the duty cycle correction feature can be enabled or disabled as desired.
Some embodiments include an offset feature to offset the predetermined times within the input clock period either forward or back (i.e., later or earlier) within the input clock period.
According to one embodiment, the invention provides a system that comprises a clock doubler circuit. The clock doubler circuit includes an input clock terminal, an output clock terminal, a first counter circuit, a register, a set counter circuit, a reset counter circuit, and an output clock generator. The first counter circuit has a clock terminal coupled to the input clock terminal and a plurality of output terminals. The register has a plurality of data input terminals coupled to the output terminals of the first counter circuit, a clock terminal coupled to the input clock terminal, and a plurality of output terminals. The set counter circuit has a clock terminal coupled to the input clock terminal, a plurality of data input terminals coupled to a first subset of the output terminals of the register, and an output terminal. The reset counter circuit has a clock terminal coupled to the output clock terminal of the set counter circuit, a plurality of data input terminals coupled to a second subset of the output terminals of the register, and an output terminal. Finally, the output clock generator has a first input terminal coupled to the input clock terminal, a set input terminal coupled to the output terminal of the set counter circuit, a reset input terminal coupled to the output terminal of the reset counter circuit, and an output terminal coupled to the output clock terminal.
Other embodiments of the invention provide methods of providing an output clock signal having a frequency twice that of an input clock signal. According to one embodiment, a method of providing from an input clock signal an output clock signal having a frequency twice that of the input clock signal includes: counting a first number of counts between successive first edges of the input clock signal; dividing the first number to provide a divided number; counting a second number of counts following each first edge of the input clock signal and comparing the second number with the divided number; providing a first pulse on the output clock signal in response to each first edge of the input clock signal; and providing a second pulse on the output clock signal based on results of comparing the second number with the divided number.
According to another embodiment, the invention provides a system that comprises a clock doubler circuit. The clock doubler circuit includes an input clock terminal, an output clock terminal, a first counter circuit, a divide-by-two register, a second counter circuit, and an output clock generator. The first counter circuit has a clock terminal coupled to the input clock terminal and a plurality of output terminals. The divide-by-two register has a plurality of data input terminals coupled to the output terminals of the first counter circuit, a clock terminal coupled to the input clock terminal, and a plurality of output terminals. The second counter circuit has a clock terminal coupled to the input clock terminal, a plurality of data input terminals coupled to the output terminals of the divide-by-two register, and a plurality of output terminals. Finally, the output clock generator has a plurality of input terminals coupled to the output terminals of the second counter circuit and an output terminal coupled to the output clock terminal of the clock doubler circuit.
According to yet another embodiment, a method of providing from an input clock signal an output clock signal having a frequency twice that of the input clock signal includes: counting a first number of counts between successive first edges of the input clock signal; dividing the first number to provide a divided number; counting a second number of counts following each first edge of the input clock signal and comparing the second number with the divided number; providing a first pulse on a first signal in response to each first edge of the input clock signal; providing a second pulse on a second signal based on results of comparing the second number with the divided number; and providing a pulse on the output clock signal whenever a pulse is provided on one of the first and second signals.
The present invention is illustrated by way of example, and not by way of limitation, in the following figures.
In the following description, numerous specific details are set forth to provide a more thorough understanding of the present invention. However, it will be apparent to one skilled in the art that the present invention can be practiced without these specific details.
The clock doubler circuit of
When input clock signal CLKIN goes high, logical OR gate 101 drives output clock signal CLK2X high. Less than one-half clock period later, signal CLKIN goes low. Signal CLK180 (provided by delay element 102) is also still low. Therefore, logical OR gate 101 drives output clock signal CLK2X low. At the half-way point of the input clock period, signal CLK180 goes high, and logical OR gate 101 drives output clock signal CLK2X high again. Less than one-half clock period later, signal CLK180 goes low. Signal CLKIN is still low, so logical OR gate 101 drives output clock signal CLK2X low. Thus, signal CLK2X has twice the frequency of signal CLKIN. The length of the high pulse is unchanged from signal CLKIN, so the duty cycle of the output signal CLK2X is twice the duty cycle of the input signal CLKIN.
As previously noted, the circuit of
When input clock signal CLKIN goes high, one-shot 203 provides a high value on signal PULSE. In response, logical OR gate 201 drives output clock signal CLK2X high. At the end of the high pulse from one-shot 203, signal PULSE goes low. Signal CLK180 (provided by delay element 102 from signal PULSE) is also still low. Therefore, logical OR gate 201 drives output clock signal CLK2X low. At the half-way point of the input clock period, signal CLK180 goes high, and logical OR gate 201 drives output clock signal CLK2X high again. At the end of the high pulse from delay element 202, signal CLK180 goes low. Signal CLKIN is still low, so logical OR gate 201 drives output clock signal CLK2X low. Thus, signal CLK2X has twice the frequency of signal CLKIN, and the duty cycle of signal CLK2X is determined by the length of the pulse generated by one-shot 203.
A pulse generated by a one-shot has a length that depends on process, power high level, and temperature. Therefore, the location of the falling edge of output signal CLK2X can vary with these factors. Further, the output pulse from one-shot 203 must be of sufficient duration to ensure a complete pulse regardless of these external factors, which can become a limiting factor to the frequency of input clock signal CLKIN.
As with the clock doubler circuit of
Because the circuit of
The clock doubler of
Signal CLK360 is provided to phase detector 406 along with input signal CLKIN, and phase detector 406 provides control signals CTRL (e.g., signals ADD and SUBTRACT, not shown) indicating a phase relationship between signals CLKIN and CLK360. State machine 407 receives control signals CTRL and provides SELECT signals that control clock multiplexers 404 and 405 to select appropriate clock signals CLK180 and CLK360. Thus, the DLL comprising elements 402-407 ensures the correct phase relationship between each signal CLK180, CLK360 and input clock signal CLKIN, and the clock doubler circuit is accurate over a range of input clock frequencies. The output clock signal CLK2X has twice the duty cycle of input clock signal CLKIN.
A significant disadvantage of the circuit of
The circuit of
The clock doubler of
Signal CLK360 is provided to phase detector 509 along with input signal CLKIN, and phase detector 509 provides control signals CTRL (e.g., signals ADD and SUBTRACT, not shown) indicating a phase relationship between signals CLKIN and CLK360. State machine 510 receives control signals CTRL and provides SELECT signals that control clock multiplexers 505-508 to select appropriate clock signals CLK90, CLK180, CLK270, and CLK360. Thus, the DLL comprising elements 501-511 ensures the correct phase relationship between each signal CLK90, CLK180, CLK270, CLK360 and input clock signal CLKIN, and the clock doubler circuit is accurate over a range of input clock frequencies. Clock generator 511 uses the signals CLKIN, CLK90, CLK180, and CLK270, which accurately reflect the starting point, one-quarter, one-half, and three-quarter points of the input clock cycle, to generate successive edges of output clock signal CLK2X. Thus, signal CLK2X has a 50 percent duty cycle.
As in the circuit of
Counter 1 (601) uses a relatively faster clock signal (e.g., generated by an oscillator circuit 626) to count a number of counts P in one period of input clock signal CLKIN. The number of counts P is stored in register 605. When signal CLKIN goes high at time T0, the power high VDD value is clocked into flip-flop 607, driving signal CLK0 high and resulting in a high value on signal CLK2X. The number of counts P is recounted, in the pictured embodiment, during every fifth input clock cycle.
Counters 2, 3, and 4 (602, 603, and 604, respectively) are clocked by similar faster clock signals (e.g., generated by oscillator circuits having the same design and configuration as oscillator circuit 626). Counter 2 (602) starts counting when input clock signal CLKIN (ClkStart) goes high, and compares the count value with one-fourth of the value stored in register 605 (i.e., P/4). Note that counter 2 does not use the two least significant bits from register 605, thus dividing the value in register 605 by four to provide the counter stop value Qstop[N:0]. When the value in counter 2 reaches P/4 (at time T1 of FIG. 7), counter 2 (602) provides a high output pulse on signal RST0. The high output pulse resets flip-flop 607, driving signal CLK0 low at time T1, as shown in FIG. 7. The high output pulse also resets counter 2. Because signal CLK180 is also low, NOR gate 611 provides a high value to inverter 610, which drives output clock signal CLK2X low at time T1.
Counter 3 (603) starts counting when input clock signal CLKIN (ClkStart) goes high, and compares the count value with one-half of the value stored in register 605 (i.e., P/2). Note that counter 3 does not use the least significant bit from register 605, thus dividing the value in register 605 by two to provide the counter stop value Qstop[N:0]. When the value in counter 3 reaches P/2 (at time T2 of FIG. 7), counter 3 (603) provides a high output pulse on signal SET180. The high output pulse clocks the power high VDD value into flip-flop 608, driving signal CLK180 high at time T2, as shown in FIG. 7. The high output pulse also resets counter 3. In response, NOR gate 611 provides a low value to inverter 610, which drives output clock signal CLK2X high at time T2.
Counter 4 (604) starts counting when signal SET180 (ClkStart) goes high, and compares the count value with one-fourth of the value stored in register 605 (i.e., P/4). Note that counter 4 does not use the two least significant bits from register 605, thus dividing the value in register 605 by four to provide the counter stop value Qstop[N:0]. When the value in counter 4 reaches P/4 (at time T3 of FIG. 7), counter 4 (604) provides a high output pulse on signal RST180. The high output pulse resets flip-flop 608, driving signal CLK180 low at time T3, as shown in FIG. 7. The high output pulse also resets counter 4. Because signal CLK0 is also low, NOR gate 611 provides a high value to inverter 610, which drives output clock signal CLK2X low at time T3.
In the pictured embodiment, the reset signal for each of counters 1-4 (601-604) and register 605 is signal RST2, which is provided by flip-flop 606. Whenever a global reset signal RST is high (active), flip-flop 606 ensures that signal RST2 is also high, resetting all counters and register 605. Whenever the global reset signal RST is low (inactive), flip-flop 606 clocks in the low value and drives signal RST2 low on the next falling edge of signal CLKIN.
In the pictured embodiment, counter 1 (601) is designed to recount the length of the input clock pulse (i.e., to generate a new value of P) every fifth clock cycle. In other embodiments, the periodicity of the count has other values, e.g., the desired periodicity can be selected based on the stability of the input clock frequency. In other embodiments, other implementations of counter circuit 601 are used. Any appropriate embodiment can be used.
Counter circuit 601 has as inputs input clock signal CLKIN and reset signal RST2. Counter circuit 601 provides a clock update signal CLK_UPDT and a counter output bus QC[N:0]. In the pictured embodiment, counter circuit 601 includes a counter 627, which counts a number of counts in one period of the input clock signal CLKIN.
In the pictured embodiment, counter circuit 601 includes reset flip-flops 621-624, set flip-flop 625, oscillator circuit 626, and counter 627. Flip-flops 621-625 are coupled in series, and serve to provide three non-overlapping clock pulses in the following repeating sequence: RST_QP, CLK_QP, and CLK_UPDT. Each of these signals is high for only one clock cycle.
Initially, signal RST_QP is high, because flip-flop 625 is a set flip-flop, and counter 627 is reset. The first rising edge of signal CLKIN brings signal RST_QP low. On the second rising edge of signal CLKIN, signal CLK_QP provides a high value on oscillator enable signal EN to oscillator circuit 626. Thus, oscillator enable signal EN is high for one out of every five input clock cycles. Oscillator circuit 626 generates a relatively fast oscillator output signal OUT (i.e., faster than input clock signal CLKIN) whenever signal EN is high. The oscillator output signal CLK_P is used by counter 627 to measure the input clock period. Thus, in the pictured embodiment counter 627 performs the counting process only during one input clock period out of each five input clock periods. On the fourth rising edge of signal CLKIN, signal CLK_UPDT goes high. On the fifth rising edge of signal CLKIN, signal RST_QP goes high again, resetting counter 627. The cycle then repeats each five clock cycles.
Note that the number of flip-flops coupled in series in counter circuit 601 determines the frequency with which the length of the input clock period is determined. For example, in the embodiment of
Any known oscillator circuit can be used to implement oscillator circuit 802 of FIG. 8 and oscillator circuit 626 of FIG. 6. Preferably, the same implementation is used for all four oscillator circuits in the clock doubler, as this approach creates a high correlation between the four oscillators irregardless of external factors such as processing and temperature variations. For example, the well known ring oscillator design (e.g., a loop including an odd number of logic gates, e.g., two inverters and a NAND gate driven by the enable signal) can be used. This embodiment is particularly useful when the clock doubler circuit is implemented in a PLD, because the oscillator can be implemented using the programmable logic blocks of the PLD. In some embodiments, external oscillators are used.
Any known counter or counters can be used to implement counter 803 of FIG. 8 and/or counter 627 of FIG. 6. For example, the well known ripple counters can be used. In some embodiments, double-edge flip-flops are used to double the count stored in the counter. In some embodiments, a first subset of the counters use double-edge flip-flops with a first oscillator frequency, while a second subset of the counters use single-edge flip-flops with a second oscillator frequency twice that of the first oscillator frequency.
Any known comparator can be used to implement comparator 804 of FIG. 8. For example, the well known exclusive-NOR (XNOR) implementation can be used, wherein each pair of bits is provided to an XNOR gate, the XNOR gates are combined using NAND gates, and the NAND gates each drive a NOR gate providing the Pulse output signal in FIG. 8.
Counter 1 (601) uses a relatively faster clock signal (e.g., generated by oscillator circuit 626) to count a number of counts P in one period of input clock signal CLKIN. The number of counts P is stored in register 605. When signal CLKIN goes high at time T0, the power high VDD value is clocked into flip-flop 607, driving signal CLK0 high and resulting in a high value on signal CLK2X. The number of counts P is recounted, in the pictured embodiment, during every fifth clock cycle.
Counters 2, 3, and 4 (602-604) are clocked by similar faster clock signals (e.g., generated by oscillator circuits having the same design and configuration as oscillator circuit 626). Counter 2 (602) starts counting when input clock signal CLKIN (ClkStart) goes high, and compares the count value with one-eighth of the value stored in register 605 (i.e., P/8). Note that counter 2 does not use the three least significant bits from register 605, thus dividing the value in register 605 by eight to provide the counter stop value Qstop[N:0]. When the value in counter 2 reaches P/8 (at time T1′ of FIG. 10), counter 2 (602) provides a high output pulse on signal RST0. The high output pulse resets flip-flop 607, driving signal CLK0 low at time T1′, as shown in FIG. 10. The high output pulse also resets counter 2. Because signal CLK180 is also low, NOR gate 611 provides a high value to inverter 610, which drives output clock signal CLK2X low at time T1′.
Counter 3 (603) functions in the same fashion as in the embodiment of
Counter 4 (604) starts counting when signal SET180 (ClkStart) goes high, and compares the count value with one-eighth of the value stored in register 605 (i.e., P/8). Note that counter 4 does not use the three least significant bits from register 605, thus dividing the value in register 605 by eight to provide the counter stop value Qstop[N:0]. When the value in the counter reaches P/8 (at time T3′ of FIG. 10), counter 4 (604) provides a high output pulse on signal RST180. The high output pulse resets flip-flop 608, driving signal CLK180 low at time T3′, as shown in FIG. 7. The high output pulse also resets counter 4. Because signal CLK0 is also low, NOR gate 611 provides a high value to inverter 610, which drives output clock signal CLK2X low at time T3′.
The embodiment of
The clock doubler circuit of
Counter 1 (601) functions in the same fashion as in
The number of counts P is provided to divide-by-eight register 1102, where the value is divided by eight and registered. For example, the division can be performed by simply shifting the number of counts by three bits towards the least significant bit (LSB), as in the embodiments of
The number of counts P is also provided to divide-by-two register 1103, but is first altered by adding or subtracting a value from the number of counts using adder/subtractor 1104. (In some embodiments, not shown, the number of counts is first divided and then offset by a predetermined value, rather than performing the offset prior to the division as in the pictured embodiment.) The offset divided value Qoffset[N:0] is divided by two (e.g., by shifting by one bit towards the LSB) and stored. One embodiment of divide-by-two register 1103 is shown in FIG. 14. The divided and offset value is provided to counter 3 (603) as the stop value Qstop[N:0] via signals Q_180[N:0]. Adder/subtractors are well known in the relevant arts, and any suitable implementation can be used.
As in previously described embodiments, counters 2, 3, and 4 (602, 603, and 604) are clocked by similar faster clock signals (e.g., generated by oscillator circuits having the same design and configuration as oscillator circuit 626). Counter 2 (602) starts counting when input clock signal CLKIN (ClkStart) goes high, and compares the count value with the value stored in divide-by-eight register 1102 (i.e., one-eighth of the value stored in register 605, or P/8). When the value in the counter reaches P/8 (at time T1′ of FIG. 12), counter 2 (602) provides a high output pulse on signal RST0. The high output pulse resets flip-flop 607, driving signal CLK0 low at time T1′, as shown in FIG. 12. The high output pulse also resets counter 2. Because signal CLK180 is also low, NOR gate 611 provides a high value to inverter 610, which drives output clock signal CLK2X low at time T1′.
Counter 3 (603) starts counting when input clock signal CLKIN (ClkStart) goes high, and compares the count value with the value stored in divide-by-two register 1103. Thus, the count value is compared to one-half of the count value P (i.e., P/2) plus or minus a predetermined offset. When the value in the counter reaches this stop value, counter 3 (603) provides a high output pulse on signal SET180. The high output pulse clocks the power high VDD value into flip-flop 608, driving signal CLK180 high, as shown in FIG. 12. The high output pulse also resets counter 3. In response, NOR gate 611 provides a low value to inverter 610, which drives output clock signal CLK2X high.
Counter 4 (604) starts counting when signal SET180 (ClkStart) goes high, and compares the count value with the value stored in divide-by-eight register 1102 (i.e., one-eighth of the count value P, or P/8). When the value in the counter reaches P/8, counter 4 (604) provides a high output pulse on signal RST180. The high output pulse resets flip-flop 608, driving signal CLK180 low, as shown in FIG. 12. The high output pulse also resets counter 4. Because signal CLK0 is also low, NOR gate 611 provides a high value to inverter 610, which drives output clock signal CLK2X low. As shown in
The register of
The circuit of
Counter 1 (601) functions in the same fashion as in
When signal CLKIN pulses high, the high pulse is echoed on output terminal CLK2X (via NOR gate 611 and inverter 610). To provide the clock doubler function, a second clock pulse must be generated halfway through the input clock cycle.
Counter 3 (603) starts counting when input clock signal CLKIN (ClkStart) goes high, and compares the count value with the value stored in divide-by-two register 1103. Thus, the count value is compared to one-half of the count value P (i.e., P/2). When the value in counter 3 reaches this stop value, counter 3 (603) provides a high output pulse on signal SET180. The high output pulse clocks the power high VDD value into flip-flop 608, driving signal CLK180 high. The high output pulse also resets counter 3. In response, NOR gate 611 provides a low value to inverter 610, which drives output clock signal CLK2X high.
Counter 4 (604) starts counting when input clock signal CLKIN goes low (signal CLKIN inverted by inverter 1501 provides signal ClkStart), and compares the count value with the value stored in divide-by-two register 1103. Thus, the count value is compared to one-half of the count value P (i.e., P/2). When the value in counter 4 reaches this stop value, counter 4 (604) provides a high output pulse on signal RST180. The high output pulse resets flip-flop 608, driving signal CLK180 low. The high output pulse also resets counter 4. Because signal CLK0 is also low, NOR gate 611 provides a high value to inverter 610, which drives output clock signal CLK2X low.
Thus, each of counters 3 and 4 (603 and 604) provides a clock edge having the same polarity as signal CLKIN, but delayed from signal CLKIN by one-half a CLKIN clock period. Thus, the clock doubler of
Note that in the pictured embodiment, when signal RST is high (active), signal RST2 is high, signal RST180 is high (because the two values being compared are both low, see FIG. 8), and signal CLK180 is low. Thus, output signal CLK2X is the same as input signal CLKIN.
In addition to the elements shown in
NAND gate 1705 is driven by signal DCC_EN and by the inverse of signal RST2. Thus, NAND gate 1705 controls the reset of counter 2 (602) by passing signal RST2 only when signal DCC_EN is high, i.e., when the DCC function is enabled. When signal DCC_EN is low (i.e., the DCC function is disabled), counter 2 (602) is always reset.
In step 1801, a first number of counts between successive first edges of an input clock signal is counted. For example, in the embodiment of
In step 1802, the first number is divided to provide a divided number. In some embodiments, the number is stored, then is divided as it is passed to another circuit (e.g., as in the embodiments of FIGS. 6 and 9). In other embodiments, the number is divided prior to being stored in a register, as in the embodiments of
In step 1803, a second number of counts following each first edge of the input clock are counted, and the second number is compared with the divided number.
In step 1804, a first pulse is provided on an output clock signal in response to each first edge of the input clock signal.
In step 1805, a second pulse is provided on the output clock signal based on the results of comparing the second number with the divided number. In some embodiments, the second pulse is provided whenever the second number is the same as the divided number. In some embodiments, the second pulse is provided whenever the second number is the same as the divided number plus an offset value. In some embodiments, the second pulse is provided whenever the second number is the same as the divided number minus an offset value.
In some embodiments, the first number of counts is repeated every M periods of the input clock signal, where M is an integer. In some embodiments, M is five.
In some embodiments, the output clock signal has a predefined duty cycle independent of a duty cycle of the input clock signal. For example, the duty cycle of the output clock signal can be 50 percent, 25 percent, or some other desired value.
Counter 1 (601) uses a relatively faster clock signal (e.g., generated by oscillator circuit 626) to count a first number of counts P in one period of input clock signal CLKIN. The first number of counts P is divided by two and stored in divide-by-two register 1941. Divide-by-two register 1941 can be implemented, for example, as shown in FIG. 14. Counter circuit 1942 is clocked by a similar faster clock signal (e.g., generated by oscillator circuits having the same design and configuration as oscillator circuit 626). The number of counts P is recounted, in the pictured embodiment, during every fifth clock cycle.
When signal CLKIN goes high at time T0, the second counter circuit 1942 begins to count and to compare the resulting second number of counts with two different values. The first value is 00 . . . 01 (all zeros with a one in the least significant bit). The second value is Q_180[N:0], the value from divide-by-two register 1941. Almost immediately (i.e., after one oscillator clock cycle), the second number is equal to 00 . . . 01, and counter circuit 1942 provides a high pulse on signal Pulse1. This pulse passes through NOR gate 611 and inverter 610 to provide a high pulse on output clock signal CLK2X from essentially time T0 (time T0 plus one oscillator clock period) to time T1″.
Halfway through the input clock cycle (at time T2), counter circuit 1942 detects that the second number is equal to Q_180[N:0], the value from divide-by-two register 1941. In response, counter circuit 1942 provides a high pulse on signal Pulse2. This pulse passes through NOR gate 611 and inverter 610 to provide a high pulse on output clock signal CLK2X from time T2 to time T3″.
Any known comparators can be used to implement comparators COMP1 and COMP2 of FIG. 21. For example, the well known exclusive-NOR (XNOR) implementation can be used, wherein each pair of bits is provided to an XNOR gate, the XNOR gates are combined using NAND gates, and the NAND gates each drive a NOR gate providing the Pulse output signal in FIG. 21.
At time T0 (see FIG. 20), signal ClkStart (CLKIN) goes high, clocking power high VDD into flip-flop 2241. Thus, signal Pulse 1 goes high at time T0. One oscillator clock period later, comparator COMP1 detects that the second number is the same as the value 00 . . . 01, and provides a high pulse on the comparator output signal Pulse. This high pulse resets flip-flop 2241, and the flip-flop output signal Pulse1 goes low again.
Signals QT[7:4] from counter 803 drive NOR gate 2351, signals QT[3:0] from counter 803 drive NOR gate 2352, and NOR gates 2351 and 2352 drive NAND gate 2353. Thus, gates 2351-2353 implement a logical OR gate that provides a low value on signal ALL_0s_B only when all of signals QT[7:0]1 are low. Inverter 2354 inverts signal ALL_0s_B to provide a high value on signal ALL_0s when all of signals QT[7:0] are low.
At time T0 (see FIG. 20), all of signals QT[7:0] are low. Thus, signal ALL_0s_B is low, and signal ALL_0s is high. Pass transistor 2355 is enabled (turned on) and passes the high value on signal ClkStart (CLKIN) to signal Pulse1. Because signal ALL_0s_B is low, pull-down 2356 is off. The high value on signal Pulse1 passes through NOR gate 611 and inverter 610. (see
Many embodiments other than those illustrated can be used to implement counter circuits 601 and 1942 of FIG. 19.
In step 2401, a first number of counts between successive first edges of an input clock signal is counted. For example, in the embodiment of
In step 2402, the first number is divided to provide a divided number. In some embodiments, the number is stored, then is divided as it is passed to another circuit (e.g., as in the embodiments of FIGS. 6 and 9). In other embodiments, the number is divided prior to being stored in a register, as in the embodiments of
In step 2403, a second number of counts following each first edge of the input clock are counted, and the second number is compared with the divided number.
In step 2404, a first pulse is provided on a first signal (e.g., signal Pulse1 in
In step 2405, a second pulse is provided on a second signal (e.g., signal Pulse2 in
In step 2406, a pulse is provided on the output clock signal whenever a pulse is provided on one of the first and second signals.
In some embodiments, the first number of counts is counted and divided (i.e., steps 2401 and 2402 are repeated) every M periods of the input clock signal, where M is an integer. In some embodiments, M is five.
Those having skill in the relevant arts of the invention will now perceive various modifications and additions that can be made as a result of the disclosure herein. For example, the above text describes the circuits and methods of the invention in the context of ICs such as programmable logic devices (PLDs). However, the circuits of the invention can also be implemented in other electronic systems, for example, in non-programmable integrated circuits, or in printed circuit boards including discrete devices.
Further, inverters, logical OR gates, NOR gates, NAND gates, flip-flops, counters, oscillators, registers, output clock generators, reset circuits, dividers, adder/subtractors, adders, subtractors, multiplexers, comparators, pull-downs, pass transistors, and other components other than those described herein can be used to implement the invention. Active-high signals can be replaced with active-low signals by making straightforward alterations to the circuitry, such as are well known in the art of circuit design. Logical circuits can be replaced by their logical equivalents by appropriately inverting input and output signals, as is also well known.
Moreover, some components are shown directly connected to one another while others are shown connected via intermediate components. In each instance the method of interconnection establishes some desired electrical communication between two or more circuit nodes. Such communication can often be accomplished using a number of circuit configurations, as will be understood by those of skill in the art.
Accordingly, all such modifications and additions are deemed to be within the scope of the invention, which is to be limited only by the appended claims and their equivalents.
Patent | Priority | Assignee | Title |
7535278, | Mar 13 2007 | XILINX, Inc. | Circuits and methods of using parallel counter controlled delay lines to generate a clock signal |
7728642, | Nov 13 2008 | XILINX, Inc. | Ripple counter based programmable delay line |
8132039, | Oct 31 2007 | Altera Corporation | Techniques for generating clock signals using counters |
Patent | Priority | Assignee | Title |
3952253, | Nov 21 1974 | The United States of America as represented by the United States Energy | Method and means for generating a synchronizing pulse from a repetitive wave of varying frequency |
4017719, | Dec 18 1975 | Lockheed Martin Corporation | Binary rate multiplier with means for spacing output signals |
4290022, | Apr 16 1979 | General Electric Company | Digitally programmable phase shifter |
5109395, | Jan 12 1990 | NEC Corporation | Decimetor circuit of simple construction and high speed operation |
5744992, | Dec 20 1995 | ST Wireless SA | Digital phase shifter |
5898329, | Dec 31 1996 | STMicroelectronics, Inc | Programmable pulse width modulation circuit |
6023199, | Jan 16 1998 | Freescale Semiconductor, Inc | Pulse width modulation circuit and method |
6259283, | Oct 25 1999 | XILINX, Inc.; Xilinx, Inc | Clock doubler circuit and method |
6285226, | Oct 25 1999 | XILINX, Inc.; Xilinx, Inc | Duty cycle correction circuit and method |
6351756, | Apr 28 1998 | NEC Electronics Corporation | Clock signal multiplier circuit for a clock signal generator circuit |
6426660, | Aug 30 2001 | GLOBALFOUNDRIES U S INC | Duty-cycle correction circuit |
Executed on | Assignor | Assignee | Conveyance | Frame | Reel | Doc |
Nov 18 2003 | NGUYEN, ANDY T | Xilinx, Inc | ASSIGNMENT OF ASSIGNORS INTEREST SEE DOCUMENT FOR DETAILS | 014737 | /0152 | |
Nov 20 2003 | XILINX, Inc. | (assignment on the face of the patent) | / |
Date | Maintenance Fee Events |
Jan 09 2009 | M1551: Payment of Maintenance Fee, 4th Year, Large Entity. |
Jan 09 2009 | M1554: Surcharge for Late Payment, Large Entity. |
Oct 02 2012 | M1552: Payment of Maintenance Fee, 8th Year, Large Entity. |
Jan 05 2017 | M1553: Payment of Maintenance Fee, 12th Year, Large Entity. |
Date | Maintenance Schedule |
Jul 05 2008 | 4 years fee payment window open |
Jan 05 2009 | 6 months grace period start (w surcharge) |
Jul 05 2009 | patent expiry (for year 4) |
Jul 05 2011 | 2 years to revive unintentionally abandoned end. (for year 4) |
Jul 05 2012 | 8 years fee payment window open |
Jan 05 2013 | 6 months grace period start (w surcharge) |
Jul 05 2013 | patent expiry (for year 8) |
Jul 05 2015 | 2 years to revive unintentionally abandoned end. (for year 8) |
Jul 05 2016 | 12 years fee payment window open |
Jan 05 2017 | 6 months grace period start (w surcharge) |
Jul 05 2017 | patent expiry (for year 12) |
Jul 05 2019 | 2 years to revive unintentionally abandoned end. (for year 12) |