[LinuxPPS] PPS on Raspberry Pi - with device tree

Jan Lübbe jlu at pengutronix.de
Wed Aug 10 09:55:56 CEST 2016


On Di, 2016-08-09 at 18:46 -0400, tlhackque wrote:
> Add assert_falling_edge=true to config.txt, e.g.:
> 
> dtoverlay=pps-gpio,gpiopin=24,assert_falling_edge=true
> 
> Reboot, and you're in business.
> 
> In debugging this, I noticed that the driver doesn't have a
> "capture_clear" parameter for the device tree.
> I think one should be added - there is code for this on the "pdata"
> path.  Something like:
> if (of_get_property(np, "capture-clear", NULL))
>             data->capture_clear = true;
> at line 122 should do it.  Then the DT and pdata paths should be equivalent.
> 
> For reference, the RPi issue for this is
> https://github.com/raspberrypi/linux/issues/1590

No. As the DT should describe the hardware, it only describes which edge
is the assert. Which edge is captured at is configured by userspace at
runtime.

NTPd can configure the PPS capture itself or you can use pps-tools.

Regards,
Jan
-- 
Pengutronix e.K.                           |                             |
Industrial Linux Solutions                 | http://www.pengutronix.de/  |
Peiner Str. 6-8, 31137 Hildesheim, Germany | Phone: +49-5121-206917-0    |
Amtsgericht Hildesheim, HRA 2686           | Fax:   +49-5121-206917-5555 |





More information about the discussions mailing list