From 215a4054880af2993f81c1e26245084e2075a6da Mon Sep 17 00:00:00 2001 From: "Eric S. Raymond" Date: Wed, 11 Mar 2015 08:32:15 -0400 Subject: Simplify the thread-monitor interface. PPS observed live on GR601W. --- ppsthread.h | 11 +++++------ 1 file changed, 5 insertions(+), 6 deletions(-) (limited to 'ppsthread.h') 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 */ -- cgit v1.2.1