summaryrefslogtreecommitdiffstats
path: root/usr.sbin/xntpd/parse
diff options
context:
space:
mode:
authorjkh <jkh@FreeBSD.org>1995-07-21 13:04:07 +0000
committerjkh <jkh@FreeBSD.org>1995-07-21 13:04:07 +0000
commit7e7ec9acb6a342e9a2e4063d83c6c0e064e75c35 (patch)
treed8c4f11d7bb265fc2aae6f7f14c5bb9684be2cae /usr.sbin/xntpd/parse
parent237c7bb61ec0d318b3c7e3b0327aa3cb46e7f411 (diff)
downloadFreeBSD-src-7e7ec9acb6a342e9a2e4063d83c6c0e064e75c35.zip
FreeBSD-src-7e7ec9acb6a342e9a2e4063d83c6c0e064e75c35.tar.gz
Support for the Boeder DCF77 Receiver
Submitted by: Vincenzo Capuano <VCAPUANO@VMPROFS.ESOC.ESA.DE>
Diffstat (limited to 'usr.sbin/xntpd/parse')
-rw-r--r--usr.sbin/xntpd/parse/README.parse_clocks7
-rw-r--r--usr.sbin/xntpd/parse/util/dcfd.c12
2 files changed, 14 insertions, 5 deletions
diff --git a/usr.sbin/xntpd/parse/README.parse_clocks b/usr.sbin/xntpd/parse/README.parse_clocks
index cf8d77e..a3c5a80 100644
--- a/usr.sbin/xntpd/parse/README.parse_clocks
+++ b/usr.sbin/xntpd/parse/README.parse_clocks
@@ -119,9 +119,10 @@ in the parse/clk_*.c and xntpd/refclock_parse.c files).
For the Meinberg parse look into clock_meinberg.c
---
- RAWDCF: 127.127.8.20-23 (Conrad receiver module - delay 210ms)
- 127.127.8.24-27 (FAU receiver - delay 258ms)
- RAWDCF: end=TIMEOUT>1.5s, sync each char (any char),generate psuedo time
+ RAWDCF: 127.127.8.20-23 (Conrad receiver module - delay 258ms)
+ 127.127.8.24-27 (FAU receiver - delay 210ms)
+ 127.127.8.40-43 (Boeder receiver - delay 258ms)
+ RAWDCF: end=TIMEOUT>1.5s, sync each char (any char), generate psuedo time
codes, fixed format
direct DCF77 code input
diff --git a/usr.sbin/xntpd/parse/util/dcfd.c b/usr.sbin/xntpd/parse/util/dcfd.c
index e8103d4..0a1f7fe 100644
--- a/usr.sbin/xntpd/parse/util/dcfd.c
+++ b/usr.sbin/xntpd/parse/util/dcfd.c
@@ -1544,8 +1544,16 @@ main(argc, argv)
* last error is valid
*/
#if defined(BOEDER)
- time_offset.tv_sec = utc_time - tt.tv_sec;
- time_offset.tv_usec = 0;
+ if (abs(utc_time - tt.tv_sec) > 10)
+ {
+ time_offset.tv_sec = utc_time - tt.tv_sec;
+ time_offset.tv_usec = 0;
+ }
+ else
+ {
+ time_offset.tv_sec = lasterror / 1000000;
+ time_offset.tv_usec = lasterror % 1000000;
+ }
#else
time_offset.tv_sec = lasterror / 1000000;
time_offset.tv_usec = lasterror % 1000000;
OpenPOWER on IntegriCloud