Time-to-digital converter calibration
By employing open-loop calibration technology in digital phase-locked loops and generating calibration lookup tables using digital fitting methods, the problems of high power consumption, high noise, and low resolution of TDC in digital phase-locked loops are solved. This achieves fast and low-power TDC calibration, improves the resolution and linearity of TDC, and reduces clutter interference.
Patent Information
- Application Number
- CN202080100255.9
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2020-04-28
- Publication Date
- 2025-12-12
- Estimated Expiration
- 2040-04-28
AI Technical Summary
In digital phase-locked loops, the design of time-to-digital converters (TDCs) faces problems such as high power consumption, high noise, and low resolution. In particular, insufficient linearity in fractional-N mode leads to clutter interference, affecting the performance of wireless transceivers.
The open-loop calibration technique is adopted. By receiving the reference signal and the digitally controlled oscillator signal, a calibration lookup table is generated using a digital fitting method to calibrate the error value of the TDC output level. This avoids the dewinding process or adjusting the DCO frequency to an integer multiple, and directly measures the phase difference to achieve high-precision calibration.
It achieves fast, low-power TDC calibration, reduces phase noise and clutter interference, improves TDC resolution and linearity, and is suitable for TDC calibration at various DCO frequencies.
Smart Images

Figure CN115516768B_ABST
Abstract
Description
TECHNICAL FIELD
[0001] Embodiments herein relate to calibration techniques for time-to-digital converters (TDCs). In particular, embodiments herein relate to calibrating a TDC included in a digital phase-locked loop (PLL) in an open loop. BACKGROUND
[0002] An accurate local oscillator (LO) signal is required in a wireless transceiver. Typically, the LO signal is generated using a phase-locked loop (PLL). Traditionally, analog PLLs have been used, but recently digital PLLs have also been used. Both options are currently viable, each with different advantages and disadvantages. The advantage of a digital PLL is that there is no analog loop filter with large area capacitors, and it is possible to support advanced digital algorithms, e.g. to speed up frequency hopping. On the other hand, an analog PLL is much simpler to design, and can have excellent performance in terms of phase noise. For example, at very high frequencies or for very low power, the simplicity of an analog PLL makes it a good choice. However, by choosing an analog PLL, the possibility of using digital algorithms to achieve improved performance can be sacrificed.
[0003] Regardless of whether an analog or digital PLL is used, the key issue is how to achieve sufficiently low phase noise with limited power consumption and chip area without sacrificing anything else. While the traditional PLL structure using a phase-frequency detector and a charge pump has been well validated in applications, digital PLLs typically rely on a time-to-digital converter (TDC) to measure the phase error to enable the PLL to form a control signal.
[0004] TDCs tend to consume a significant portion of the power in a digital PLL. Depending on the PLL structure, they need to measure signal timing over an interval that is typically at least one period of the output signal. To achieve low in-band PLL phase noise, the timing resolution of the TDC is typically required to be less than one inverter delay, making it impossible to implement a TDC with a single delay line of inverters. The thermal and 1 / f noise must also be very low, which is difficult to achieve with long delay lines. When operating in fractional-N mode, i.e. when generating an output frequency that is a non-integer multiple of the reference in the PLL, the linearity must be very high, since non-linearity can lead to so-called fractional spurs. Fractional spurs can appear at frequencies close to the carrier, and they can be relatively strong, causing problems in that the transceiver receives or transmits signals at these unintended frequencies. High linearity means that the matching accuracy between delay line cells must be very high, requiring increased physical size. Thus, a TDC must have high performance, low noise and high resolution to minimize phase noise, and high linearity to minimize spurs. It should be clear that implementing a high performance TDC with low power consumption is a major challenge in digital PLL design.
[0005] Some calibration techniques have been proposed to improve the linearity of TDCs, relaxing their design. In D. Liao et al.,“An 802.11a / b / g / n digital fractional-N PLL with automatic TDC linearity calibration for spur cancellation,” IEEE RFIC Symposium, 2016, and in US8736384B2, a closed-loop TDC calibration technique is proposed that requires a long calibration time. More improvements are needed for TDC calibration. SUMMARY
[0006] It is therefore an object of embodiments herein to provide an improved calibration technique for a TDC comprised in a phase-locked loop (PLL).
[0007] According to a first aspect of embodiments herein, the object is achieved by a calibration unit for calibrating a time-to-digital converter (TDC) and a method thereof. The TDC is configured to receive a signal having a reference frequency F REF and a signal from a digitally controlled oscillator (DCO) having a frequency F DCO .
[0008] The calibration unit receives output data samples from the TDC within a predefined time period.
[0009] The calibration unit performs a de-wrapping procedure on the data samples.
[0010] The calibration unit generates reference line segments from the data samples using a digital fitting method.
[0011] The calibration unit calculates an error value for each output data sample associated with a TDC output level by calculating a deviation of each output data sample from a corresponding reference level of at least one reference line segment.
[0012] The calibration unit accumulates the error values of the data samples associated with the TDC output levels in accumulators for the TDC output levels.
[0013] The calibration unit increases a counter value for a TDC output level by one when an error value of a data sample associated with the TDC output level is added to its accumulator.
[0014] The calibration unit averages the error values for each TDC output level by dividing the accumulated error values for each TDC output level in its accumulator by its counter value.
[0015] The calibration unit generates a calibration lookup table comprising an error vector of average error values of TDC output levels.
[0016] According to a second aspect of embodiments herein, the object is achieved by a calibration unit for calibrating a time-to-digital converter (TDC) and a method thereof. The TDC is configured to receive a signal having a reference frequency F REF and a signal from a digitally controlled oscillator (DCO) having a frequency F DCO . The DCO frequency F DCO is set to be close to an integer multiple of the reference frequency F REF so that a plurality of slopes of output data samples are generated from the TDC.
[0017] The calibration unit receives output data samples from the TDC during a predefined time period.
[0018] The calibration unit detects a boundary between the slopes by observing whether an output data sample has a large and sudden transition compared to a previous output data sample.
[0019] For each slope of TDC output data samples, the calibration unit generates a reference line for the slope using a digital fitting method.
[0020] The calibration unit calculates an error value for each of the output data samples associated with a TDC output level by calculating a deviation of each output data sample in the slope from a corresponding reference level of the reference line of the slope.
[0021] The calibration unit accumulates the error values of data samples associated with the TDC output levels in accumulators for the TDC output levels.
[0022] The calibration unit increases a counter value for a TDC output level by one when an error value of a data sample associated with the TDC output level is added to its accumulator.
[0023] When the slopes of output data samples have been analyzed and the accumulators and the counters have been updated, the calibration unit averages the error values for each TDC output level by dividing the accumulated error values in its accumulator for each TDC output level by its counter value.
[0024] The calibration unit generates a calibration lookup table comprising an error vector of average error values of TDC output levels.
[0025] Embodiments herein provide a calibration technique that works with a digital PLL in open loop. A TDC receives a signal from a free-running DCO and receives a reference signal and measures the time difference between the DCO and the reference signal edges. Since the reference frequency F REF and the DCO frequency F DCO are not phase-locked, a sawtooth-shaped output data sample is observed from the TDC, which represents the phase or time difference between the two signals.
[0026] There are two options for performing the open loop calibration. One option is to perform a de-wrapping procedure, as described in a first aspect of embodiments herein, i.e. the data samples are processed to form a ramp of output levels. In this case, the gain or de-wrapping step of the TDC needs to be estimated. This can be done by estimating the TDC output level difference over a time period corresponding to one DCO period, and in turn adding or subtracting a step function with the estimated TDC output level difference to / from the data samples, such that the sawtooth-shaped output data samples are converted to a single ramp of all output data samples. By de-wrapping the output data samples and comparing them to one or more reference line segments, the error of each data sample can be estimated.
[0027] In another option for performing the open loop calibration, as described in a second aspect of embodiments herein, no de-wrapping procedure is needed. The DCO frequency is in turn set to be closer to an integer multiple of the reference frequency. This will directly generate longer ramps at the output of the TDC. The benefit of using this scheme is that by avoiding the de-wrapping procedure, the gain of the TDC does not need to be estimated and the original TDC output data samples can be used directly. For each ramp, the data samples are compared to the reference line of the ramp and the error values of the output data samples in the ramp are calculated. After all data sample ramps have been processed, the error values for each TDC output value are averaged for better accuracy. As a result, a calibration lookup table is generated, which comprises an error vector of the average error values of the TDC output levels. This calibration lookup table can in turn be used for digital correction, i.e. post distortion, or for calibrating the TDC by e.g. programming the node capacitors or bias currents of the TDC.
[0028] The calibration techniques according to embodiments herein have some advantages:
[0029] • The calibration techniques are open loop, and thus very fast.
[0030] • Calibration can be performed at the lowest DCO frequency and in turn can calibrate the full TDC range needed in PLL operation.
[0031] • During calibration, there is no interaction from the PLL affecting the calibration results due to open loop.
[0032] • DCO frequency drift is allowed by dividing the data samples into a series of independent line fits.
[0033] Accordingly, embodiments herein provide an improved calibration technique for a TDC included in a phase-locked loop (PLL). BRIEF DESCRIPTION OF DRAWINGS
[0034] Examples of embodiments herein are described in more detail with reference to the accompanying drawings, in which:
[0035] Figure 1 is a schematic block diagram of a calibration system according to embodiments herein;
[0036] Figure 2 is a schematic diagram illustrating an example of output data samples from a TDC;
[0037] Figure 3 is a block diagram illustrating the block functionality of a calibration unit according to embodiments herein;
[0038] Figure 4 is a flowchart of a calibration method according to one embodiment herein;
[0039] Figure 5 is a schematic diagram illustrating a de-windup process according to embodiments herein;
[0040] Figure 6 is a schematic diagram illustrating simulation results for actual and estimated TDC output errors;
[0041] Figure 7 is a block diagram illustrating the block functionality of a calibration unit according to embodiments herein;
[0042] Figure 8 is a flowchart of a calibration method according to another embodiment herein;
[0043] Figure 9 is a schematic diagram illustrating simulation results for actual and estimated TDC output errors and residual errors; and
[0044] Figure 10 is a block diagram illustrating an electronic device in which a calibration unit according to embodiments herein can be implemented. DETAILED DESCRIPTION
[0045] Figure 1A calibration system 100 for calibrating a TDC according to embodiments herein is shown. From Figure 1 it can be seen that the calibration system 100 comprises a calibration unit 110 for calibrating a TDC 120 comprised in a digital PLL 150. The digital PLL 150 further comprises a DCO 130. The DCO 130 is self-excited and excites the TDC 120. The digital PLL 150 is assumed to be dividerless, thus the DCO 130 is connected directly to the TDC 120, which is a common approach to eliminate divider power consumption and potential phase noise increase. However, there is nothing in the TDC calibration technique that would prevent using a PLL structure with a divider. In order to keep the figure simple, in this case it can be assumed that the divider is comprised in the DCO 130 block, while other parts (e.g. the loop filter of the PLL) are not shown in Figure 1 . The TDC 120 receives a reference signal with a reference frequency F REF and a signal from the DCO 130 with a frequency F DCO .
[0046] When the DCO 130 is set at a constant frequency, preferably at its lowest frequency, the output of the TDC 120 is monitored. The TDC 120 measures the time or phase difference between the edges of the reference signal and the signal from the self-excited DCO 130. These two signals are almost constant in frequency, especially the reference signal, while the DCO 130 will have some more drift. Since the reference frequency F REF and the DCO frequency F DCO are not phase-locked, the time difference between the edges of these two signals will develop linearly over time due to the fixed frequency difference. From the TDC 120 output TDC_raw_out_nonlinear the output data samples are observed to have a sawtooth shape, where each data point represents a linearly increasing or decreasing time difference sampled at the reference frequency rate. When the phase difference exceeds one period of the DCO frequency or becomes negative, another edge of the DCO will enter the measurement range of the TDC and the output will suddenly change by an amount corresponding to one DCO period. At that time there will be a wrap-around of the TDC output level, thus generating a sawtooth shaped signal. Thus, when monitoring the TDC output over a predefined time period, as shown in Figure 1 , a number of ramps of output data samples are observed at the output TDC_raw_out_nonlinear of the TDC 120, which are further shown in Figure 2 .
[0047] If F DCO is close to F REFIf the number of TDC output levels is a multiple of the number of slopes, most of the TDC output levels will be excited in each slope. This is desirable because more TDC output levels can be collected from each slope without the need to wrap around, and after several slopes many error estimates for each TDC output level can be computed. In turn, the error estimates for each TDC output level can be averaged to obtain higher accuracy. The average error estimate for each TDC output level can be stored in a calibration lookup table 140, which can be used for post-distortion. For each TDC output level, the corresponding calibration value from the lookup table 140 is added to the output of the TDC for correction. This is indicated in Figure 1 by the summation unit 160 producing the calibrated output TDC_raw_out_linear.
[0048] There are different options for performing open loop calibration. One option is to perform a unwrap procedure on the output data samples from the TDC 120. One option is to perform calibration on the output data samples from the TDC 120 without the need for an unwrap procedure.
[0049] According to one embodiment herein, a method for calibrating a TDC 120 (with an unwrap procedure on the output data samples from the TDC 120) performed in a calibration unit 110 will be described with reference to Figure 3 and Figure 4 Figure 3 is a block diagram illustrating the block functions of the calibration unit 110, Figure 4 is a flow chart of the calibration method. The calibration unit 110 comprises a receiving unit 111, an estimation unit 112, an unwrap unit 113, a line fitting unit 114, an accumulator unit 115, a counter unit 116 and an averaging unit 117. The method comprises the following actions.
[0050] Action 410
[0051] The calibration is performed by first collecting TDC 120 output data samples in the receiving unit 111. The calibration unit 110 receives output data samples from the TDC 120 over a predefined time period. As described above, the TDC 120 receives a signal with a reference frequency F REF and a signal from the DCO 120 with a frequency F DCO , measures the time or phase difference between the edges of the two signals and outputs a data sample.
[0052] Action 420
[0053] The calibration unit 110 performs an unwrap procedure on the data samples in the estimation unit 112 and the unwrap unit 113.
[0054] This action performs a de-wrapping process on the output data samples from the TDC 120. To perform the de-wrapping process, the de-wrapping step size of the TDC, i.e., the TDC gain, needs to be accurately estimated. This can be done by estimating the difference in TDC output levels over a time period corresponding to one DCO cycle, and then adding or subtracting a step function with a step size equal to the estimated TDC output level difference to or from the data samples. That is, a stair-like de-wrapping step associated with the estimated TDC output level difference is placed at the sample where the value suddenly changes due to phase wrap-around. For example, a first de-wrapping value equal to the estimated TDC gain is added to the first data sample where the value suddenly changes, and is added to the data samples following the first data sample until the next data sample where the value suddenly changes. A second de-wrapping value equal to twice the estimated TDC gain is added to the next data sample, i.e., the second data sample where the value suddenly changes, and is added to the data samples following the second data sample until the next sample where the value suddenly changes, and so on. In this way, the data samples are de-wrapped so that the difference in value between each data sample and its next data sample becomes close to a constant. In Figure 5 This de-wrapping process is shown in FIG. 4, where the output data samples, the stair-like de-wrapping values, and the data samples where the value suddenly changes are shown intuitively for easy understanding. It can be seen that after the de-wrapping process, the sawtooth shape of the output data samples is converted to a single slope of the data samples.
[0055] A method to accurately estimate the TDC 120 gain can be to adjust the de-wrapping step size to minimize the estimated mean square error of the data samples over several reference line segments. When the square error is minimized, the TDC gain or the de-wrapping step size is correctly estimated, and the de-wrapping process will then introduce the least deviation from the reference line segments. This estimation requires some computation, but on the other hand, the DCO 130 frequency does not need to be adjusted to be close to an integer multiple of the reference frequency F REF .
[0056] Action 430
[0057] The calibration unit 110 generates one or more reference line segments from the data samples using a numerical fitting method in the line fitting unit 114. For example, the one or more reference line segments can be calculated using a least squares sum method, and each reference line segment comprises a perfectly linear response that fits the actual TDC output over a time interval. The reference line segment can be characterized by parameters in a mathematical equation. For example, it can use a start point and an end point of the line from which points in between are interpolated. Alternatively, it can use one point, e.g. the start point, an intermediate point, or the end point, the slope of the line, and possibly also a parameter indicating the length of the line in which the evaluation is to be performed. In some embodiments, other parameters can also be used to characterize the reference line segment. For example, any two points on the line segment, or any single point together with a parameter indicating the slope can be used. For a sample time within the valid interval of the line, the value of the line can then be calculated using the equation of the line and the parameters found by the numerical fitting method.
[0058] Action 440
[0059] The calibration unit 110 calculates an error value for each output data sample associated with a TDC output level by calculating the deviation of each output data sample in the output data sample from the corresponding reference level of at least one reference line segment. For example, as shown in FIG. 4B, the error values Err(n), Err(n-1), Err(n-2)... for the output levels TDC_out(n), TDC_out(n-1), TDC_out(n-2)... are calculated as the difference between the output level and the reference line, respectively. Each TDC output level has a plurality of data samples, each data sample having an associated TDC output level. To improve the accuracy of the calibration, the number of data samples associated with each TDC output level should be sufficient. Figure 3
[0060] By de-bunching the data samples and fitting them to the reference line, the error of the TDC can be estimated for each output data sample.
[0061] To allow for some drift of the DCO frequency, the reference line can be broken into shorter segments that can have different slopes, i.e. frequency differences. As long as the DCO frequency drifts very little during one segment, the assumption that the TDC output should ideally follow the line holds, and deviations from the line can be correctly detected.
[0062] Action 450
[0063] The calibration unit 110 accumulates in the accumulator unit 115 the error values of the data samples associated with the TDC output levels in accumulators for the TDC output levels. Each TDC output level has its own accumulator in the accumulator unit 115. The error values of the data samples associated with a TDC output level that are calculated in act 440 are accumulated for that TDC output level. At the start of each calibration, the accumulated error vector is reset to zero.
[0064] Act 460
[0065] When an error value of a data sample associated with a TDC output level is added to its accumulator, the calibration unit 110 increments in the counter unit 116 the counter value of that TDC output level by one. Each TDC output level has its own counter in the counter unit 116.
[0066] Act 470
[0067] The calibration unit 110 averages in the averaging unit 117 the error values of each TDC output level by dividing the accumulated error value in its accumulator by its counter value.
[0068] Act 480
[0069] The calibration unit 110 generates a calibration lookup table that comprises an error vector of the averaged error values of the TDC output levels. In the calibration lookup table, each TDC output value has a calibration value.
[0070] The error vector in the calibration lookup table can be used for post-distortion. As shown in Figure 1 The calibration can be applied by a simple summation in the summation unit 160, as shown in
[0071] As shown in Figure 3 To perform the above calibration method with acts 410-480, the calibration unit 110 comprises an estimation unit 111, a de-bwound unit 112, a line fitting unit 113, an accumulator unit 114, a counter unit 115, and an averaging unit 116.
[0072] The calibration unit 110 is configured to receive output data samples from the TDC within a predefined time period.
[0073] The calibration unit 110 is configured (by the estimation unit 111 and the de-wrapping unit 112) to perform a de-wrapping procedure on the data samples.
[0074] The calibration unit 110 is configured (by the line fitting unit 113) to generate reference line segments from the data samples using a numerical fitting method and to calculate an error value for each of the output data samples associated with a TDC output level by calculating a deviation of each of the output data samples from a corresponding reference level of at least one of the reference line segments.
[0075] The calibration unit 110 is configured (by the accumulator unit 114 and the counter unit 115) to accumulate the error values of the data samples associated with a TDC output level in an accumulator of the TDC output level and to increase a counter value of the TDC output level by one when an error value of a data sample associated with the TDC output level is added to its accumulator.
[0076] The calibration unit 110 is configured (by the averaging unit 116) to average the error values for each TDC output level by dividing the accumulated error values in its accumulator by its counter value.
[0077] The calibration unit 110 is configured to generate a calibration lookup table comprising an error vector of the averaged error values of the TDC output levels.
[0078] Another option is to perform calibration on the output data samples from the TDC 120 without a de-wrapping procedure. The DCO frequency has to be adjusted usually to trade off not having to estimate the de-wrapping step size. The DCO frequency can be set to be closer to an integer multiple of the reference frequency, i.e. F DCO ~ N * F REF but F DCO ≠ N * F REF This will provide longer output ramps from the TDC without de-wrapping. The closer the DCO frequency is to a multiple of the reference frequency, the more output levels of the TDC will be fired and the longer the ramp. That is, the closeness to an integer is related to the number of data samples in each ramp, the closer it is, the more data samples in each ramp. For example, if the fractional part of the frequency ratio is 0.05, there will be about 1 / 0.05 = 20 data samples per ramp. Depending on the DCO structure, the frequency can be set by e.g. a capacitor bank or setting the current of a ring oscillator. The benefit of using this scheme is that by avoiding the de-wrapping procedure, there is no need to estimate the gain of the TDC and the raw TDC output data samples can be used directly.
[0079] In Figure 6The number of TDC output levels for a certain performance can be seen. Figure 6 Simulation results for the actual and estimated TDC output integral non-linearity (INL) error are shown in FIG. 6 REF = 200 MHz, F DCO = 5799 MHz, where the TDC resolution is 2 ps and the calibration time is 100 ps). Each output level has on average 64 data samples. It can be seen that the proposed calibration technique can accurately estimate very small errors in less than 100 ps total time after 64 data sample readings for each output level.
[0080] The number of TDC levels depends on the resolution of the TDC and the range covered by the TDC. A finer resolution and a larger range will result in a need for more TDC output levels.
[0081] For example, the reference frequency F REF 200 MHz has a clock period of 5 ns. In the calibration time of 100 us, there will be a total of 20000 reference clock periods in that time, i.e. the TDC 120 can produce 20000 output data samples. When the DCO period is about 172 ps, it will reach 172 ps / 2 ps = 86 TDC output levels. On average, it will get 20000 / 86 ~ 233 data samples per TDC output level.
[0082] The TDC output will only shift and produce a new output level when the phase drift between the DCO and the reference signal has shifted enough to reach a new discrete output level of the TDC. Figure 6 The frequency ratio in is 5799 / 200 = 28.995, which gives a phase or time difference of 0.005 * DCO-period, i.e. 0.005 * 1 / 5799 MHz = 0.005 * 172.44 ps = 0.8622 ps. The resolution of the TDC is 2 ps. This means that the TDC will on average stay at each output level for 2 ps / 0.8622 ps = 2.3196 reference periods. In this case, the DCO frequency is well chosen and the TDC runs 20000 / (2.3196 * 86) ~ 100 ramps in the calibration time. For good performance and accuracy, it is good if the TDC runs at least 10 ramps.
[0083] The reference Figure 7 and Figure 8 to describe a method for calibrating the TDC 120 in the calibration unit 110 without performing a de-bounce process on the output data samples from the TDC 120. Figure 7 is a block diagram showing the block functionality of the calibration unit 710, Figure 8is a flowchart of the calibration method. The calibration unit 110 comprises a receiving unit 711, a detecting unit 712, a line fitting unit 713, an accumulator unit 714, a counting unit 715 and an averaging unit 716. The method comprises the following actions.
[0084] Action 810
[0085] The calibration is performed by first collecting TDC output data samples. The calibration unit 110 receives output data samples from the TDC 120 for a predefined time period through the receiving unit 711. As Figure 7 indicated in Fig. 2, the TDC 120 receives a signal with a reference frequency F REF and a signal from the DCO 130 with a frequency F DCO . The DCO frequency F DCO is set to be close to an integer multiple of the reference frequency F REF so that a ramp is generated from the TDC 120 whose output data samples are intuitively shown in Fig. 2 as TDC_raw_out_nonlinear. Figure 7
[0086] Action 820
[0087] The calibration unit 110 detects the boundaries between the ramps in the detecting unit 712 by observing whether an output data sample has a large and sudden transition compared to the previous output data sample. In this case, the wrap-around detection can for example be triggered by a large jump in the output of the TDC. When the wrap-around detection is triggered, the sample and the following samples are considered to belong to a new ramp of data samples. In this way, based on the detected boundaries, the data samples are divided into ramps.
[0088] The data samples collected in one ramp are checked to see if there is a sufficient number of samples. If not, the DCO frequency needs to be adjusted so that it is close to an integer multiple of the reference frequency F REF . From simulations, values within N*F REF ± F REF *5% are sufficient to accurately estimate the TDC output error, but it is to be noted that the frequency of the DCO should not be exactly at an integer multiple of the reference frequency, as in this case the output from the TDC would be constant instead of a ramp.
[0089] Action 830
[0090] For each ramp of TDC output data samples, the calibration unit 110 generates a reference line for the ramp in the line fitting unit 713 using a numerical fitting method, as Figure 2 The output data samples, the TDC output levels, the reference lines, the reference line fits are intuitively shown in Fig. 6, wherein each reference line consists of a slope of reference output levels representing a perfectly linear output of the TDC. In this way, one reference line per slope of output data samples is achieved. Similar to the discussion in action 430 above, the reference lines can be characterized by parameters in a mathematical equation.
[0091] Action 840
[0092] The calibration unit 110 calculates in the line fitting unit 713 an error value for each of the output data samples associated with a TDC output level by calculating the deviation of each output data sample in the slope from the corresponding reference level of the reference line of this slope.
[0093] Action 850
[0094] The calibration unit 110 accumulates in the accumulator unit 714 the error values of the data samples associated with a TDC output level in an accumulator for this TDC output level. Each TDC output level has its own accumulator in the accumulator unit 714. The calculated error values of the data samples associated with a TDC output level are accumulated for this TDC output level. In other words, an error vector is obtained for all TDC output levels, one entry per TDC output level. This error vector is accumulated. At the beginning of each calibration, the accumulated error vector is reset to zero.
[0095] Action 860
[0096] There is also a corresponding vector of counters, the counter unit 815, one for each TDC output level and reset to zero at the beginning of each calibration. When an error value of a data sample associated with a TDC output level is added to its accumulator, the calibration unit 110 increases the counter value of this TDC output level by one. This means that each TDC output level has its own counter in the counter unit 815. When the accumulators are updated with error values from one slope, the corresponding counters are updated as well.
[0097] Action 870
[0098] When the slopes of output data samples have been analyzed and the accumulators and counters have been updated, the calibration unit 110 averages the error values for each TDC output level by dividing the accumulated error value in its accumulator by its counter value for each TDC output level. This action is performed once enough error values are recorded for each output level. By enough error values, it is meant either a required precision set by the user or a minimum number of readings for each level.
[0099] Action 880
[0100] The calibration unit 110 generates a calibration lookup table comprising an error vector of average error values of TDC output levels. In this calibration lookup table, each TDC output value has a calibration value.
[0101] As Figure 7 To perform the calibration actions 810-880, the calibration unit 710 comprises a detection unit 712, a line fitting unit 713, an accumulator unit 714, a counter unit 715 and an averaging unit 716, as shown in Fig. 8.
[0102] The calibration unit 710 is configured to receive output data samples from the TDC within a predefined time period.
[0103] The calibration unit 710 is configured (by the detection unit 712 being configured to) detect boundaries between ramps by observing whether an output data sample has a large and sudden transition compared to a previous output data sample.
[0104] For each ramp of a TDC output data sample, the calibration unit 710 is configured (by the line fitting unit 713 being configured to) generate a reference line for this ramp using a numerical fitting method and calculate an error value for each of the output data samples associated with a TDC output level by calculating a deviation of each output data sample in the ramp from a corresponding reference level of the reference line of this ramp.
[0105] The calibration unit 710 is configured (by the accumulator unit 714 and the counter unit 715 being configured to) accumulate error values of data samples associated with a TDC output level in an accumulator for this TDC output level and increase a counter value for this TDC output level by one when an error value of a data sample associated with this TDC output level is added to its accumulator.
[0106] When the ramps of these output data samples have been analyzed and these accumulators and counters have been updated, the calibration unit 710 is configured (by the averaging unit 716 being configured to) average the error values for each TDC output level by dividing the accumulated error values in its accumulator for each TDC output level by its counter value.
[0107] The calibration unit 710 is configured to generate a calibration lookup table comprising an error vector of average error values of the TDC output levels.
[0108] While the calibration algorithm according to embodiments herein is able to detect very small errors well in a given time, it is also important to be able to solve larger errors in a shorter time. Thus, for the same simulation example as before, the integral non-linearity (INL) error was increased to ± 1 least significant bit (LSB) to see how fast the calibration algorithm is able to detect it and still produce acceptable results. The estimated error and the actual error (left-hand side plot) and the error residual (right-hand side plot), i.e. the post-correction error, is shown in Figure 9 Figure 9 As can be seen from Figure 9 at 10 μS, the error residual is about ± 0.06 LSB, as shown in the upper right-hand side plot. It can also be seen that the estimated error improves when the TDC is calibrated for a longer period of time. For example, at 50 μS, the error residual is about ± 0.03 LSB, as shown in the middle right-hand side plot, and at 100 μS, the error residual is about ± 0.06 LSB, as shown in the lower right-hand side plot.
[0109] In summary, by performing the calibration at low DCO frequencies or at very low DCO frequencies, the largest DCO period time is obtained, and the TDC range corresponding to the DCO period will be calibrated, and the TDC in turn will be calibrated over the full timing range that it can need during PLL operation. By performing the calibration in open loop, a high-speed calibration is achieved as well as an accurate estimation of the error, since there is no need to wait for the loop to settle down before the calibration can start. Furthermore, by keeping the DCO control voltage fixed during the calibration, the loop will not affect the calibration results, and the output error of the TDC can be measured directly without interaction from the PLL. These are some advantages compared to prior art solutions utilizing closed loop TDC calibration techniques.
[0110] The calibration unit 110, 710 together with the TDC 120 and the DCO 130 in the PLL circuit 150 can be used in various integrated circuits, electronic circuits, communication devices or apparatuses. Figure 10 A block diagram of an electronic device 1000 in which a calibration unit 110, 710 according to embodiments herein can be implemented is shown. The electronic device 1000 in which a calibration unit 110, 710 according to embodiments herein can be implemented can comprise a receiver or a transmitter or both, i.e. a transceiver TX / RX 1010. The electronic device 1000 can comprise other units, of which a memory 1020, a processing unit 1030 are shown. The electronic device 1000 can be any one of a base station for a cellular communications system, a wireless communication device such as a user equipment or a mobile device.
[0111] When used in the present document, the word "comprise" is to be interpreted as non-limiting, i.e. meaning "comprises at least".
[0112] The embodiments herein are not limited to the preferred embodiments described above. Various alternatives, modifications and equivalents can be used. Therefore, the above described embodiments are not to be taken in a limiting sense but are made for the purpose of description only. The scope of the application is to be interpreted only from the appended claims.
Claims
1. A method for calibrating a time-to-digital converter, TDC, (120) performed in a calibration unit (110), wherein, The TDC is configured to receive a signal having a reference frequency F REF and a signal from a digitally controlled oscillator DCO (130) having a frequency F DCO , the method comprising: receiving (410) output data samples from the TDC over a predefined time period; performing a de-bounce process on the data samples (420); generating (430) reference line segments from the data samples using a numerical fitting method; calculating (440) an error value for each output data sample associated with a TDC output level by calculating a deviation of each of the output data samples from a corresponding reference level of at least one reference line segment; accumulating (450) the error values of the data samples associated with a TDC output level in an accumulator for that TDC output level; increasing (460) a counter value for a TDC output level by one when an error value of a data sample associated with that TDC output level is added to its accumulator; averaging (470) the error values for each TDC output level by dividing the accumulated error values in its accumulator by its counter value; generating (480) a calibration lookup table comprising an error vector of the averaged error values for the TDC output levels.
2. The method for calibrating a TDC of claim 1, wherein, processing the data samples includes estimating a TDC output level difference over a time period corresponding to one DCO cycle and adding or subtracting a step function having the estimated TDC output level difference to or from the data samples such that the data samples over the predefined time period are converted from a sawtooth shaped output level to a single ramped output level.
3. A calibration unit (110) for calibrating a time-to-digital converter, TDC, (120), wherein The TDC is configured to receive a signal having a reference frequency F REF and a signal from a digitally controlled oscillator DCO (130) having a frequency F DCO The calibration unit (110) is configured to: receiving output data samples from the TDC over a predefined time period; performing a de-bounce process on the data samples; generating reference line segments from the data samples using a numerical fitting method; calculating an error value for each output data sample associated with a TDC output level by calculating a deviation of each of the output data samples from a corresponding reference level of at least one reference line segment; accumulating the error values of the data samples associated with a TDC output level in an accumulator for that TDC output level; increasing a counter value for a TDC output level by one when an error value of a data sample associated with that TDC output level is added to its accumulator; averaging the error values for each TDC output level by dividing the accumulated error values in its accumulator by its counter value; and generating a calibration lookup table comprising an error vector of the averaged error values for the TDC output levels. receiving (810) output data samples from the TDC over a predefined time period; 4. A method performed in a calibration unit (710) for calibrating a time-to-digital converter, TDC, wherein, The TDC is configured to receive a signal having a reference frequency F REF and a signal from a digitally controlled oscillator (DCO) having a frequency F DCO , wherein the frequency F DCO is set to be close to an integer multiple of the reference frequency F REF , such that a plurality of ramps of output data samples are generated from the TDC, the method comprising: detecting (820) boundaries between ramps by observing whether an output data sample has a large and sudden transition compared to a previous output data sample; for each ramp of the TDC output data samples, generating (830) a reference line for the ramp using a numerical fitting method, calculating (840) an error value for each of the output data samples associated with a TDC output level by calculating the deviation of each output data sample in a slope from the corresponding reference level of the reference line of that slope; accumulating (850) the error values of the data samples associated with that TDC output level in an accumulator of that TDC output level; increasing (860) the counter value of a TDC output level by one when the error values of the data samples associated with that TDC output level are added to its accumulator; when the slopes of the output data samples have been analyzed and the accumulators and counters have been updated, averaging (870) the error values of each TDC output level by dividing the accumulated error values in its accumulator by its counter value; generating (880) a calibration lookup table comprising an error vector of the averaged error values of the TDC output levels.
5. A calibration unit (710) for calibrating a time-to-digital converter, TDC, wherein The TDC is configured to receive a signal having a reference frequency F REF and a signal from a digitally controlled oscillator DCO having a frequency F DCO , wherein the frequency F DCO is set to be close to an integer multiple of the reference frequency F REF , such that a ramp of output data samples is generated from the TDC, the calibration unit (710) is configured to: receiving output data samples from the TDC within a predefined time period; detecting boundaries between slopes by observing whether an output data sample has a large and sudden transition compared to the previous output data sample; for each slope of the TDC output data samples, generating a reference line for the slope using a digital fitting method, calculating an error value for each of the output data samples associated with a TDC output level by calculating the deviation of each output data sample in a slope from the corresponding reference level of the reference line of that slope; accumulating the error values of the data samples associated with that TDC output level in an accumulator of that TDC output level; increasing the counter value of a TDC output level by one when the error values of the data samples associated with that TDC output level are added to its accumulator; when the slopes of the output data samples have been analyzed and the accumulators and counters have been updated, averaging the error values of each TDC output level by dividing the accumulated error values in its accumulator by its counter value; generating a calibration lookup table comprising an error vector of the averaged error values of the TDC output levels.
6. An electronic device (1000) comprising a calibration unit (110, 710) according to any one of claims 3 or 5.
7. The electronic device (1000) according to claim 6, wherein The electronic device (1000) is any one of a base station and a wireless communication device for a cellular communication system. The electronic device (1000) is any one of a base station and a wireless communication device for a cellular communication system.
Citation Information
Patent Citations
Delay line calibration
US8736384B2
Methods and systems to compensate for non-linearity of a stochastic system
US20150074156A1
System and a method for determining a correction for an output value of a time-to-digital converter within a phase-locked loop
US20180131380A1