[time-nuts] measuring os latency for pps

Andrew Symington andrew.c.symington at gmail.com
Tue Aug 25 13:53:26 EDT 2015

Hi Folkert

If you have a board with a hardware timer that supports load/match/compare
then you can schedule an external interrupt to be generated at a
predetermined point in the hardware count. Thus, if you know the transform
between your disciplined clock and the hardware counter of the timer that
drives it, then you should be able to do this. I have spent some time
working with the (pretty neat) timers on board a beaglebone black, and I've
written some code to setup input capture and compare on up to 4 timers:


On Tue, Aug 25, 2015 at 8:24 AM, folkert <folkert at vanheusden.com> wrote:

> Hi,
> Not sure if it is interesting for you guys but I wrote a simple program
> for e.g. Linux (or any other system with the pps api implemented) that
> listens on a pps source waiting for a pulse and then toggles a gpio
> pin. That way you can measure the latency introduced by the the kernel
> when listening from userspace. Note that there's a little extra latency
> due to the gpio-pin handling.
> It is on github: https://github.com/flok99/pps2gpio
> Folkert van Heusden
> --
> MultiTail cok yonlu kullanimli bir program, loglari okumak, verilen
> kommandolari yerine getirebilen. Filter, renk verme, merge, 'diff-
> view', vs.  http://www.vanheusden.com/multitail/
> ----------------------------------------------------------------------
> Phone: +31-6-41278122, PGP-key: 1F28D8AE, www.vanheusden.com
> _______________________________________________
> time-nuts mailing list -- time-nuts at febo.com
> To unsubscribe, go to
> https://www.febo.com/cgi-bin/mailman/listinfo/time-nuts
> and follow the instructions there.

More information about the time-nuts mailing list