[ntp:questions] Re: Some anomalies

Vaidotas J. dtroit at ktu.lt
Tue Nov 30 13:12:37 UTC 2004

On Mon, 29 Nov 2004 10:49:16 -0500
"Richard B. Gilbert" <rgilbert88 at comcast.net> wrote:

> Vaidotas J. wrote:
> >Hello,
> >
> >recently my office decided to create some QoS monitoring system and the main goal of it's correct results on some tests is precise time synchronization. So we bought few Trimble Acutime 2000 SyncKits and I've conected them at first to my WS and then to project notebook. It;s a little bit pitty, that (as far as i know), that Trimbles Palisade ref clock driver doesn't use ports B output also no PPS usage too ;(
> >But anyway, the synchronization is received and so on... After some time, i wrote this veeeery small c program to get the offset value from ntp_adjtime() function for one hour (calling it every 1 second). Here it is:
> >#include <sys/timex.h>
> >#include <sys/time.h>
> >#include <stdio.h>
> >int main(){
> >int i;
> >struct timeval ts;
> >struct timex *adjtm; //ntp_adjtime pointeris
> >adjtm = (struct timex *)malloc(sizeof(struct timex));
> >for (i=0;i<=3600;i++) {
> >ntp_adjtime(adjtm);
> >printf("%i\t%i\n",i, (unsigned int) adjtm->offset);
> >sleep(1);
> >} //foras
> >}
> >And i graphed some results enabling/disabling some kernel functions:
> >http://orka.litnet.lt/~dtroit/
> >(gnuplot was used as a ploting engine, with just simple input x,y from file, generated by this smaaaal c program of mine:)
> >
> >So in one graph we see that for sometime offset was 0, in some of the graphs (that are wildely absurd) the offset is taken just right after the ntpd is started and other graphs are commented.
> >The last graph I think is quite good and stable (that last jump is a mystery to me), but such offset with direct startum0 connected to PC isn't satisfieing. So maybe any ideas/responses to these graphs or some experience using Trimble GPS Acutime? What's the offset with Your Trimble Acutime and the settings of the system that runs it and other things. So if any ideas please help me to get the smallest ofset :) Because rigth now i've no more ideas :)
> >
> >PS> The notebook is:
> >model name      : Intel(R) Pentium(R) 4 Mobile CPU 1.70GHz
> >System parameters:
> >Linux ippm 2.6.9 #4 Fri Nov 26 16:39:29 EET 2004 i686 GNU/Linux
> >Debian 3.1 distr.
> >System has no other processes than ntpd, apache, sshd and the GPS is connected via UST-RS232 converter (no comm port on this notebook).
> >
> >Sincerely,
> >Vaidotas J.
> >LitNET,
> >Network engineer,
> >http://www.litnet.lt
> >dtroit at ktu.lt
> >  
> >
> My first guess is that you are having problems receiving the satellite 
> signals.  Further, I'd say that the times when you show a long run of 
> zero offset, you are getting a solid signal from four satellites.  Four 
> satellites are necessary and sufficient to solve for latitude, 
> longitude, height, and time.
> I'm not familiar with your Trimble hardware or the driver for it but; in 
> principle, if you know your position accurately you need only one 
> satellite to get the time.
> Things to check:
> 1.  Does your antenna have a clear view of the entire sky?  If not, >find 
> a better location for it.
It's mounted on the top of the building and the sky view is clear (cable length is 30 meters)
> 2.  Use nptq -p and check the "reach" field for your reference clock.  > If it is not 377 you have a problem!
dtroit at ippm:~$ ntptime -c
[ us 279952: 2 2 1 2 1 1 2 1 1 2 1 2 1 1 2 1 2 1 1 ]
ntp_gettime() returns code 0 (OK)
  time c556efda.47bcc000  Tue, Nov 30 2004 15:10:50.280, (.280224),
  maximum error 3656 us, estimated error 1036 us
ntp_adjtime() returns code 0 (OK)
  modes 0x0 (),
  offset -673.000 us, frequency 17.862 ppm, interval 4 s,
  maximum error 3656 us, estimated error 1036 us,
  status 0x1 (PLL),
  time constant 1, precision 1.000 us, tolerance 512 ppm,
  pps frequency 0.000 ppm, stability 512.000 ppm, jitter 200.000 us,
  intervals 0, jitter exceeded 0, stability exceeded 0, errors 0.
dtroit at ippm:~$ ntpq -p
     remote           refid      st t when poll reach   delay   offset  jitter
*GPS_PALISADE(0) .GPS.            0 l    7   16  377    0.000   -0.684   1.351

> 2.  Does your driver allow you to ignore satellites close to the 
> horizon?  If so, it may help to enable this feature.
That I shall check out shortly :)
> Another possibility is that both Linux and Windows have a reputation for 
> losing interrupts!  Losing clock ticks will do horrible things to your 
> timekeeping!!!!
Later i'll try to use fbsd :)
> _______________________________________________
> questions mailing list
> questions at lists.ntp.isc.org
> https://lists.ntp.isc.org/mailman/listinfo/questions

More information about the questions mailing list