[LinuxPPS] GPIO PPS Generator

Igor Plyatov plyatov at gmail.com
Fri May 17 16:36:59 CEST 2013


Dear guys,

here is an experimental driver for GPIO pps generator attached.

It was made from pps_gen_parport.c by me and tested with Linux 2.6.39.3.

Of course it have some drawbacks, but can be improved by yours if needed.

Unfortunately I don't have time to improve it now.

Good luck and best regards!
--
Igor Plyatov

> On Fri, May 17, 2013 at 03:54:13PM +0200, Drasko DRASKOVIC wrote:
>> Hi Rodolfo,
>>
>> On Fri, May 17, 2013 at 3:23 PM, Rodolfo Giometti <giometti at enneenne.com> wrote:
>>> On Fri, May 17, 2013 at 03:20:32PM +0200, Drasko DRASKOVIC wrote:
>>>> Hi all,
>>>> I'd like to test time synchronization of my two embedded systems
>>>> (Pandaboards). I thought connecting two Oscilloscope channels to the
>>>> GPIOs and use PPS to pules the GPIO.
>>>>
>>>> I have several questions :
>>>>
>>>> 1) Is there a GPIO PPS enerator support in the kernel. I can see only
>>>> the one that uses Parallel port
>>> You have an old kernel.
>> I was looking at the latest sources here :
>> http://lxr.linux.no/linux+v3.9.2/drivers/pps/generators/
>>
>> Parport is all there is.
>>
>> Can you point me please to the sources with GPIO generator ?
> Sorry! I supposed you meant PPS source... :'(
>
> You are rigth. There are no GPIO PPS generator support.
>
> Ciao,
>
> Rodolfo
>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: pps_gen_gpio.c
Type: text/x-csrc
Size: 7792 bytes
Desc: not available
URL: <http://www.linuxpps.org/pipermail/discussions/attachments/20130517/bfc8bc7d/attachment-0002.c>
-------------- next part --------------
#
# PPS generators configuration
#

comment "PPS generators support"

config PPS_GENERATOR_PARPORT
	tristate "Parallel port PPS signal generator"
	depends on PARPORT && BROKEN
	help
	  If you say yes here you get support for a PPS signal generator which
	  utilizes STROBE pin of a parallel port to send PPS signals. It uses
	  parport abstraction layer and hrtimers to precisely control the signal.

config PPS_GENERATOR_GPIO
	tristate "PPS signal generator for the GPIO pin"
	depends on GENERIC_GPIO
	help
	  If you say yes here you get support for a PPS signal generator which
	  utilizes GPIO. This GPIO should be specified in platform code. It uses
	  hrtimers to precisely control the signal.
-------------- next part --------------
#
# Makefile for PPS generators.
#

obj-$(CONFIG_PPS_GENERATOR_PARPORT) += pps_gen_parport.o
obj-$(CONFIG_PPS_GENERATOR_GPIO) += pps_gen_gpio.o

ifeq ($(CONFIG_PPS_DEBUG),y)
EXTRA_CFLAGS += -DDEBUG
endif


More information about the discussions mailing list