[ntp:bk-ntp-dev-send] BitKeeper patch

Harlan Stenn stenn at mail.eecis.udel.edu
Mon Nov 28 17:56:35 PST 2005


This BitKeeper patch contains the following changesets:
stenn at deacon.udel.edu|ChangeSet|20051129015435|20309

# This is a BitKeeper patch.  What follows are the unified diffs for the
# set of deltas contained in the patch.  The rest of the patch, the part
# that BitKeeper cares about, is below these diffs.
# ID:	stenn at whimsy.udel.edu|ChangeSet|19990526004811|57482|8983e65c737bb465
# User:	stenn
# Host:	deacon.udel.edu
# Root:	/deacon/backroom/ntp-dev

#
#--- 1.26/html/drivers/driver36.html	2005-09-15 02:22:53 -04:00
#+++ 1.27/html/drivers/driver36.html	2005-11-28 20:54:02 -05:00
#@@ -27,11 +27,11 @@
# 		<p>As in the original program, the clock discipline is modelled as a Markov process, with probabilistic state transitions corresponding to a conventional clock and the probabilities of received decimal digits. The result is a performance level which results in very high accuracy and reliability, even under conditions when the minute beep of the signal, normally its most prominent feature, can barely be detected by ear with a communications receiver.</p>
# 		<p>The analog audio signal from the shortwave radio is sampled at 8000 Hz and converted to digital representation. The 1000/1200-Hz pulses and 100-Hz subcarrier are first separated using two IIR filters, a 600-Hz bandpass filter centered on 1100 Hz and a 150-Hz lowpass filter. The minute sync pulse is extracted using a 800-ms synchronous matched filter and pulse grooming logic which discriminates between WWV and WWVH signals and noise. The second sync pulse is extracted using a 5-ms FIR matched filter and 8000-stage comb filter.</p>
# 		<p>The phase of the 100-Hz subcarrier relative to the second sync pulse is fixed at the transmitter; however, the audio stage in many radios affects the phase response at 100 Hz in unpredictable ways. The driver adjusts for each radio using two 170-ms synchronous matched filters. The I (in-phase) filter is used to demodulate the subcarrier envelope, while the Q (quadrature-phase) filter is used in a tracking loop to discipline the codec sample clock and thus the demodulator phase.</p>
#-		<p>The data bit probabilities are determined from the subcarrier envelope using a threshold-corrected slicer. The averaged envelope amplitude 30 ms from the beginning of the second establishes the minimum (noise floor) value, while the amplitude 200 ms from the beginning establishes the maximum (signal peak) value. The slice level is midway between these two values. The negative-going envelope transition at the slice level establishes the length of the data pulse, which in turn establish probabilities for binary zero (P0) and binary one (P1). The data values are established by linear interpolation between the pulse lengths for P0 (-1) and P1 (+1). If the driver has not synchronized to the minute pulse, or if the data bit amplitude, signal/noise ratio (SNR) or length are below thresholds, the bit is considered invalid and the data value is ignored.</p>
#-		<p>The difference between the P1 and P0 data values, or likelihood, for each data bit is exponentially averaged in a set of 60 accumulators, one for each second, to determine the semi-static miscellaneous bits, such as DST indicator, leap second warning and DUT1 correction. In this design a data average value larger than a positive threshold is interpreted as +1 (hit) and a value smaller than a negative threshold as a -1 (miss). Values between the two thresholds, which can occur due to signal fades or loss of signal, are interpreted as an erasure and result in no change of indication.</p>
#-		<p>The BCD digit in each digit position of the timecode is represented as four data bits, all of which must be valid for the digit itself to be considered valid. If so, the bits are correlated with the bits corresponding to each of the valid decimal digits in this position. If the digit is invalid, the correlated value for all digits in this position is assumed zero. In either case, the values for all digits are exponentially averaged in a likelihood vector associated with this position. The digit associated with the maximum over all averaged values then becomes the maximum likelihood selection for this position and the ratio of the maximum over the next lower value becomes the likelihood ratio.</p>
#+		<p>The data bit probabilities are determined from the subcarrier amplitude using two 170-ms matched filters, one centered on 200 ms (s<sub>0</sub>) into the second and the other on 500 ms (<i>s</i><sub>1</sub>). The noise floor <i>n</i> is sampled 15 ms into the second. A bipolar data signal is developed as (<i>s</i><sub>1</sub> - <i>n</i>)&nbsp;- (<i>s</i><sub>0</sub> - <i>s</i><sub>1</sub>). The data bit SNR&nbsp;is calculated from the envelope amplitude at the end of the second, which represents the noise, and the envelope amplitude 200 ms from the beginning of the second, which represents the signal. If the driver has not synchronized to the minute pulse, or if the data bit amplitude or SNR are below thresholds, the bit is considered invalid and the bipolar signal is forced to zero.</p>
#+		<p>The bipolar signal is exponentially averaged in a set of 60 accumulators, one for each second, to determine the semi-static miscellaneous bits, such as DST indicator, leap second warning and DUT1 correction. In this design a data average value larger than a positive threshold is interpreted as +1 (hit) and a value smaller than a negative threshold as a -1 (miss). Values between the two thresholds, which can occur due to signal fades or loss of signal, are interpreted as an erasure and result in no change of indication.</p>
#+		<p>The BCD digit in each digit position of the timecode is represented as four data bits. The bits are correlated with the bits corresponding to each of the valid decimal digits in this position. If the digit is invalid, the correlated value for all digits in this position is assumed zero. In either case, the values for all digits are exponentially averaged in a likelihood vector associated with this position. The digit associated with the maximum over all averaged values then becomes the maximum likelihood selection for this position and the ratio of the maximum over the next lower value represents the digit SNR.</p>
# 		<p>The decoding matrix contains nine row vectors, one for each digit position. Each row vector includes the maximum likelihood digit, likelihood vector and other related data. The maximum likelihood digit for each of the nine digit positions becomes the maximum likelihood time of the century. A built-in transition function implements a conventional clock with decimal digits that count the minutes, hours, days and years, as corrected for leap seconds and leap years. The counting operation also rotates the likelihood vector corresponding to each digit as it advances. Thus, once the clock is set, each clock digit should correspond to the maximum likelihood digit as transmitted.</p>
#-		<p>Each row of the decoding matrix also includes a compare counter and the difference (modulo the radix) between the current clock digit and most recently determined maximum likelihood digit. If a digit likelihood exceeds the decision level and the difference is constant for a number of successive minutes in any row, the maximum likelihood digit replaces the clock digit in that row. When this condition is true for all rows and the second epoch has been reliably determined, the clock is set (or verified if it has already been set) and delivers correct time to the integral second. The fraction within the second is derived from the logical master clock, which runs at 8000 Hz and drives all system timing functions.</p>
#+		<p>Each row of the decoding matrix also includes a compare counter and the most recently determined maximum likelihood digit. If a digit likelihood exceeds the decision level and compares with previous digits for a number of successive minutes in any row, the maximum likelihood digit replaces the clock digit in that row. When this condition is true for all rows and the second epoch has been reliably determined, the clock is set (or verified if it has already been set) and delivers correct time to the integral second. The fraction within the second is derived from the logical master clock, which runs at 8000 Hz and drives all system timing functions.</p>
# 		<p>The logical master clock is derived from the audio codec clock. Its frequency is disciplined by a frequency-lock loop (FLL) which operates independently of the data recovery functions. At averaging intervals determined by the measured jitter, the frequency error is calculated as the difference between the most recent and the current second epoch divided by the interval. The sample clock frequency is then corrected by this amount. When first started, the frequency averaging interval is eight seconds, in order to compensate for intrinsic codec clock frequency offsets up to 125 PPM. Under most conditions, the averaging interval doubles in stages from the initial value to over 1000 seconds, which results in an ultimate frequency precision of 0.125 PPM, or about 11 ms/day.</p>
# 		<p>It is important that the logical clock frequency is stable and accurately determined, since in most applications the shortwave radio will be tuned to a fixed frequency where WWV or WWVH signals are not available throughout the day. In addition, in some parts of the US, especially on the west coast, signals from either or both WWV and WWVH may be available at different times or even at the same time. Since the propagation times from either station are almost always different, each station must be reliably identified before attempting to set the clock.</p>
# 		<p>Station identification uses the 800-ms minute pulse transmitted by each station. In the acquisition phase the entire minute is searched using both the WWV and WWVH matched filters and a pulse gate discriminator similar to that found in radar acquisition and tracking receivers. The peak amplitude found determines a range gate and window where the next pulse is expected to be found. The minute is scanned again to verify the peak is indeed in the window and with acceptable amplitude, SNR and jitter. At this point the receiver begins to track the second sync pulse and operate as above until the clock is set. Once the minute is synchronized, the range gate is fixed and only energy within the window is considered for the minute sync pulse.</p>
#@@ -42,13 +42,13 @@
# 		<p>The measured propagation delay from the WWV transmitter at Boulder, CO, to the receiver at Newark, DE, is 23.5&plusmn;0.1 ms. This is measured to the peak of the pulse after the second sync comb filter and includes components due to the ionospheric propagation delay, nominally 8.9 ms, communications receiver delay and program delay. The propagation delay can be expected to change about 0.2 ms over the day, as the result of changing ionosphere height. The DSP93 program delay was measured at 5.5 ms, most of which is due to the 400-Hz bandpass filter and 5-ms matched filter. Similar delays can be expected of this driver.</p>
# 		<h4>Program Operation</h4>
# 		The driver begins operation immediately upon startup. It first searches for one or both of the stations WWV and WWVH and attempts to acquire minute sync. This may take some fits and starts, as the driver expects to see three consecutive minutes with good signals and low jitter. If the autotune function is active, the driver will rotate over all five frequencies and both WWV and WWVH stations until three good minutes are found.
#-		<p>When a minute sync candidate has been found, the driver acquires second sync, which can take up to several minutes, depending on signal quality. At the same time the driver accumulates likelihood values for each of the nine digits of the clock, plus the seven miscellaneous bits included in the WWV/H transmission format. When five repetitions of all nine digits have decoded correctly, which normally takes 15 minutes with good signals and up to an hour when buried in noise, and the second sync has been acquired, the clock is set (or verified) and is selectable to discipline the system clock.</p>
#-		<p>As long as the clock is set or verified, the system clock offsets are provided once each second to the reference clock interface, where they are saved in a buffer. At the end of each minute the buffer samples are groomed by the median-filter and trimmed-mean functions. Using these functions, the system clock can in principle be disciplined to a much finer resolution than the 125-<font face="Symbol">m</font>s sample interval would suggest, although the ultimate accuracy is probably limited by propagation delay variations as the ionspheric height varies throughout the day and night.</p>
#+		<p>When a minute sync candidate has been found, the driver acquires second sync, which can take up to several minutes, depending on signal quality. At the same time the driver accumulates likelihood values for each of the nine digits of the clock, plus the seven miscellaneous bits included in the WWV/H transmission format. When three repetitions of all nine digits have decoded correctly, which normally takes 15 minutes with good signals and up to an hour when buried in noise, and the second sync has been acquired, the clock is set (or verified) and is selectable to discipline the system clock.</p>
#+		<p>As long as the clock is set or verified, the system clock offsets are provided once each minute to the reference clock interface, where they are processed using the same algorithms used with other local reference clocks and remote servers. Using these algorithms, the system clock can in principle be disciplined to a much finer resolution than the 125-<font face="Symbol">m</font>s sample interval would suggest, although the ultimate accuracy is probably limited by propagation delay variations as the ionspheric height varies throughout the day and night.</p>
# 		<p>The codec clock frequency is disciplined during times when WWV/H signals are available. The algorithm refines the frequency offset using increasingly longer averaging intervals to 1024 s, where the precision is about 0.1 PPM. With good signals, it takes well over two hours to reach this degree of precision; however, it can take many more hours than this in case of marginal signals. Once reaching the limit, the algorithm will follow frequency variations due to temperature fluctuations and ionospheric height variations.</p>
# 		<p>It may happen as the hours progress around the clock that WWV and WWVH signals may appear alone, together or not at all. When the driver is first started, the NTP reference identifier appears as <tt>NONE</tt>. When the driver has mitigated which station and frequency is best, it sets the reference identifier to the string WV<i>f</i> for WWV and WH<i>f</i> for WWVH, where <i>f</i> is the frequency in megahertz. If the propagation delays have been properly set with the <tt>fudge time1</tt> (WWV) and <tt>fudge time2</tt> (WWVH) commands in the configuration file, handover from one station to the other is seamless.</p>
# 		<p>Once the clock has been set for the first time, it will appear reachable and selectable to discipline the system clock. Operation continues as long as the signal quality from at least one station on at least one frequency is acceptable and for a holdover interval of about 30 minutes after signal loss for both stations on all frequencies. A consequence of this design is that, once the clock is set, the time and frequency are disciplined only by the second sync pulse and the clock digits themselves are driven by the clock state machine. If for some reason the state machine drifts to the wrong second, it would never reresynchronize. To protect against this most unlikely situation, if after two days with no signals, the clock is considered unset and resumes the synchronization procedure from the beginning.</p>
# 		<p>However, as long as the clock has once been set correctly and allowed to converge to the intrinsic codec clock frequency, it will continue to read correctly even during the holdover interval, but will appear unreachable for synchronization purposes after the holdover intervall. The local clock driver can be used to extend the holdover interval if required.</p>
#-		<p>Assuming the clock frequency can be disciplined within 1 PPM, it can coast without signals for several days without exceeding the NTP step threshold of 128 ms. During such periods the root dispersion increases at 5 <font face="Symbol">m</font>s per second, which makes the driver appears less likely for selection as time goes on. Eventually, when the dispersion due all causes exceeds 1 s, it is no longer suitable for synchronization.</p>
#+		<p>Assuming the clock frequency can be disciplined within 1 PPM, it can coast without signals for several days without exceeding the NTP step threshold of 128 ms. During such periods the root dispersion increases at 5 <font face="Symbol">m</font>s per second, which makes the driver appear less likely for selection as time goes on. Eventually, when the dispersion due all causes exceeds 1 s, it is no longer suitable for synchronization.</p>
# 		<p>To work well, the driver needs a shortwave receiver with good audio response at 100 Hz. Most shortwave and communications receivers roll off the audio response below 250 Hz, so this can be a problem, especially with receivers using DSP technology, since DSP filters can have very fast rolloff outside the passband. Some DSP transceivers, in particular the ICOM 775, have a programmable low frequency cutoff which can be set as low as 80 Hz. However, this particular radio has a strong low frequency buzz at about 10 Hz which appears in the audio output and can affect data recovery under marginal conditions. Although not tested, it would seem very likely that a cheap shortwave receiver could function just as well as an expensive communications receiver.</p>
# 		<h4>Autotune</h4>
# 		<p>The driver includes provisions to automatically tune the radio in response to changing radio propagation conditions throughout the day and night. The radio interface is compatible with the ICOM CI-V standard, which is a bidirectional serial bus operating at TTL levels. The bus can be connected to a serial port using a level converter such as the CT-17.</p>
#@@ -58,12 +58,10 @@
# 		<p>Reception conditions for each frequency and station are evaluated according to the signal metric, which uses the minute sync pulse amplitude and SNR and data subcarrier amplitude and SNR. The minute pulse is evaluated at second 0, while the data pulse is evaluated at second 1. In principle, the data pulse in second 58 is usable, but the AGC in most radios is not fast enough for a reliable measurement.</p>
# 		<p>The results are summarized in a metric which drives the mitigation function. First, determine a score as 1 if:</p>
# 		<ul>
#-			<li>For the minute sync pulse in second 0, the amplitude and SNR are above thresholds (2000 and 20 dB, respectively).
#-			<li>For the data pulse in second 1, the amplitude and SNR are above threshold (1000 and 10 dB, respectively).
#+			<li>For the minute sync pulse in second 0, the amplitude and SNR are above thresholds (3000 and 20 dB, respectively).<li>For the data pulse in second 1, the amplitude and SNR are above threshold (1000 and 10 dB, respectively).
# 		</ul>
# 		<dl>
#-			<dt>and 0 otherwise. The scoreboard is a shift register of 32 bits. Each time a frequency is probed the register is shifted left by one bit with the score replacing the rightmost bit. The metric is computed as the number of 1 bits in the rightmost six bits of the scoreboard. At the end of each probe, the frequency and station with the maximum metric is chosen, with ties going first to the highest frequency and then to WWV in order. During the acquisition phase a station is considered valid only if the metric is above 13; after the clock is synchronized a station is valid only if the metric is above 50. If no stations are valid, the driver ignores all signals and sets the reference ID field to NONE.
#-		</dl>
#+			<dt>and 0 otherwise. The scoreboard is a shift register of 32 bits. Each time a frequency is probed the register is shifted left by one bit with the score replacing the rightmost bit. The metric is computed as the number of 1 bits in the rightmost six bits of the scoreboard. At the end of each probe, the frequency and station with the maximum metric is chosen, with ties going first to the highest frequency and then to WWV in order. A station is considered valid only if the metric is above 13; otherwise, the radio is tuned to WWV&nbsp;on 15 MHz and the reference ID field is set to NONE. The rotating probes continue until a valid station is found.</dl>
# 		<h4>Diagnostics</h4>
# 		<p>The autotune process produces diagnostic information along with the timecode. This is very useful for evaluating the performance of the algorithms, as well as radio propagation conditions in general. The message is produced once each minute for each frequency in turn after minute sync has been acquired.</p>
# 		<p><tt>wwv5 port status agc epoch count wwv wwvh</tt></p>
#@@ -142,14 +140,9 @@
# 					<dt><tt>0x8</tt>
# 					<dd>Sync alarm. The decoder is not synchronized to the station within 125 <font face="Symbol">m</font>s.
# 					<dt><tt>0x4</tt>
#-					<dd>Error alarm. More than 30 data bit errors occurred in the last minute.
#-					<dt><tt>0x2</tt>
#-					<dd>Symbol alarm. The probability of correct decoding for a digit or miscellaneous bit has fallen below the threshold.
#-					<dt><tt>0x1</tt>
#-					<dd>Decoding alarm. A maximum likelihood digit fails to agree with the current associated clock digit.
#-				</dl>
#-				It is important to note that one or more of the above alarms does not necessarily indicate a clock error, but only that the decoder has detected a condition that may eventually result in an error.
#-			<dt><tt>yyyy ddd hh:mm:ss</tt>
#+					<dd>Digit error alarm. Less than nine decimal digits were found in the last minute.<dt><tt>0x2</tt>
#+					<dd>Error alarm. More than 20 data bit errors were found in the last minute.<dt><tt>0x1</tt>
#+					<dd>Compare alarm. A maximum likelihood digit failed to agree with the current associated clock digit in the last minute.</dl>It is important to note that one or more of the above alarms does not necessarily indicate a clock error, but only that the decoder has detected a condition that may result in an error. For this reason the local clock update is suppressed if any alarm bits are set.<dt><tt>yyyy ddd hh:mm:ss</tt>
# 			<dd>The timecode format itself is self explanatory. Since the driver latches the on-time epoch directly from the second sync pulse, the seconds fraction is always zero. Although the transmitted timecode includes only the year of century, the Gregorian year is augmented by 2000.
# 			<dt><tt>l</tt>
# 			<dd>The leap second warning is normally space, but changes to <tt>L</tt> if a leap second is to occur at the end of the month of June or December.
#@@ -162,12 +155,11 @@
# 			<dt><tt>agc</tt>
# 			<dd>The audio gain shows the current codec gain setting in the range 0 to 255. Ordinarily, the receiver audio gain control should be set for a value midway in this range.
# 			<dt><tt>ident</tt>
#-			<dd>The station identifier shows the station, <tt>C</tt> for WWV or <tt>H</tt> for WWVH, and frequency being tracked. If neither station is heard on any frequency, the reference identifier shows <tt>NONE</tt>.
#+			<dd>The station identifier shows the station, <tt>WV<i>f</i></tt> for WWV or <tt>WH<i>f</i></tt> for WWVH, and frequency <i><tt>f</tt></i> being tracked. If neither station is heard on any frequency, the reference identifier shows <tt>NONE</tt>.
# 			<dt><tt>metric</tt>
# 			<dd>The signal metric described above from 0 (no signal) to 100 (best).
# 			<dt><tt>errs</tt>
#-			<dd>The bit error counter is useful to determine the quality of the data signal received in the most recent minute. It is normal to drop a couple of data bits under good signal conditions and increasing numbers as conditions worsen. While the decoder performs moderately well even with half the bits are in error in any minute, usually by that point the metric drops below threshold and the decoder switches to a different frequency.
#-			<dt><tt>freq</tt>
#+			<dd>The bit error counter is useful to determine the quality of the data signal received in the most recent minute. It is normal to drop a couple of data bits under good signal conditions and increasing numbers as conditions worsen. While the decoder performs moderately well even with half the bits are in error in any minute, usually by that point the metric drops below threshold and the decoder switches to a different frequency.<dt><tt>freq</tt>
# 			<dd>The frequency offset is the current estimate of the codec frequency offset to within 0.1 PPM. This may wander a bit over the day due to local temperature fluctuations and propagation conditions.
# 			<dt><tt>avgt</tt>
# 			<dd>The averaging time is the interval between frequency updates in powers of two to a maximum of 1024 s. Attainment of the maximum indicates the driver is operating at the best possible resolution in time and frequency.
#

