Root privileges for GPIO, I2C, etc ...

Mario
New Member Posts: 9
Hello
Here's my situation: I'm running Ubuntu 14.04 and ROS and I have a ROS node that needs access to the I2C and GPIO pins. Of course launching the node as a normal user fails because of the permissions. I could always prepend sudo and make it work, but then I would also need to export my ROS and catkin workspace paths as root to even find the node I'm trying to launch and some python modules required by it. Even though this works, I believe it is a very ugly solution specially because that node is part of a long launch chain. I would need to launch this particular node independently with all the steps mentioned before. I would like to know if there is a group for GPIO, I2C just like the dialout group (ex: I'm using a node in my project that accesses ttyUSB) so that my user has access to these pins. If not is this easy to create or is there any other alternatives to do what I want?
Here's my situation: I'm running Ubuntu 14.04 and ROS and I have a ROS node that needs access to the I2C and GPIO pins. Of course launching the node as a normal user fails because of the permissions. I could always prepend sudo and make it work, but then I would also need to export my ROS and catkin workspace paths as root to even find the node I'm trying to launch and some python modules required by it. Even though this works, I believe it is a very ugly solution specially because that node is part of a long launch chain. I would need to launch this particular node independently with all the steps mentioned before. I would like to know if there is a group for GPIO, I2C just like the dialout group (ex: I'm using a node in my project that accesses ttyUSB) so that my user has access to these pins. If not is this easy to create or is there any other alternatives to do what I want?
Categories
- All Categories
- 105 Announcements & News
- 55 Product News - New Product/Product Change Notice/ End-of-life
- 186 Welcome Developers!
- 55 Unboxing & Project Sharing
- 50 Tech Updates
- 693 UP Products
- 11 UP 7000
- 1 UP Squared i12
- 10 UP Xtreme i12
- 11 UP Squared Pro 7000
- 1 UP Element i12 Edge
- 19 UP Squared V2
- 59 UP 4000
- 24 UP Xtreme i11
- 35 UP Squared 6000
- 60 UP Squared Pro
- 143 UP Xtreme
- 837 UP Squared
- 1.4K UP Board
- 89 UP Core Plus
- 222 UP Core
- 3 UP Xtreme Lite
- 44 UP AI Edge
- 216 Starter Kits & Peripheral