7,260 Experience
72 Lessons Completed
0 Questions Solved


Posted in Ruby gems to interact with Raspberry Pi GPIO

I can't remember all of them because I dabbled with that couple of months ago. Most of them are more than 5-6 years without a commit. Didn't cross my mind I could search for help here. What I can recall is that rpi_gpio gem was 32bit but my ubuntu server is 64bits.

c_GPIO gem would always give me "uninitialized constant GPIO::Led (NameError)" for "led = 17)" so I gave up there.

pi_piper is what I tried last and that one sort of works. First time when I send a request it works, second request gives me this error. "Errno::EBUSY - Device or resource busy @ fptr_finalize_flush - /sys/class/gpio/export (Errno::EBUSY)"

Something like pin on, sleep 2 sec, pin off should be fairly easy and I've done it successfully in Python I am not able to make it work with Ruby :/

Posted in Ruby gems to interact with Raspberry Pi GPIO

I'm doing a small project in Sinatra where I want to unlock my doors via internet and Pi. Super simple. I'm still learning Ruby and Rails. I was searching for a Ruby GPIO gem and there is a quite few of them on GitHub but most of them haven't been updated in years. And when I try them they are mostly not working. Can someone recommend me, or knows about, a Ruby gem that is up to date and working with Pi GPIO?

Thank you in advance,