[LinuxPPS] [PATCHv3 12/16] ntp: add hardpps implementation

Felix Joussein felix.joussein at gmx.at
Tue Oct 5 10:49:28 CEST 2010


  This was incorect information from me:

Of course, pps.h was in the header file directory...
It just, that the GNU find did not find it, strange...

I was in /usr/include and typed find . -name pps.h and got only the ones 
from the backuped directory.

How ever, it's there... and your program brings output....

The NTP behavior also has changed:

First: ntptime command now brings the status code 0x2007 
(PPL,PPSFREQ,PPSTIME,NANO) which is good, as this is apart from the 
status code the same flags I know from PPSKit + 2.4 kernel (See output) 
but also brings errors:

ntp_gettime() returns code 5 (ERROR)
   time d05563fd.bf9b4524  Tue, Oct  5 2010  8:44:45.748, (.748463205),
   maximum error 37991 us, estimated error 33 us
ntp_adjtime() returns code 5 (ERROR)
   modes 0x0 (),
   offset 46.994 us, frequency -17.849 ppm, interval 4 s,
   maximum error 37991 us, estimated error 33 us,
   status 0x2007 (PLL,PPSFREQ,PPSTIME,NANO),
   time constant 4, precision 0.001 us, tolerance 500 ppm,
   pps frequency 0.000 ppm, stability 0.000 ppm, jitter 0.000 us,
   intervals 0, jitter exceeded 0, stability exceeded 0, errors 0.


Also: the jitter/offset are heavily jumping around - also the output:

ie Okt 5 08:33:05 UTC 2010 xPPS(0) .ATOM. 0 l 15 16 377 0.000 -0.130 0.181
Die Okt 5 08:33:15 UTC 2010 xPPS(0) .ATOM. 0 l 9 16 377 0.000 -0.125 0.145
Die Okt 5 08:33:26 UTC 2010 xPPS(0) .ATOM. 0 l 4 16 377 0.000 -0.123 0.106
Die Okt 5 08:33:36 UTC 2010 xPPS(0) .ATOM. 0 l 14 16 377 0.000 -0.123 0.106
Die Okt 5 08:33:46 UTC 2010 xPPS(0) .ATOM. 0 l 8 16 377 0.000 -0.122 0.067
Die Okt 5 08:33:56 UTC 2010 xPPS(0) .ATOM. 0 l 2 16 377 0.000 -0.106 0.032
Die Okt 5 08:34:06 UTC 2010 xPPS(0) .ATOM. 0 l 12 16 377 0.000 -0.106 0.032
Die Okt 5 08:34:16 UTC 2010 xPPS(0) .ATOM. 0 l 6 16 377 0.000 -0.071 0.046
Die Okt 5 08:34:26 UTC 2010 xPPS(0) .ATOM. 0 l - 16 377 0.000 -0.050 0.066
Die Okt 5 08:34:36 UTC 2010 xPPS(0) .ATOM. 0 l 10 16 377 0.000 -0.050 0.066
Die Okt 5 08:34:46 UTC 2010 xPPS(0) .ATOM. 0 l 4 16 377 0.000 -0.029 0.080
Die Okt 5 08:34:56 UTC 2010 xPPS(0) .ATOM. 0 l 14 16 377 0.000 -0.029 0.080
Die Okt 5 08:35:06 UTC 2010 xPPS(0) .ATOM. 0 l 8 16 377 0.000 -0.014 0.083
Die Okt 5 08:35:16 UTC 2010 xPPS(0) .ATOM. 0 l 2 16 377 0.000 -0.006 0.079
Die Okt 5 08:35:26 UTC 2010 xPPS(0) .ATOM. 0 l 12 16 377 0.000 -0.006 0.079
Die Okt 5 08:35:36 UTC 2010 xPPS(0) .ATOM. 0 l 6 16 377 0.000 0.004 0.074
Die Okt 5 08:35:46 UTC 2010 xPPS(0) .ATOM. 0 l - 16 377 0.000 0.009 0.061
Die Okt 5 08:35:56 UTC 2010 xPPS(0) .ATOM. 0 l 10 16 377 0.000 0.009 0.061
Die Okt 5 08:36:06 UTC 2010 xPPS(0) .ATOM. 0 l 4 16 377 0.000 0.021 0.052
Die Okt 5 08:36:16 UTC 2010 xPPS(0) .ATOM. 0 l 14 16 377 0.000 0.021 0.052
Die Okt 5 08:36:27 UTC 2010 xPPS(0) .ATOM. 0 l 9 16 377 0.000 0.058 0.071
Die Okt 5 08:36:37 UTC 2010 xPPS(0) .ATOM. 0 l 3 16 377 0.000 0.077 0.075

So there must be something still wrong.

I have now removed the fudge flag3 1  to see, if that bouncing stops then.

I appreciate any help provided!

Thanks,

Felix


Am 2010-10-04 18:02, schrieb Reg Clemens:
> Just a question about your compiles w/o the pps.h .
>
> All of the programs
> 	ppsapitest8.c (the source I gave you)
> 	refclock_atom.c
> 	refclock_jupiter.c
> 	refclock_mx4200.c
> 	refclock_nmea.c
> 	refclock_oncore.c
> 	refclock_parse.c
> 	refclock_ripencc.c
> 	refclock_wwvb.c
>
> have an include ppsapi_timepps.h in them.
> This is just a silly stack of #ifdef's to look several places for the actual
> timepps.h .
>
> But then timepps.h includes pps.h from /usr/include/linux/pps.h .
>
> So, I dont understand how you could have had a clean compile of either my
> ppsapitest8.c
> nor atom.c / parse.c without it.
>
> The 'new' pps.h adds a define for PPS_KC_BIND , which is needed in the
> static __inline at the very end of timepps.h .
>
> Just a question, not a solution to your problem.
>
>




More information about the LinuxPPS mailing list