Automatic Control and Computer Sciences Vol.35, No.5, pp.11-18, 2001 Avtomatika i Vychislitel’naya Tekhnika Vol.35, No.5, pp.15-24, 2001 A METHOD FOR CONTINUOUS SUPERPRECISE TIME-INTERVAL MEASUREMENT Yu. N. ARTYUKH, Dr.Hab.Comp.Sc (Technical Sciences) Institute of Electronics and Computer Science Latvian University, 14 Dzerbenes Street, LV-1006 Riga (Latvia) E-mail: artyukh@edi.lv A method is considered for the continuous wide-range measurement of time intervals with elevated accuracy (error 10-20 psec) at data rates up to tens of megahertz. Its specific features can be used in estimating the implementation error. General principles are given together with an engineering realization to illustrate the performance. 1. INTRODUCTION Continuous measurement of a series of intervals differs from measuring a single time interval between two start/stop pulses in that each input pulse is simultaneously the end of the current interval and the start of the next one. Those intervals should be measured not only accurately but also rapidly, since the time to measure an interval should not exceed its length. However, raising the data rate usually results in a loss of accuracy. For example, in measuring single intervals, where the time for each measurement is almost unrestricted, the error of measurement may be some tens of picoseconds. At the same time, the best modern time-interval meters operate with maximum frequencies from one to ten megahertz or so and have errors of about 100 picoseconds, which is worse by a factor 35. In [1, 2], I have briefly considered a new method of continuous interval measurement, which has been called enhanced event timing EET. Recent researches and tests have shown that devices based on it can provide an error of about 10-20 psec at maximum data rates up to tens of megahertz. This makes them the same or better as regards accuracy not only as means of continuous interval measurement but also in comparison with any other wide-range measurements. As interval measurement has many applications, I here give a more detailed exposition of the basic properties and principles of the EET method. 2. ESSENCE OF THE EET METHOD Time intervals are not necessarily measured directly. Often, it is more convenient to measure the instants of arrival {t0 , t1, t2 ,…tN} of the input pulses (timing events corresponding for example to the leading edges of the input pulses). Then if necessary one can calculate the time intervals as the differences between the results for adjacent events. Wide-range and at the same time very precise event timing is usually implemented by a combined method based on discrete (rough) and interpolating (refining) time interval measurements (Fig. 1). The rough measurements are performed by continuous cyclic counting of the individual time increments TR defined by clock pulses of constant frequency and read at the time of the event in the current state of the increment counter. This allows one to time the events with a discreteness TR over a wide range. The interpolating measurements refine the time positions of the events within TR , the rough-measurement interval, and they are usually based on special methods such as the vernier one, stretching the intervals, and so on. In the context of combined event timing, the EET method largely eliminates the problem of raising the accuracy in the interpolating measurements. © 2001 by Allerton Press, Inc. Authorization to photocopy individual items for internal or personal use, or the internal or personal use of specific clients, is granted by Allerton Press, Inc. for libraries and other users registered with the Copyright Clearance Center (CCC) Transactional Reporting Service, provided that the base fee $50.00 per copy is paid directly to CCC, 222 Rosewood Drive, Danvers, MA 01923. 11 Automatic Control and Computer Sciences Vol.35, No.5 Event j Nj t j = Nj T R + τ j τj t Clock pulses TR Fig. 1. Combined timing principle. In the EET method, each event j occurring at time t *j gives rise to a nonlinear analog signal u(t- t *j ), which has a finite duration and is subsequently called the secondary signal. The secondary-signal sequence is digitized with period TR of the clock pulses to give digital readings {si}, which are processed to estimate the position of each signal on the time axis relative to the clock pulses and the time t *j of the corresponding event. We consider using each event j to generate a secondary signal u(t- t *j ), whose shape is close to an isosceles triangle, while the duration at the middle of its amplitude is about 2TR . For any position of such signals relative to the clock pulses in the sequence, the digitized samples s0 , s1 ,… si, … will always contain samples si = SjR and si+2 = SjF obtained correspondingly on the rising and falling parts of secondary signal j (Fig. 2). These readings are selected from the general sequence on the condition SjR = si if (sj ≥ Q) & (si-1 < Q), in which Q is some digital selection threshold. That Q is chosen such that SjR and SjF are realized on the more linear parts R and F of the secondary signal. The difference Gj= SjF - SjR for the selected readings and the serial number Nj = i of one of them together define the position of secondary signal j and correspondingly the time tj of onset of event j: tj = Nj TR + τ(Gj), (1) in which τ(G) is a certain dependence known a priori of the interpolation component τ for estimating the event time on the parameter G; τ(G) is subsequently called the calibration function, and it is monotone and in general nonlinear. The following method can be used to determine it (calibrate the real device). SjF F R 2T R Secondary signal SjR u(t- t j*) Q tj * τj Clock pulses TR Input pulse Fig. 2. Example of a quasioptimal secondary signal waveform. 12 Automatic Control and Computer Sciences Vol.35, No.5 We assume that the digital readings on the secondary signals are obtained with identical absolute errors, so all possible values of G form a certain set K of integers {Gk}. We assume that for a test sequence composed of L » K events, the true values τ* of the interpolation component are uniformly distributed in the interval TR , and so the digitization of the corresponding secondary signals means that each Gk may be realized repeatedly. In that case, the relative frequency λk = nk /L of realizing any particular Gk will characterize the relative range εk / TR of true values for the interpolation component represented by that number. In other words, the sequence of K quantities TR λ1 , TR λ2 , …TR λk ,…TR λK will represent an estimator for the sequence K of timing samples ε1 , ε2 ,…εk ,…εK in order of increasing Gk . The minimum timing error is attained when each Gk is put into correspondence with an estimator τ(Gk) equal to the mean value of the interpolation component in the corresponding range. Such estimators for all the Gk in increasing order may be represented as follows together with the required calibration function as determined from the λk : k i =1 τ (G k ) = T R ∑ λ i − 0.5λ k . (2) When this calibration method is used, many different signals can be employed for the tests, including quasiperiodic pulse trains with repetition frequencies that are not multiples of the clock pulse frequency. The standard deviation representing the statistical calibration error is approximately TR / L . The calibration function in timing EET events can be interpreted as the logic transformation Gk → τk , which is the inverse to the physically realizable transformation τ k* → Gk . The calibration function τ(Gk) is then a numerical model for the physical transformation, and the timing error is very much dependent on its correspondence with the actual parameters in that transformation. 3. EET INTERVAL MEASUREMENT ERRORS One can estimate the variance due to the systematic errors in timing in the EET method quite accurately from the mean timing sample interval εA = TR / К . In most implementations of the EET method, the secondary signals are to some extent unsymmetrical, so the distribution of the timing samples {εk} is close to uniform in the range from zero to 2εA , and the variance in the systematic timing errors is 2 σ iM ≅ ε A2 /6. (3) 2 from the systematic errors in continuous measurement by the EET method is Correspondingly, the variance σ iM 2 2 σ TM = 2 σ iM ≅ ε A2 /3. (4) In practice, the standard deviation from the systematic errors in continuous measurement may be less than a picosecond, but the actual measurement errors are usually much larger because of the instrumental component, with the errors caused by noise in the analog signal system, timing instability in the clock pulses, and so on. The actual error in continuous measurement by the method is governed by the stability of the clock pulse frequency and by the difference in the errors in estimating the interpolation component. The standard deviation of the over-all errors in measuring intervals of length TM is σ T = 2σ τ2 + (δ S TM ) 2 , (5) in which σ τ2 is the variance of the errors in estimating the interpolation component and δs is the stability of the reference frequency used in the clock pulses. That δs is usually determined by the value of the Allan variation [3] over an interval of 1 sec. 13 Automatic Control and Computer Sciences Vol.35, No.5 The EET method is intended for precision measurements, where one uses thermally stabilized oscillators that produce a highly stable reference frequency (δs < 10-10). Intervals in the range up to hundreds of milliseconds may be measured with effects from the instability in the reference frequency that are negligibly small, and the standard deviation is almost completely determined by the variance in estimating the interpolation component: σ T* ≅ 2σ τ2 . (6) The EET method provides unique scope for the reliable estimation of that error by experiment. We assume that in a time interval TS one times a sequence of test pulses similar to that used in calibration. The resulting set of secondary signal readings is processed twice on the same algorithm but with two different values for the selection threshold QA < QB . Then for the same events, one gets two estimators for the interpolation component. For the part of the events where QA ≤ SjR < QB , the estimators τ(GjA) and τ(GjB) will be derived from different pairs of readings on the same secondary signal, which have independent random errors (Fig. 3). The proportion ξ / TR of such estimators is itself proportional to the difference between QA and QB . To exclude the correlation of the systematic errors in the estimators τ(GjA) and τ(GjB), it is sufficient to obey the condition ξ /εA > 50. The differences between the independent estimators {∆τj = τ(GjA) – τ(GjB)} are equivalent to the results from repeated measurement of intervals of duration TR whose origin has been varied with respect to the clock pulses in the range ξ (Fig. 3). Each difference ∆ τj consists of the error Cj corresponding to a realization of the time-dependent error C(t), together with the differences (∆jA – ∆jB) in the stationary (time-independent) timing errors. The errors {Cj} are due to the calibration function not exactly matching the transformation τ k* → Gk physically realized in the time interval TS on account of thermal instability. We assume that in a certain time interval TS, the effects of the thermal instability are negligibly small, and the value CS of the nonstationary error C(t) is virtually constant and corresponds to the mean value of the differences M[∆τj]. In that particular case, this error is maximal, since the errors τ(GjA) and τ(GjB) of the interpolation component are realized only at opposite edges of the calibration function range. In general, CS is dependent on the differences of the interpolation components between the ends of the measured intervals, and their variance is σ 2 [СS(τ)] = (M[∆τj])2 / 6. GjB QB QA τj GjA Sj1 TR Secondary signal Clock pulses Input pulse ξ Fig. 3. Secondary-signal sampling realization regions, with the generation of two independent time estimates for the same events. 14 (7) Automatic Control and Computer Sciences Vol.35, No.5 The variance of the differences σ 2 [∆τj] corresponds directly to the variance of the stationary errors in measuring the time intervals. As the stationary and nonstationary errors are independent, the sample standard deviation for the overall errors in measuring a time interval TS is σ T* = σ 2 [∆ τj ] + ( M [∆ τj ]) 2 6 . (8) One repeats periodically such estimates of the overall errors to determine σ T* (t ) and the integral error parameters for a particular realization of the EET method (minimal, maximal, or confidence-range values of the standard deviation and so on) for a long measurement time. The resulting error estimators characterize the inherent error of the device with respect to the triggering instants for the secondary signal generator, i.e., they are invariant with respect to the errors caused by any instability in the parameters of the input pulses or noise at the timer input. 4. EET IMPLEMENTATION PRINCIPLES An important place in implementing the EET method is taken by the digital processing. Figure 4 shows measurement systems based on the EET method as usually constructed on the basis of computers supplemented with special measurement devices. The secondary signals are generated and digitized in the EET operations, which govern the potential accuracy and data rate. The systematic error acceptable for most applications can be provided by digitizing the secondary signals by means of standard analog-digital converters operating at 80-100 MHz with 8-10 bit accuracy. To generate the secondary signals with the required base duration of 40-50 nsec, one can use a standard method of controlled capacitor charging and discharging. Simple data compression is applied to the output of the analog-digital converter by selecting a series of samples relating directly to each secondary signal and accompanying each such series with the serial number Nj of one of them. Then the time of each event is written into the buffer memory as a block of primary data with unified format. After the end of the recording, the accumulated data file is output from the buffer memory to the computer and processed by the software in accordance with the algorithm considered in section 2. Generate secondary secondary signal signal Digitize secondary secondary signal signal signal Data compression compre and and buffering buffering Specialized device Digital processing {Tj} Computer Fig. 4. Typical structure for a measurement system based on the EET method. 5. EET IMPLEMENTATION EXAMPLE I have developed the A012 time interval series meter [4] on the basis of this method, which consists of a specialized device (timer) and several special software functions implemented in the computer (Fig. 5). The timer is a single-board unit coupled to the computer through a standard parallel port. The timer transforms the input pulses into secondary signals of duration at the base about 50 nsec. These signals are sampled with a frequency of 80 MHz and accuracy 9 bits by a typical analog-digital converter (AD9071) and are accumulated as a sequence of 7-byte blocks of primary data in the buffer executive store of capacity 32 kbyte. The data compression and management functions are provided by a single dedicated microcircuit. The timer interacts with the software functions in given modes of operation, and in output and processing and so on. The particular order in which the corresponding software functions are called up is determined by the principal applications program, which may vary in accordance with the type of virtual instrument. Then the A012 is not so much an instrument ready for use but rather a hardware and software complex from which one can build several virtual devices not only for general use but also adapted to specific tasks. 15 Automatic Control and Computer Sciences Vol.35, No.5 COMPUTER METER А012 Input . Тimer A011-ET Software function Applied program Output Control Fig. 5. A012 timer structure. The A012-TIA time-interval analyzer is an example of a virtual instrument based on the A012; the software functions in the timer have here been integrated with the applied functions of processing the measured time intervals, displaying the results, managing the processing, and so on. That timer program runs on the computer in the MS Windows operational environment. The analyzer operates interactively and cyclically measures the intervals between input pulses (up to 4680 pulses in each cycle) in the range from 100 nsec to 209 msec, and it displays them graphically in order of measurement, as well as in the form of a histogram and as a frequency spectrum for the variations in the measured intervals. The measurements can be stored for processing by any other software. Figure 6 shows an evaluation as considered in section 3 based on the sample standard deviations σ T* of the real errors in an A012-TIA analyzer. The error estimates were made every 15 seconds for an hour. The TS for each case was 1.68 msec, and there were about 750 independent paired estimators for the interpolation component in each interval. Figure 6 shows that σ T* varies from 16 to 18.5 psec; the mean drifts because of the nonstationary component and is increased by the end of the test period by about 1 psec. Similar estimates of the actual errors are closely reproduced when one uses various test sequences, including ones substantially unstable in frequency. Such analyzers have many uses such as characterizing radar signals and sources of rapidly swept frequencies, transient response in phase-amplitude tuning, and the demodulation of frequency-modulated signals. An application with high precision which makes the AO12-TIA almost irreplaceable is the characterization of highly stable signal frequency sources. Figure 7 shows an AO12-TIA histogram characterizing the variation in the input signal period for a typical crystal oscillator microcircuit. Fig. 6. Example of test results for A012 timer; the solid curve shows the errors averaged over ten current readings. 16 Automatic Control and Computer Sciences Vol.35, No.5 Fig. 7. Histogram for output signal period measurement for a typical crystal oscillator. The histogram shows clearly that there is parasitic modulation of the period with a step of ±70 psec; eliminating that defect can improve the stability by almost a factor 2. The scope for on-line self-monitoring of the current error enables the A012-TIA to characterize signal sources in which the stability of the period is actually higher than the measurement accuracy. Figure 8 shows a histogram characterizing the variation in the output signal period for another and more stable crystal oscillator. The standard deviation in the measurements is 23.4 psec with a current value for the RMS error of 18.7 psec. Correspondingly, the standard deviation in the signal period variation is 14 psec. Then the A012-TIA can be used also as a standard measuring instrument such as for testing the accuracy of other interval timers. Fig. 8. Histogram for output signal period measurement for a highly stable crystal oscillator. 17 Automatic Control and Computer Sciences Vol.35, No.5 5. CONCLUSIONS The accuracy in event timing by traditional methods is restricted in the main by the instrumental errors in performing the operations with analog signals. In particular, such errors are caused by jitter in the clock pulses and interference between them and the input pulses, as well as by noise in the transmission system and in the analog signal processing, and thermal instability in the analog component parameters. The EET method substantially improves the timing accuracy because of the following factors: • radical reduction in the number of operations with the analog signals to give only the generation and digitization of the secondary signals; • the use of several digital samples on a secondary signal on timing a single event; and • exact determination of the calibration function, which is used in the timing and incorporates the actual current characteristics of the physically realized analog signal transformations. Incidentally, the EET method resolves a major problem in estimating the actual accuracy of implementations involving the generation and comparison of different sets of timing data for the same events. In a technical respect, the emphasis is shifted from analog operations to digital ones, which means that the EET method can be realized with commonly available digital signal processing facilities. REFERENCES [1] Yu. Artyukh, A. Rybakov, and V. Vedin, “A new approach to high performance continuous time interval counting”, Proceedings of the XI Polish National Conference ‘Application of Microprocessors in Automatic Control and Measurements’, Warsaw, Poland, October 1998, pp. 139-143. [2] Yu. N. Artyukh, “A signal analyzer for the modulation region with picosecond resolving power”, Avtomatika i Vychislitel’naya Tekhnika, no. 2, pp. 3-12, 1998. [3] J. H. Shoaf, D. Halford, and A. S. Risley, Frequency Stability Specification and Measurement: High Frequency and Microwave Signals, NBS Technical Note 632, US Dept. of Commerce, January 1973. [4] Yu. Artyukh, V. Bespal’ko, and E. Boole, “High resolution modular time interval counter”, 12th International Workshop on Laser Ranging, Matera, Italy, 13-17 November 2000, pp. 120-125. Received 10 July 2001 (originally submitted 11 March 2001) 18