gpsd-users
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: NMEA but no PPS in ntp, Ubuntu 18.04.5


From: Steve Bourland
Subject: Re: NMEA but no PPS in ntp, Ubuntu 18.04.5
Date: Thu, 3 Dec 2020 08:42:59 -0600
User-agent: Alpine 2.21 (DEB 202 2017-01-01)

Yo Gary!
  I've tried to attach the output of:

# gpsd -N -n -D 6 /dev/ttyS0 |& fgrep PPS

as a text file attachment, I hope it comes through in an easier to read format for you. I had to add the -N to keep from daemonizing to get the output. If I am reading it correctly, it looks like it is activating ntpshm link #1 as we had hoped/expected (using SHM(2) did not solve the problem, which I think is now expected given the ntpshm_link_activate line). It look like the PPS thinks there is no fix, although cgps reports one:

[...]
│ Status:         3D DGPS FIX (90 secs)     │
[...]


As to why I have the '-b' in the command line, that is a carryover from my "standard" gpsd configuration starting way back in Ubuntu 10.04's time frame I believe, I've just dragged it along...will ditch it moving forward now that I understand the broken binaries it is dealing with aren't mine :)
                                        Thanks,
                                          Steve

On Wed, 2 Dec 2020, gpsd-users-request@nongnu.org wrote:

------------------------------

Message: 2
Date: Tue, 1 Dec 2020 13:52:23 -0800
From: "Gary E. Miller" <gem@rellim.com>
To: <gpsd-users@nongnu.org>
Subject: Re: NMEA but no PPS in ntp, Ubuntu 18.04.5
Message-ID: <20201201135223.361f4bb7@spidey.rellim.com>
Content-Type: text/plain; charset="utf-8"

Yo Steve!

On Tue, 1 Dec 2020 15:24:18 -0600
Steve Bourland <sbourland@swri.org> wrote:

   Super happy to learn about new places to look for information :)

So much internet, so little time.

> But no PPS.  You also do not have enough other chimers.  Hard to
> vote with only 2 voters.
I have 4 other voters but figured their info wasn't relevant, and
knew I was already going to have a long message, just trying to keep
it as short as possible.

When removing data, this tells us you did: [...]

> That is good.  What is your gpsd command line?  See it this way:
> # pstree -paul | fgrep gpsd
# pstree -paul | fgrep gpsd
   |-gpsd,25099,nobody -b -n /dev/ttyS0
   |   `-{gpsd},25100
   |                       |-grep,25730 -F --color=auto gpsd

Why are you using -b?  That is to fix Bluetooth problems.  Otherwise looks
good.


> Uh, you have if backwards.  The kernel feeds PPS to gpsd.  Then gpsd
> uses a SHM to eed it to ntpd.
Is the lack of /dev/pps0 on the gpsd command line causing the issue?

Normally not.  But cant hurt to try it.  Then your PPS would be
on SHM(2) if you did: gpsd -n /dev/ttyS0 /dev/pps0

What does this show:
       gpsd -n -D 6 /dev/ttyS0 |& fgrep PPS

It should show PPS being configured properly.  As long as you start as root.


ntpshmmon
ntpshmmon: version 3.21

# Name Seen@ Clock Real L Prc

sample NTP0 1606854237.160599667 1606854236.723461751
1606854236.000000000 0 -20
sample NTP2 1606854237.160618091 1605548548.531056191
1605548548.000000000 0 -20

For some reason your PPS is on SHM(2), not SHM(1).  Odd, that usually
happens when you ut /dev/pps0 on the gpsd command line.

Adjust your nto.conf to fit and it should all work fine.

Using this super cool new tool on a functioning system,
I see NTP2, NTP3, and then NTP0, NTP1 every second.

That would mean you have two serial and two PPS sources nn that system.

> You need to be running gpsd and ntpd as root, of course.
They both start as root but then drop privleges so gpsd runs as
nobody, and ntpd runs as "ntp."  I believe this is expected behavior?

Yes.  Good.

So hopefully I'm following along here, but it looks to me like gpsd
isn't putting the PPS timing in the shared memory for ntpd,

No.  We confirmed gpsd is putting PPS on SHM(2), not SHM(1) as you,
and I, expected.

Restarted gpsd on the command line with -D 5 to see if there was
useful information:

Once again, the interesting parts you deleted.  Do this:

       # gpsd -n -D 6 /dev/ttyS0 |& fgrep PPS

RGDS
GARY

Attachment: temp.txt
Description: Text document


reply via email to

[Prev in Thread] Current Thread [Next in Thread]