This invention relates generally to measuring time periods and more specifically, to a calibrated method and apparatus to measure the frequency of and retune a high speed clock in situ.
Accurate time measurements using integrated tapped CMOS delay lines have been obtained in low voltage semiconductor environments. Rahkonen et al., Time Interval Measurements Using Integrated Tapped CMOS Delay Lines, PROCEEDINGS OF THE 32ND MIDWEST SYMPOSIUM, CIRCUITS AND SYSTEMS, pp. 202-204 (14-16 Aug. 1989) describe a time-to-digital converter wherein a start signal is propagated on a slow tapped delay line and a stop signal is propagated on an integrated relatively fast tapped delay line. The stop signal latches the output of the slow delay line and when the stop signal catches the start signal, the position of the start signal is detected by a coder and converted to a binary output word. Calibration of the time-to-digital converter is accomplished either by measuring a known time interval, calculating the tap size and scaling the results computationally, or by biasing adjustable delay elements to a proper unit delay. In any event, the calibration is dependent upon the environmental conditions affecting the delay lines and the flip-flops.
In order to continuously and accurately measure short time durations, on the order of hundreds of nanoseconds, within a reasonable tolerance on the order of fifty or fewer picoseconds, within changing environments and at low power, modification and calibration of the Rahkonen et al. device is required. Continuous measurements, moreover, permit in situ control of the high frequency oscillating signal.
These needs have been met by an apparatus and a method to accurately measure time periods in situ. The apparatus comprises a time measurement unit to receive an input of a reference clock and a high speed oscillating clock having a time period to be measured; the time measurement unit further comprising an edge-launcher that receives the rference clock and the high speed oscillating clock and in response thereto generates a plurality of signals; a plurality of fast delay units arranged in a fast delay line and a plurality of slow delay units arranged in a slow delay line, and a plurality of latches; the first of the slow delay units receiving a start signal generated by the edge-launcher, and the first of the fast delay units receiving a stop signal generated by the edge-launcher. One each slow delay unit is interconnected with one each latch to one each fast delay unit. The first of the slow delay units receives a second start signal and the first of the fast delay units receives a second stop signal to calibrate the time measurement unit. The time measurement unit further comprises a plurality of combinatorial logic, one combinatorial logic receiving the output of one latch; a linear-to-binary coder connected to the output of the plurality of combinatorial logic; a cycle counter having a plurality of counters; each counter to count and store the number of the high speed oscillating clock cycles within a time period of alternating reference clock cycles; and a register to store the output of the linear-to-binary coder and the cycle counter.
The time measurement unit measures the leading fractional edge as the time difference between a rising edge of the reference clock and the next rising edge of the high speed oscillating clock and a next leading fractional edge as the time difference from a next rising edge of the reference clock and a rising edge of the high speed oscillating clock immediately following that next rising edge of the reference clock. Counters in the cycle counter are reset on different cycles of the reference clock so that number of fractional and integral high speed oscillating clock cycles of the reference clock are measured and calibrated every reference clock cycle.
The method of the invention comprises measuring the time periods, the method comprising the steps of: inputting a reference signal and a high speed oscillating signal into an edge-launcher of a time measurement unit; launching a start signal generated from the reference signal by the edge-launcher down a slow delay line; launching a stop signal generated from the high speed oscillating signal down a fast delay line; calibrating the time measurement unit; determining when the stop signal catches the start signal; and counting the cycles of the high speed oscillating signal in each cycle of the reference signal. The time at which the stop signal catches the start signal is determined by sampling a latch connecting an output of a slow delay unit on the slow delay line and also connecting an output of a fast delay unit on the fast delay line, the sampling occurring when the stop signal arrives at each fast delay unit on the fast delay line. Calibration of the time measurement unit encompasses launching a second start signal on the slow delay line on a rising edge of the high speed oscillating signal but before a second rising edge of the reference signal, launching a second stop signal on the fast delay line on the next rising edge of the high speed oscillating signal after the second start signal is launched; and determining when the second stop signal on the fast delay line catches the second start signal on the slow delay line. Similarly, the determination of when the second stop signal on the fast delay line catches the second start signal on the slow delay line further comprises sampling a second output of a slow delay unit on the slow delay line as the second start signal traverses the slow delay units, the sampling taking place in a latch connecting the slow delay line and a fast delay unit on the fast delay line, the sampling of the second output occurring as the second stop signal travels down the fast delay line and catches the second start signal; and decoding the latch of the second output when the second stop signal catches the second start signal in a linear-to-binary coder to yield a calibration value. Counting is assured every cycle of the reference clock by enabling a first counter to count the number of cycles of the high speed oscillating signal in a first cycle of the reference signal, and storing a count in is a register, and then enabling a second counter to count the number of cycles of the high speed oscillating signal in a next cycle of the reference signal.
Other aspects and features of the present invention, as defined solely by the claims, will become apparent to those ordinarily skilled in the art upon review of the following non-limited detailed description of the invention in conjunction with the accompanying figures.
a is a simplified block diagram of features of the fraction measure block in the time measurement unit illustrating two delay lines and latches.
a, 7b, and 7c are waveforms of how the edges of a reference signal and a high speed oscillating signal can be used to launch a start signal and a stop signal down their respective delay lines and obtain a calibration of the delay lines in accordance with features of the invention.
The present invention now will be described more fully hereinafter with reference to the accompanying drawings, in which illustrative embodiments of the invention are shown. This invention may, however, be embodied in many different forms and should not be construed as limited to the embodiments set forth herein; rather, these embodiments are provided so that this disclosure will be thorough, complete, and will fully convey the scope of the invention to those skilled in the art. Like numbers refer to like elements throughout.
The time interval measurement unit 200 further comprises a fraction measure block 210, a cycle counter 220, and a temporary storage register 240. The cycle counter 220 measures and outputs 222 the integral number of fast cycles while the fraction measure block 210 measures the fractions of the fast signal. The cycle counter 220 is further described with respect to
The fraction measure block 210 measures the edges and fractions of the waveforms output from the edge-launcher 208 as described herein and provides a binary value output 212 of the leading edge fraction 242, the next leading edge fraction 244; and a binary calibration count 246. In the preferred embodiment, these three time intervals are measured for each cycle of the slow signal as described below. Output save-all 218 is a save-all signal that preserves the state of the fraction measure block 210 and the cycle counter 220.
The fraction measure block 210 contains components as shown in
Combinatorial logic 420 comprises a NAND gate 422, an AND gate 424 and an inverter 426. Thus for each latch 332 . . . 338, there is a corresponding NAND gate 422, AND gate 424, and inverter 426 arranged as in FIG. 4. One skilled in the art will also recognize that logic can be configured differently to achieve the same results. Input to a NAND gate 422 include the output of the current current latch 338 and the output 428 from the previous latch 336. The output of NAND gate 422 is 0 only when the stop signal has not yet passed the start signal clock. The output 428 from a previous latch 336 and the output from the NAND gate 422 are input to AND gate 424 which results are output at 430 to a series of OR gates of the linear-to-binary coder 360. Output 430 signals if the current latch 338 sampled a 0 and all previous latches sampled a 1. Thus, only one latch provides a binary 1 to the OR gates of the linear-to-binary coder 360. Another output of NAND gate 422 is input through inverter 426 to become input 428 of the next latch.
The linear-to-binary coder 360 comprises multiple OR gates. There is one OR gate for each binary output bit, thus if the output is an eight-bit binary number, there are eight OR gates. Of course, the number of bits required for the binary number is dependent upon the number of discrete delay units in the delay lines. Eight bits will accommodate up to 128 delay units in each line; nine bits will accommodate up to 256 delay units, and so on. Inputs to each OR gate are selected outputs 430 of the AND gates 424 corresponding to each latch 332 . . . 338. For example, the output 430 of the AND gate corresponding to the fifth latch is wired to the OR gate feeding bits 0 and 2 of the binary number; the output of the seventh AND gate of the seventh latch is wired to the OR gate feeding bits 0, 1, and 2. Thus, again, depending upon the resolution and the number of delay units, each OR gate may have tens, hundreds, or more inputs. As explained above, only the current latch 338 at which the sampled output changed from 1 to 0 will output a logic high into the linear-to-binary coder 360, all the other outputs will be low. Thus, the linear-to-binary coder 360 converts the passing delay number 318, 328 to a binary integer.
Changing now to the contents and the operation of the digital counter 220 shown in FIG. 5. The use of a single counter as the cycle counter is difficult to implement because the value in the counter has to be stored during the same cycle that the counter is being reset. To remediate this concern, two counters have been implemented which simplifies storing and resetting the counter value and measures every cycle of the reference clock. The digital counter 220 counts the integer number of high speed oscillating clock 102 that occur during every cycle of the reference clock 104. The cycle counter 220 preferably has two synchronous counters 510, 520 whose inputs are the high speed oscillating clock 102 and a counter-start pulse 224 output from the fraction measure block 210 in response to the input reference signal 104. The counter-start pulse 224 causes multiplexer 544 to pass the output of inverter 542 to flip-flop 540 which toggles enable signal 514, 518. Enable signal 514 is input to the first counter 510 on a first reference clock 104. On the next cycle of the reference clock 104, another counter-start pulse 224 toggles flip-flop 540 to provide a second enable signal 518 to the other counter 520. While the first counter 510 is counting the whole number of high speed oscillating clock cycles 102, the second counter 520 holds its count value of the high speed oscillating clocks during its cycle of the reference clock. Upon enable signal 514 to the first counter 510, multiplexer 560 toggles on every enable output from reset logic 550 and the integer value from the second counter 520 is captured in a register 248. Afterwards, a reset signal 554 is asserted by reset logic 550 into the second counter 520. When the next counter-start signal 224 occurs, the second counter 520 is enabled and begins to count whole cycles of the high speed oscillating clock; the first counter 510 holds its value captured in the register 248, the multiplexer 560 toggles and the integer count of high speed oscillating signals from the first counter during its enablement is saved to register 248. Then the first counter is reset by reset signal 552 from reset logic 550. The implementation of two or more counters in this way is a convenient implementation to count the number of high speed oscillating clock cycles in each and every reference clock cycle and simplifies storing and resetting the counter values.
Calibration of the delay lines is uniquely achieved by subtracting out the variations resulting from the environmental changes affecting the delay lines. Input and output waveforms for the calibration and measurements and the following-described method of calibration of the time measurement unit can best be understood by viewing
Note that any fractional fixed offset associated with the leading edge measurement is subtracted out thus compensating for temperature and voltage changes. The appropriate reset signal for the particular counter is generated in step 830 of
The various embodiments of the present invention described above have been presented by way of example and not limitation. The breadth and scope of the present invention is not limited by the included exemplary embodiments, but should be defined only in accordance with the following claims and their equivalents.
Number | Name | Date | Kind |
---|---|---|---|
3576532 | Kaps | Apr 1971 | A |
3753111 | Denbnovetsky et al. | Aug 1973 | A |
4544884 | Hayashi | Oct 1985 | A |
5337335 | Cloetens et al. | Aug 1994 | A |
5694377 | Kushnick | Dec 1997 | A |
5764045 | Hayashi | Jun 1998 | A |
5796682 | Swapp | Aug 1998 | A |
5818797 | Watanabe et al. | Oct 1998 | A |
5867453 | Wang et al. | Feb 1999 | A |
5903522 | Carley | May 1999 | A |
6081484 | West | Jun 2000 | A |
6501706 | West | Dec 2002 | B1 |
6597213 | Weintraub | Jul 2003 | B1 |
6741522 | Lin | May 2004 | B1 |