summaryrefslogtreecommitdiff
path: root/ppsthread.h
diff options
context:
space:
mode:
authorEric S. Raymond <esr@thyrsus.com>2015-03-11 08:32:15 -0400
committerEric S. Raymond <esr@thyrsus.com>2015-03-11 08:32:15 -0400
commit215a4054880af2993f81c1e26245084e2075a6da (patch)
treee89c1852140e11d113954f3d365a3ad640631c67 /ppsthread.h
parentd58f5ce5a04e7a680d67796f80d22f73d4943e40 (diff)
downloadgpsd-215a4054880af2993f81c1e26245084e2075a6da.tar.gz
Simplify the thread-monitor interface.
PPS observed live on GR601W.
Diffstat (limited to 'ppsthread.h')
-rw-r--r--ppsthread.h11
1 files changed, 5 insertions, 6 deletions
diff --git a/ppsthread.h b/ppsthread.h
index c048afaf..167a183c 100644
--- a/ppsthread.h
+++ b/ppsthread.h
@@ -37,8 +37,7 @@ struct timedelta_t {
#define timespec_diff_ns(x, y) (long)(((x).tv_sec-(y).tv_sec)*1000000000+(x).tv_nsec-(y).tv_nsec)
struct pps_thread_t {
- struct timespec fixin_real; /* in-band time of the fix */
- struct timespec fixin_clock; /* system clock time when fix received */
+ struct timedelta_t fixin; /* real & clock time when in-band fix received */
#if defined(HAVE_SYS_TIMEPPS_H)
pps_handle_t kernelpps_handle;
#endif /* defined(HAVE_SYS_TIMEPPS_H) */
@@ -62,9 +61,9 @@ struct pps_thread_t {
extern void pps_thread_activate(volatile struct pps_thread_t *);
extern void pps_thread_deactivate(volatile struct pps_thread_t *);
-extern void pps_thread_stash_fixtime(volatile struct pps_thread_t *,
- struct timespec, struct timespec);
-extern int pps_thread_lastpps(volatile struct pps_thread_t *,
- struct timedelta_t *);
+extern void pps_thread_fixin(volatile struct pps_thread_t *,
+ volatile struct timedelta_t *);
+extern int pps_thread_ppsout(volatile struct pps_thread_t *,
+ volatile struct timedelta_t *);
#endif /* PPSTHREAD_H */