1

I am trying to get a viperboard USB GPIO board running on ubuntu. I already got a newer kernel, because I understood that the 3.13 kernel doesn't support the viperboard so well.

What I want to do is to use the /sys/class/gpio sysfs interface for GPIO so I can develop raspberry pi projects on my PC and then use them on my RPi.

My Problem - the /sys/class/gpio directory is missing. The config of the kernel shows:

CONFIG_GPIO_SYSFS is not set

Does this mean I have to compile a new kernel?

Falko
  • 17,076
  • 13
  • 60
  • 105
HankTheTank
  • 537
  • 5
  • 15

2 Answers2

1

I just had to recompile the kernel with CONFIG_GPIO_SYSFS set; now I see the /sys/class/gpio directory. Ubuntu does not enable gpio sysfs by default.

tshepang
  • 12,111
  • 21
  • 91
  • 136
HankTheTank
  • 537
  • 5
  • 15
0

I solved my Ubuntu-GPIO problems with the pigpio library.

It runs a daemon started with sudo, which is controlling the GPIO pins. A client program (started without sudo) communicates with the deamon and thus indirectly controls the pins.

You can even run the client on a remote machine. This way a ROS node can control the GPIO pins of a remote raspberry, which itself isn't even running ROS.

See this and this post for reference.

Community
  • 1
  • 1
Falko
  • 17,076
  • 13
  • 60
  • 105