• Advertisement
Sign in to follow this  

Linux gamepad support and /dev/input/event permissions

This topic is 2933 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

Hello all- I've been working on a simple gamepad library. Eventually it will be multiplatform, but I've developing the alpha on linux. So far, everything has gone well. I've been using the linux input event model, using /dev/input/eventX files, to read and write to the attached devices. For instance, I've been able to read a variety of USB-attached gamepads and get rumble working, etc. However, with the latest Fedora release (12) I notice that permissions to /dev/input/eventX files have been restricted to root only. The kernel creates a /dev/input/jsX file for joysticks and gives it world-readable permissions, but that device doesn't support force feedback, and even if it did, the permissions would have to be writeable. In effect, the existing kernel permissions model makes truly interactive devices (with force feedback or any information flowing back to the physical device) impossible without root privileges or yet another daemon process to translate. Does anyone know what is going to happen here? I have no idea how I'm supposed to write a gamepad library now. Obviously I could write a gamepad daemon and ask all distributions to pick it up but that seems pretty silly. Hopefully someone on these boards has more information. -Thomas

Share this post


Link to post
Share on other sites
Advertisement
You can write some udev rules that create the proper permissions for those files. I agree, that the stock rules simple suck.

Share this post


Link to post
Share on other sites
Sign in to follow this  

  • Advertisement