gpsd-users
[Top][All Lists]
Advanced

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

[gpsd-users] Unexpected behavior


From: Nick Burkitt
Subject: [gpsd-users] Unexpected behavior
Date: Fri, 15 Sep 2017 09:52:19 -0700

Hi.

 

My apologies if this is a duplicate…

I’m attempting to use GPSD with LinuxPPS. My hardware environment is an embedded device with a u-blox NEO-M8T GPS module connected to a Xilinx Zynq FPGA, which contains, in part, logic equivalent to a 16550 UART. The (inverted) output of the GPS module’s PPS pin (TIMEPULSE) is connected, via programmable logic, to the DCDn input of the UART. The width of the GPS module’s PPS output pulse is 100 ms. The UART driver is the standard Linux 8250 module.

The OS is Ubuntu 14.04 LTS.

My kernel (4.4) configuration looks like this in menuconfig:

 

-*- PPS support

[*]          PPS debugging messages

                *** PPS clients support ***

                <M>      Kernel timer client (Testing client, use for debug)

                <M>      PPS line discipline

                <M>      PPS client using GPIO

 

(I added the GPIO client selection while trying to debug things – it’s not really necessary).

When I run GPSD as a foreground application, as root, with this command line

 

gpsd -D 2 -N -n /dev/ttyS0

 

I get output like this:

 

address@hidden gpsd -D 2 -N -n /dev/ttyS0

gpsd:INFO: launching (Version 3.9)

gpsd:INFO: listening on port gpsd

gpsd:ERROR: unable to connect to the DBUS system bus

gpsd:INFO: NTPD ntpd_link_activate: 1

gpsd:INFO: stashing device /dev/ttyS0 at slot 0

gpsd:INFO: opening GPS data source type 2 at '/dev/ttyS0'

gpsd:INFO: speed 115200, 8N1

gpsd:INFO: speed 9600, 8O1

gpsd:INFO: KPPS checking /sys/devices/virtual/pps/pps0/path, /dev/ttyS0

gpsd:INFO: KPPS caps 1133

gpsd:WARN: KPPS kernel PPS will be used

gpsd:INFO: KPPS cycle: -13577253, duration: -13577253 @ 1504801908.118491036

gpsd:INFO: PPS cycle: -13577121, duration: -13577121 @ 1504801908.118623

gpsd:INFO: KPPS cycle: -13477257, duration:   99996 @ 1504801908.218487449

gpsd:INFO: KPPS cycle:  999985, duration:  899989 @ 1504801909.118475719

gpsd:INFO: KPPS cycle:  999987, duration:   99997 @ 1504801909.218473536

gpsd:INFO: speed 115200, 8N1

gpsd:INFO: gpsd_activate(): activated GPS (fd 5)

gpsd:INFO: device /dev/ttyS0 activated

gpsd:INFO: running with effective group ID 20

gpsd:INFO: running with effective user ID 65534

gpsd:INFO: startup at 2017-09-07T16:31:49.000Z (1504801909)

gpsd:INFO: /dev/ttyS0 identified as type Generic NMEA (0.004399 sec @ 115200bps)

gpsd:WARN: unknown sentence: "$GNTXT,01,01,01,PASH inv format*28\x0d\x0a"

gpsd:WARN: unknown sentence: "$GNTXT,01,01,01,PGRM inv format*2A\x0d\x0a"

gpsd:WARN: unknown sentence: "$GNTXT,01,01,01,PSRF inv format*35\x0d\x0a"

gpsd:WARN: unknown sentence: "$GNTXT,01,01,01,PFEC inv format*32\x0d\x0a"

gpsd:WARN: unknown sentence: "$GNTXT,01,01,01,PTNL inv format*24\x0d\x0a"

gpsd:INFO: KPPS cycle:  999984, duration:  899986 @ 1504801910.118459378

gpsd:INFO: KPPS cycle:  999984, duration:   99997 @ 1504801910.218456853

gpsd:WARN: unknown sentence: "$GNTXT,01,01,01,PFEC inv format*32\x0d\x0a"

gpsd:WARN: unknown sentence: "$GNTXT,01,01,01,PASH inv format*28\x0d\x0a"

gpsd:WARN: unknown sentence: "$GNTXT,01,01,01,PMTK inv format*20\x0d\x0a"

gpsd:INFO: KPPS cycle:  999990, duration:  899993 @ 1504801911.118449218

