3

The pigpio GPIO library seems to provide a mechanism to invoke the pigpiod demon remotely using TCP/IP sockets. However, there appears to be some details missing. For example:

  • Do we use a TCP or UDP socket?
  • How do we terminate sending a command?
  • How do we know when the response is received/terminated?

Do we have any sample apps using native socket APIs either in C or Java?

Later ... Have started to reverse engineer code and it appears to be TCP sockets (AF_INET) ...

1 Answer 1

4

pigpio daemon

C I/F to pigpio daemon

Socket commands and responses

Examples of usage (in the download):

  • from Python is pigpio.py
  • from C is pigs.c
  • from C is pigpiod_if.c
  • using C I/F to daemon is x_pigpiod_if.c
3
  • Thank you Joan. I had failed to find: abyz.co.uk/rpi/pigpio/sif.html
    – Kolban
    Apr 20, 2015 at 11:47
  • 1
    @Kolban I sent an e-mail with the link. It may have got consumed by your spam system.
    – joan
    Apr 20, 2015 at 12:23
  • Thanks my friend. Will be studying in great depth as soon as I can. My hope is to build a sample for calling pigpio natively from Java ... remotely ... using Sockets. If that test works, I'll look to provide a Java class that implements the pigpio APIs in 100% pure Java that then won't require any Linux libraries and can run anywhere that Java can run (eg. Windows, Mac, Android etc etc). When done ... and with agreement from the community, I'll donate for others to benefit.
    – Kolban
    Apr 20, 2015 at 20:17

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge that you have read and understand our privacy policy and code of conduct.

Not the answer you're looking for? Browse other questions tagged or ask your own question.