[LinuxPPS] some problems with linuxPPS + GPS system

Hal V. Engel hvengel at astound.net
Tue Sep 9 18:59:42 CEST 2008


On Tuesday 09 September 2008 02:42:56 am david wrote:
> Dear all,
>
> I try to install on a pc with VIA processor a ntp system with a GP18LVC
> garmin GPS.
>
> I use debian and recompile the kernel with 2.6.26 kernel and the diff
> file ntp-pps-2.6.26.diff
>
> I follow the wiki but I had problem to get pps information.
>
> I found this difference with the wiki :
>
> 1) I need to load ktimer to have an answer at the command : tree
> /sys/class/pps

If your pps device is working you should not need to do this.  The ktimer 
module is to create a fake pps signal for testing.

>
> 2) the result show device missing field
>
> /sys/class/pps
>
> |-- pps0
> |
> |   |-- assert
> |   |-- clear
> |   |-- dev
> |   |-- echo
> |   |-- mode
> |   |-- name
> |   |-- path
> |   |-- power
> |   |   `-- wakeup
> |   |-- subsystem -> ../../pps
> |
> |   `-- uevent
>
> `-- pps1
>
>      |-- assert
>      |-- clear
>      |-- dev
>      |-- echo
>      |-- mode
>      |-- name
>      |-- path
>      |-- power
>      |   `-- wakeup
>      |-- subsystem -> ../../pps
>
>      `-- uevent
>
> 6 directories, 18 files
>
> 3) ./ppsfind /dev/ttyS0 give :
>
> pps0: name=serial0 path=/dev/ttyS0
>
> In the wiki this is pps1 (is it important ?)

No.

>
> 4) I patch ntpd with the file nmea.patch and when I try to get ntpq -p
> information, I always had NMEA and not PPS like this :
>
> /usr/src/ntp-4.2.2p4/ntpq/ntpq -pn
>       remote           refid      st t when poll reach   delay   offset
>   jitter
> ===========================================================================
>=== *127.127.20.0    .GPS.            0 l   18   16  377    0.000   10.107
> 3.417

First you need to confirm that your pps signal is actaully working.   Have you 
tried?

 ppstest /dev/pps0

If so what do you get?  For this to work you will need to have ntpd stopped 
and you will need to have 

 ppsldisc /dev/ttyS<what ever device you are using>

running.  The above (IE. ppsldisc...) also needs to be running when you start 
ntpd.  There was an earlier thread here that started around Aug. 5 about this 
titled gps_nmea error that you might want to have a look at.  This thread has 
lots of details on what to expect from ppstest and lots of other info for the 
refclock driver and GPS you are using.

If you are not getting the correct results for ppstest then we can help you 
get that working.  Once that is working the rest is fairly easy.

>
> 5) my ntp.conf is :
>
> # /etc/ntp.conf, configuration for ntpd
>
> driftfile /var/lib/ntp/ntp.drift
> statsdir /var/log/ntpstats/
> logfile /var/log/ntpd.log
>
> statistics loopstats peerstats clockstats
> filegen loopstats file loopstats type day enable
> filegen peerstats file peerstats type day enable
> filegen clockstats file clockstats type day enable
>
> logconfig = +syncall +clockall +sysall +peerall
> statistics loopstats peerstats clockstats
>
> # LinuxPPS: GPS + PPS
> server 127.127.20.0 prefer minpoll 4
> fudge 127.127.20.0 flag3 1 flag2 0 time1 0.0
>
> # By default, exchange time with everybody, but don't allow configuration.
> # See /usr/share/doc/ntp-doc/html/accopt.html for details.
> restrict -4 default kod notrap nomodify nopeer noquery
> restrict -6 default kod notrap nomodify nopeer noquery
>
> # Local users may interrogate the ntp server more closely.
> restrict 127.0.0.1
> #restrict ::1
>
>
> I don't understand why I don't had the PPS information in ntpd
>
> I try to long PPS pulse to 200ms (I read something about problems on
> web) without success.

The PPS pulse only needs to be longer than the clock tick interval for your 
kernel.  So if you have this set to 100 ticks/second the pulse needs to be at 
least 10 milliseconds or longer.  So pulse length is only really a concern for 
devices with very short PPS pulse lengths (some are only a few milliseconds) 
which is not an issue with your GPS.  Having a longer than needed pulse is not 
an issue.

Hal
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://ml.enneenne.com/pipermail/linuxpps/attachments/20080909/1f690109/attachment.htm 


More information about the LinuxPPS mailing list