gpsd:INFO: KPPS cycle:  999988, duration:   99994 @ 1504801911.218444104

gpsd:INFO: KPPS cycle:  999987, duration:  899992 @ 1504801912.118435452

gpsd:INFO: KPPS cycle:  999994, duration:  100002 @ 1504801912.218437502

gpsd:INFO: KPPS cycle:  999985, duration:  899983 @ 1504801913.118419919

gpsd:WARN: PPS TIOCMIWAIT returns unchanged state, ppsmonitor sleeps 10

gpsd:INFO: KPPS cycle: 10999840, duration:       0 @ 1504801923.218276895

gpsd:INFO: KPPS cycle: 10999844, duration:  899987 @ 1504801924.118263110

gpsd:INFO: KPPS cycle:  999993, duration:  100005 @ 1504801924.218269096

gpsd:INFO: KPPS cycle:  999991, duration:  899985 @ 1504801925.118253627

gpsd:INFO: KPPS cycle:  999982, duration:   99996 @ 1504801925.218250340

gpsd:INFO: KPPS cycle:  999985, duration:  899988 @ 1504801926.118238127

gpsd:INFO: KPPS cycle:  999985, duration:   99996 @ 1504801926.218234810

gpsd:INFO: KPPS cycle:  999980, duration:  899983 @ 1504801927.118217500

gpsd:INFO: KPPS cycle:  999983, duration:   99999 @ 1504801927.218217300

gpsd:WARN: PPS TIOCMIWAIT returns unchanged state, ppsmonitor sleeps 10

gpsd:INFO: KPPS cycle: 10999855, duration:       0 @ 1504801938.118072112

gpsd:INFO: KPPS cycle: 10999852, duration:   99996 @ 1504801938.218068912

gpsd:INFO: KPPS cycle:  999986, duration:  899989 @ 1504801939.118057146

gpsd:INFO: KPPS cycle:  999989, duration:  100000 @ 1504801939.218057402

gpsd:INFO: KPPS cycle:  999987, duration:  899986 @ 1504801940.118043148

gpsd:INFO: KPPS cycle:  999981, duration:   99994 @ 1504801940.218037971

gpsd:INFO: KPPS cycle:  999988, duration:  899993 @ 1504801941.118030528

gpsd:INFO: KPPS cycle:  999994, duration:  100000 @ 1504801941.218031252

gpsd:INFO: KPPS cycle:  999986, duration:  899985 @ 1504801942.118016036

gpsd:WARN: PPS TIOCMIWAIT returns unchanged state, ppsmonitor sleeps 10

 

The expected duration is, of course, 100 ms, and every second KPPS cycle report matches that expectation. But in between the expected duration reports are reports claiming a 900 ms duration, and then the TIOCMIWAIT warnings, which suggest that GPSD is using user-space PPS instead of KPPS.

 

While GPSD is running, I can cat the pps assert and clear sysfs files, which seem to return reasonable values.

 

address@hidden:/sys/devices/virtual# while true; do date; cat pps/pps0/assert pps/pps0/clear; sleep 1; done

1504802767.106082242#321

1504802767.206077443#321

Thu Sep  7 16:46:07 UTC 2017

1504802767.106082242#321

1504802767.206077443#321

Thu Sep  7 16:46:08 UTC 2017

1504802768.106068935#322

1504802768.206063338#322

Thu Sep  7 16:46:09 UTC 2017

1504802769.106056216#323

1504802769.206048951#323

Thu Sep  7 16:46:10 UTC 2017

1504802770.106042567#324

1504802770.206030037#324

Thu Sep  7 16:46:11 UTC 2017

1504802771.106029770#325

1504802771.206027917#325

Thu Sep  7 16:46:12 UTC 2017

1504802772.106015086#326

1504802772.206013074#326

Thu Sep  7 16:46:13 UTC 2017

1504802773.105998013#327

1504802773.205995257#327

Thu Sep  7 16:46:14 UTC 2017

1504802774.105984688#328

1504802774.205984140#328

Thu Sep  7 16:46:15 UTC 2017

1504802775.105970223#329

1504802775.205972660#329

 

My question, then, is – does it appear that KPPS and/or GPSD are functioning incorrectly (or have been incorrectly configured)?

Thanks in advance,

 

-Nick

 


reply via email to

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