# Diff checksum=eb6c4c4f


# Patch vers:	1.3
# Patch type:	REGULAR

== ChangeSet ==
stenn at whimsy.udel.edu|ChangeSet|19990526004811|57482|8983e65c737bb465
stenn at deacon.udel.edu|ChangeSet|20051127223802|20362
D 1.1440 05/11/28 20:54:35-05:00 stenn at deacon.udel.edu +1 -0
B stenn at whimsy.udel.edu|ChangeSet|19990526004811|57482|8983e65c737bb465
C
c  WWV doc updates from Dave Mills
K 20309
P ChangeSet
------------------------------------------------

0a0
> stenn at whimsy.udel.edu|html/driver36.htm|19991229221358|23222|2c795ab6 stenn at deacon.udel.edu|html/drivers/driver36.html|20051129015402|58453

== html/drivers/driver36.html ==
stenn at whimsy.udel.edu|html/driver36.htm|19991229221358|23222|2c795ab6
stenn at whimsy.udel.edu|html/drivers/driver36.html|20050915062253|20607
D 1.27 05/11/28 20:54:02-05:00 stenn at deacon.udel.edu +14 -22
B stenn at whimsy.udel.edu|ChangeSet|19990526004811|57482|8983e65c737bb465
C
c  WWV doc updates from Dave Mills
K 58453
O -rw-rw-r--
P html/drivers/driver36.html
------------------------------------------------

