[time-nuts] Re: PPS latency? User vs kernel mode
rcbuck at atcelectronics.com
rcbuck at atcelectronics.com
Sun Dec 12 02:05:20 UTC 2021
Adam,
Where is the PPS signal derived from? If from a GPS, what do you mean by
processing on the PI? Do You update the seconds counter of the PI clock
with each PPS?
I have a NEO-6M connected to a STM32 custom board to drive six 2.3-inch,
7 segment LEDs. I use the PPS to kick the watchdog timer in the STM32. I
have the NEO-6M programmed to only output the GPRMC NMEA sentence. After
the sentence has been received I process the information for display
purposes. If the PPS disappears the clock simply displays 12:00:00 until
PPS returns. I've never seen the clock display 12:00:00 except at
startup. Usually it finds the satellites within 3-4 minutes. It takes
about 5-10 minutes before the NEO-6M makes the correction for the 3 leap
seconds that have occurred since 2012.
My scope measurements show ~150 ms from the rising edge of the PPS
signal until the end of the GPRMC sentence. It takes a couple of ms to
process the data and 12 ms to strobe all six digits. So I'm guessing my
error is below 180 ms. If I listen to WWV on my radio I cannot detect
any difference between the WWV top of minute beep and the display
seconds changing to 00. This is more than adequate for my shack clock.
Ray, AB7HE
On 2021-12-11 14:45, Adam Space wrote:
> I have a PPS with Raspberry Pi setup going. Of course, in terms of
> precision, it's quite good (for me it's as good as I'd ever care for),
> and
> for accuracy it's quite good too. Although I guess the problem is, I
> don't
> really know how good the accuracy is, nor am I sure how I would go
> about
> finding out.
>
> The only factor here would be a delay between the PPS signal and the
> processing in the Pi. I am not using kernel mode right now, which I
> assume
> makes this even worse. Nonetheless, it is certainly no more than one or
> two
> ms. When I run ntp with several other peers, you can't tell much of a
> difference. The accuracy limits of NTP are greater than the potential
> delay
> introduced by the processing of the PPS signal, so even running NTP
> with a
> lot of peers and averaging over long periods of time doesn't give much
> info
> on this. (Perhaps if I ran it long enough I could get the mean offset,
> but
> I think the uncertainty on this value would be larger than the value
> itself).
>
> I am curious what other folks with this type of set-up have done. Just
> leave it at that and accept that there's some unknown latency? Or
> perhaps
> the latency is on the order of microseconds, in which case it's not
> really
> a big deal for me.
>
> With regards to kernel mode, I was looking to give it a try. However,
> the
> guides I've found on this, some posted several years ago on this list,
> are
> pretty outdated. If someone has a suggestion for this, I'm interested
> in
> hearing it. Also, my Raspberry Pi is relatively new, running Bullseye,
> if
> that matters.
>
> Adam
> _______________________________________________
> time-nuts mailing list -- time-nuts at lists.febo.com -- To unsubscribe
> send an email to time-nuts-leave at lists.febo.com
> To unsubscribe, go to and follow the instructions there.
More information about the Time-nuts_lists.febo.com
mailing list