summaryrefslogtreecommitdiffstats
path: root/contrib/ntp/include
diff options
context:
space:
mode:
authorroberto <roberto@FreeBSD.org>2000-01-28 14:55:50 +0000
committerroberto <roberto@FreeBSD.org>2000-01-28 14:55:50 +0000
commitb5b40f9e420899251189775800d9f74092925299 (patch)
tree98efdf1b74d6ecb7828bb502a0350116eeb2fd3c /contrib/ntp/include
parentef64b99e8412f2273dd2e8b3291c2f78ffc4667f (diff)
downloadFreeBSD-src-b5b40f9e420899251189775800d9f74092925299.zip
FreeBSD-src-b5b40f9e420899251189775800d9f74092925299.tar.gz
Virgin import of ntpd 4.0.99b
Diffstat (limited to 'contrib/ntp/include')
-rw-r--r--contrib/ntp/include/Makefile.am2
-rw-r--r--contrib/ntp/include/Makefile.in41
-rw-r--r--contrib/ntp/include/audio.h13
-rwxr-xr-xcontrib/ntp/include/icom.h87
-rw-r--r--contrib/ntp/include/l_stdlib.h4
-rw-r--r--contrib/ntp/include/ntp.h11
-rw-r--r--contrib/ntp/include/ntp_refclock.h4
7 files changed, 141 insertions, 21 deletions
diff --git a/contrib/ntp/include/Makefile.am b/contrib/ntp/include/Makefile.am
index 1f80c16..d7f28f6 100644
--- a/contrib/ntp/include/Makefile.am
+++ b/contrib/ntp/include/Makefile.am
@@ -6,9 +6,11 @@ ETAGS_ARGS = $(srcdir)/Makefile.am
noinst_HEADERS = \
adjtime.h \
ascii.h \
+ audio.h \
binio.h \
global.h \
gps.h \
+ icom.h \
ieee754io.h \
iosignal.h \
l_stdlib.h \
diff --git a/contrib/ntp/include/Makefile.in b/contrib/ntp/include/Makefile.in
index 0453bf4..c1557c0 100644
--- a/contrib/ntp/include/Makefile.in
+++ b/contrib/ntp/include/Makefile.in
@@ -63,15 +63,18 @@ host_alias = @host_alias@
host_triplet = @host@
target_alias = @target_alias@
target_triplet = @target@
+AMDEP = @AMDEP@
AMTAR = @AMTAR@
-AMTARFLAGS = @AMTARFLAGS@
AWK = @AWK@
CC = @CC@
CFLAGS = @CFLAGS@
CHUTEST = @CHUTEST@
CLKTEST = @CLKTEST@
CPP = @CPP@
+CXX = @CXX@
+CXXCPP = @CXXCPP@
DCFD = @DCFD@
+DEPDIR = @DEPDIR@
LDFLAGS = @LDFLAGS@
LIBPARSE = @LIBPARSE@
LIBRSAREF = @LIBRSAREF@
@@ -93,6 +96,7 @@ RSAREF = @RSAREF@
TESTDCF = @TESTDCF@
U = @U@
VERSION = @VERSION@
+install_sh = @install_sh@
#AUTOMAKE_OPTIONS = ../util/ansi2knr no-dependencies
@@ -104,9 +108,11 @@ ETAGS_ARGS = $(srcdir)/Makefile.am
noinst_HEADERS = \
adjtime.h \
ascii.h \
+ audio.h \
binio.h \
global.h \
gps.h \
+ icom.h \
ieee754io.h \
iosignal.h \
l_stdlib.h \
@@ -156,32 +162,36 @@ GZIP_ENV = --best
all: all-redirect
.SUFFIXES:
$(srcdir)/Makefile.in: Makefile.am $(top_srcdir)/configure.in $(ACLOCAL_M4)
- cd $(top_srcdir) && $(AUTOMAKE) --gnu --include-deps include/Makefile
+ cd $(top_srcdir) && $(AUTOMAKE) --gnu include/Makefile
-Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status
+Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status $(BUILT_SOURCES)
cd $(top_builddir) \
&& CONFIG_FILES=$(subdir)/$@ CONFIG_HEADERS= $(SHELL) ./config.status
tags: TAGS
-ID: $(HEADERS) $(SOURCES) $(LISP)
- list='$(SOURCES) $(HEADERS)'; \
- unique=`for i in $$list; do echo $$i; done | \
- ${AWK:-awk} ' { files[$$0] = 1; } \
+ID: $(HEADERS) $(SOURCES) $(LISP) $(TAGS_FILES)
+ list='$(SOURCES) $(HEADERS) $(TAGS_FILES)'; \
+ unique=`for i in $$list; do \
+ if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \
+ done | \
+ $(AWK) ' { files[$$0] = 1; } \
END { for (i in files) print i; }'`; \
- here=`pwd` && cd $(srcdir) \
- && mkid -f$$here/ID $$unique $(LISP)
+ mkid -f$$here/ID $$unique $(LISP)
-TAGS: $(HEADERS) $(SOURCES) $(TAGS_DEPENDENCIES) $(LISP)
+TAGS: $(HEADERS) $(SOURCES) $(TAGS_DEPENDENCIES) \
+ $(TAGS_FILES) $(LISP)
tags=; \
here=`pwd`; \
- list='$(SOURCES) $(HEADERS)'; \
- unique=`for i in $$list; do echo $$i; done | \
- ${AWK:-awk} ' { files[$$0] = 1; } \
+ list='$(SOURCES) $(HEADERS) $(TAGS_FILES)'; \
+ unique=`for i in $$list; do \
+ if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \
+ done | \
+ $(AWK) ' { files[$$0] = 1; } \
END { for (i in files) print i; }'`; \
test -z "$(ETAGS_ARGS)$$unique$(LISP)$$tags" \
- || (cd $(srcdir) && etags $(ETAGS_ARGS) $$tags $$unique $(LISP) -o $$here/TAGS)
+ || etags $(ETAGS_ARGS) $$tags $$unique $(LISP)
mostlyclean-tags:
@@ -198,7 +208,7 @@ distdir: $(DISTFILES)
@for file in $(DISTFILES); do \
d=$(srcdir); \
if test -d $$d/$$file; then \
- cp -pr $$d/$$file $(distdir)/$$file; \
+ cp -pR $$d/$$file $(distdir); \
else \
test -f $(distdir)/$$file \
|| ln $$d/$$file $(distdir)/$$file 2> /dev/null \
@@ -240,6 +250,7 @@ distclean-generic:
-rm -f config.cache config.log stamp-h stamp-h[0-9]*
maintainer-clean-generic:
+ -rm -f Makefile.in
mostlyclean-am: mostlyclean-tags mostlyclean-generic
mostlyclean: mostlyclean-am
diff --git a/contrib/ntp/include/audio.h b/contrib/ntp/include/audio.h
new file mode 100644
index 0000000..284411c
--- /dev/null
+++ b/contrib/ntp/include/audio.h
@@ -0,0 +1,13 @@
+/*
+ * Header file for audio drivers
+ */
+#include "ntp_types.h"
+
+#define AUDIO_BUFSIZ 160 /* codec buffer size (Solaris only) */
+
+/*
+ * Function prototypes
+ */
+int audio_init P((void));
+int audio_gain P((int, int));
+void audio_show P((void));
diff --git a/contrib/ntp/include/icom.h b/contrib/ntp/include/icom.h
new file mode 100755
index 0000000..aac62c8
--- /dev/null
+++ b/contrib/ntp/include/icom.h
@@ -0,0 +1,87 @@
+/*
+ * Header file for ICOM radios
+ */
+#include "ntp_types.h"
+
+/*
+ * Common definitions
+ */
+#define P_ERMSG 0x1 /* trace bus error messages */
+#define P_TRACE 0x2 /* trace CI-V messges */
+#define RETRY 3 /* max packet retries */
+#define IBAUD B1200 /* autotune port speed */
+
+/*
+ * Radio identifier codes
+ */
+#define IC1271 0x24
+#define IC1275 0x18
+#define IC271 0x20
+#define IC275 0x10
+#define IC375 0x12
+#define IC471 0x22
+#define IC475 0x14
+#define IC575 0x16
+#define IC725 0x28
+#define IC726 0x30
+#define IC735 0x04
+#define IC751 0x1c
+#define IC761 0x1e
+#define IC765 0x2c
+#define IC775 0x46
+#define IC781 0x26
+#define IC970 0x2e
+#define R7000 0x08
+#define R71 0x1a
+#define R7100 0x34
+#define R72 0x32
+#define R8500 0x4a
+#define R9000 0x2a
+
+/*
+ * CI-V frame codes
+ */
+#define PR 0xfe /* preamble */
+#define TX 0xe0 /* controller address */
+#define FI 0xfd /* end of message */
+#define ACK 0xfb /* controller normal reply */
+#define NAK 0xfa /* controller error reply */
+#define PAD 0xff /* transmit padding */
+
+/*
+ * CI-V controller commands
+ */
+#define V_FREQT 0x00 /* freq set (transceive) */
+#define V_MODET 0x01 /* set mode (transceive) */
+#define V_RBAND 0x02 /* read band edge */
+#define V_RFREQ 0x03 /* read frequency */
+#define V_RMODE 0x04 /* read mode */
+#define V_SFREQ 0x05 /* set frequency */
+#define V_SMODE 0x06 /* set mode */
+#define V_SVFO 0x07 /* select vfo */
+#define V_SMEM 0x08 /* select channel/bank */
+#define V_WRITE 0x09 /* write channel */
+#define V_VFOM 0x0a /* memory -> vfo */
+#define V_CLEAR 0x0b /* clear channel */
+#define V_ROFFS 0x0c /* read tx offset */
+#define V_SOFFS 0x0d /* write tx offset */
+#define V_SCAN 0x0e /* scan control */
+#define V_SPLIT 0x0f /* split control */
+#define V_DIAL 0x10 /* set dial tuning step */
+#define V_ATTEN 0x11 /* set attenuator */
+#define V_SANT 0x12 /* select antenna */
+#define V_ANNC 0x13 /* announce control */
+#define V_WRCTL 0x14 /* write controls */
+#define V_RDCTL 0x15 /* read controls */
+#define V_TOGL 0x16 /* set switches */
+#define V_ASCII 0x17 /* send CW message */
+#define V_POWER 0x18 /* power control */
+#define V_RDID 0x19 /* read model ID */
+#define V_SETW 0x1a /* read/write channel/bank data */
+#define V_CTRL 0x7f /* miscellaneous control */
+
+/*
+ * Function prototypes
+ */
+int icom_init P((char *, int, int));
+int icom_freq P((int, int, double));
diff --git a/contrib/ntp/include/l_stdlib.h b/contrib/ntp/include/l_stdlib.h
index fdabe67..949cf8f 100644
--- a/contrib/ntp/include/l_stdlib.h
+++ b/contrib/ntp/include/l_stdlib.h
@@ -169,6 +169,10 @@ extern int vsprintf P((char *, const char *, ...));
extern int stime P((const time_t *));
#endif
+#ifdef DECL_STIME_1
+extern int stime P((long *));
+#endif
+
#ifdef DECL_STRERROR_0
extern char * strerror P((int errnum));
#endif
diff --git a/contrib/ntp/include/ntp.h b/contrib/ntp/include/ntp.h
index 790e0a5..f4d01de 100644
--- a/contrib/ntp/include/ntp.h
+++ b/contrib/ntp/include/ntp.h
@@ -343,10 +343,10 @@ struct peer {
#define REFCLK_LOCALCLOCK 1 /* external (e.g., lockclock) */
#define REFCLK_GPS_TRAK 2 /* TRAK 8810 GPS Receiver */
#define REFCLK_WWV_PST 3 /* PST/Traconex 1020 WWV/H */
-#define REFCLK_WWVB_SPECTRACOM 4 /* Spectracom 8170/Netclock WWVB */
+#define REFCLK_SPECTRACOM 4 /* Spectracom (generic) Receivers */
#define REFCLK_TRUETIME 5 /* TrueTime (generic) Receivers */
-#define REFCLK_IRIG_AUDIO 6 /* IRIG-B audio decoder */
-#define REFCLK_CHU 7 /* scratchbuilt CHU (Canada) */
+#define REFCLK_IRIG_AUDIO 6 /* IRIG-B/W audio decoder */
+#define REFCLK_CHU_AUDIO 7 /* CHU audio demodulator/decoder */
#define REFCLK_PARSE 8 /* generic driver (usually DCF77,GPS,MSF) */
#define REFCLK_GPS_MX4200 9 /* Magnavox MX4200 GPS */
#define REFCLK_GPS_AS2201 10 /* Austron 2201A GPS */
@@ -373,7 +373,10 @@ struct peer {
#define REFCLK_CHRONOLOG 32 /* Chrono-log K WWVB receiver */
#define REFCLK_DUMBCLOCK 33 /* Dumb localtime clock */
#define REFCLK_ULINK 34 /* Ultralink M320 WWVB receiver */
-#define REFCLK_MAX 34 /* Grow as needed... */
+#define REFCLK_PCF 35 /* Conrad parallel port radio clock */
+#define REFCLK_WWV_AUDIO 36 /* WWV/H audio demodulator/decoder */
+#define REFCLK_FG 37 /* Forum Graphic GPS */
+#define REFCLK_MAX 37 /* Grow as needed... */
/*
* We tell reference clocks from real peers by giving the reference
diff --git a/contrib/ntp/include/ntp_refclock.h b/contrib/ntp/include/ntp_refclock.h
index ad278a3..fd1d080 100644
--- a/contrib/ntp/include/ntp_refclock.h
+++ b/contrib/ntp/include/ntp_refclock.h
@@ -165,8 +165,8 @@ struct refclockbug {
#define LDISC_CLK 0x1 /* tty_clk \n intercept */
#define LDISC_CLKPPS 0x2 /* tty_clk \377 intercept */
#define LDISC_ACTS 0x4 /* tty_clk #* intercept */
-#define LDISC_CHU 0x8 /* tty_chu */
-#define LDISC_PPS 0x10 /* ppsclock */
+#define LDISC_CHU 0x8 /* depredated */
+#define LDISC_PPS 0x10 /* ppsclock, ppsapi */
#define LDISC_RAW 0x20 /* raw binary */
struct refclockproc {
OpenPOWER on IntegriCloud