D30 3
I32 3
		<p>The data bit probabilities are determined from the subcarrier amplitude using two 170-ms matched filters, one centered on 200 ms (s<sub>0</sub>) into the second and the other on 500 ms (<i>s</i><sub>1</sub>). The noise floor <i>n</i> is sampled 15 ms into the second. A bipolar data signal is developed as (<i>s</i><sub>1</sub> - <i>n</i>)&nbsp;- (<i>s</i><sub>0</sub> - <i>s</i><sub>1</sub>). The data bit SNR&nbsp;is calculated from the envelope amplitude at the end of the second, which represents the noise, and the envelope amplitude 200 ms from the beginning of the second, which represents the signal. If the driver has not synchronized to the minute pulse, or if the data bit amplitude or SNR are below thresholds, the bit is considered invalid and the bipolar signal is forced to zero.</p>
		<p>The bipolar signal is exponentially averaged in a set of 60 accumulators, one for each second, to determine the semi-static miscellaneous bits, such as DST indicator, leap second warning and DUT1 correction. In this design a data average value larger than a positive threshold is interpreted as +1 (hit) and a value smaller than a negative threshold as a -1 (miss). Values between the two thresholds, which can occur due to signal fades or loss of signal, are interpreted as an erasure and result in no change of indication.</p>
		<p>The BCD digit in each digit position of the timecode is represented as four data bits. The bits are correlated with the bits corresponding to each of the valid decimal digits in this position. If the digit is invalid, the correlated value for all digits in this position is assumed zero. In either case, the values for all digits are exponentially averaged in a likelihood vector associated with this position. The digit associated with the maximum over all averaged values then becomes the maximum likelihood selection for this position and the ratio of the maximum over the next lower value represents the digit SNR.</p>
D34 1
I34 1
		<p>Each row of the decoding matrix also includes a compare counter and the most recently determined maximum likelihood digit. If a digit likelihood exceeds the decision level and compares with previous digits for a number of successive minutes in any row, the maximum likelihood digit replaces the clock digit in that row. When this condition is true for all rows and the second epoch has been reliably determined, the clock is set (or verified if it has already been set) and delivers correct time to the integral second. The fraction within the second is derived from the logical master clock, which runs at 8000 Hz and drives all system timing functions.</p>
D45 2
I46 2
		<p>When a minute sync candidate has been found, the driver acquires second sync, which can take up to several minutes, depending on signal quality. At the same time the driver accumulates likelihood values for each of the nine digits of the clock, plus the seven miscellaneous bits included in the WWV/H transmission format. When three repetitions of all nine digits have decoded correctly, which normally takes 15 minutes with good signals and up to an hour when buried in noise, and the second sync has been acquired, the clock is set (or verified) and is selectable to discipline the system clock.</p>
		<p>As long as the clock is set or verified, the system clock offsets are provided once each minute to the reference clock interface, where they are processed using the same algorithms used with other local reference clocks and remote servers. Using these algorithms, the system clock can in principle be disciplined to a much finer resolution than the 125-<font face="Symbol">m</font>s sample interval would suggest, although the ultimate accuracy is probably limited by propagation delay variations as the ionspheric height varies throughout the day and night.</p>
D51 1
I51 1
		<p>Assuming the clock frequency can be disciplined within 1 PPM, it can coast without signals for several days without exceeding the NTP step threshold of 128 ms. During such periods the root dispersion increases at 5 <font face="Symbol">m</font>s per second, which makes the driver appear less likely for selection as time goes on. Eventually, when the dispersion due all causes exceeds 1 s, it is no longer suitable for synchronization.</p>
D61 2
I62 1
			<li>For the minute sync pulse in second 0, the amplitude and SNR are above thresholds (3000 and 20 dB, respectively).<li>For the data pulse in second 1, the amplitude and SNR are above threshold (1000 and 10 dB, respectively).
D65 2
I66 1
			<dt>and 0 otherwise. The scoreboard is a shift register of 32 bits. Each time a frequency is probed the register is shifted left by one bit with the score replacing the rightmost bit. The metric is computed as the number of 1 bits in the rightmost six bits of the scoreboard. At the end of each probe, the frequency and station with the maximum metric is chosen, with ties going first to the highest frequency and then to WWV in order. A station is considered valid only if the metric is above 13; otherwise, the radio is tuned to WWV&nbsp;on 15 MHz and the reference ID field is set to NONE. The rotating probes continue until a valid station is found.</dl>
D145 8
I152 3
					<dd>Digit error alarm. Less than nine decimal digits were found in the last minute.<dt><tt>0x2</tt>
					<dd>Error alarm. More than 20 data bit errors were found in the last minute.<dt><tt>0x1</tt>
					<dd>Compare alarm. A maximum likelihood digit failed to agree with the current associated clock digit in the last minute.</dl>It is important to note that one or more of the above alarms does not necessarily indicate a clock error, but only that the decoder has detected a condition that may result in an error. For this reason the local clock update is suppressed if any alarm bits are set.<dt><tt>yyyy ddd hh:mm:ss</tt>
D165 1
I165 1
			<dd>The station identifier shows the station, <tt>WV<i>f</i></tt> for WWV or <tt>WH<i>f</i></tt> for WWVH, and frequency <i><tt>f</tt></i> being tracked. If neither station is heard on any frequency, the reference identifier shows <tt>NONE</tt>.
D169 2
I170 1
			<dd>The bit error counter is useful to determine the quality of the data signal received in the most recent minute. It is normal to drop a couple of data bits under good signal conditions and increasing numbers as conditions worsen. While the decoder performs moderately well even with half the bits are in error in any minute, usually by that point the metric drops below threshold and the decoder switches to a different frequency.<dt><tt>freq</tt>

# Patch checksum=cda735c5


More information about the bk-ntp-dev-send mailing list