julianduque / beaglebone-io

BeagleBone Black IO Plugin for Johnny-Five
77 stars 29 forks source link

BeagleBone-IO requires root privileges #46

Closed fivdi closed 6 years ago

fivdi commented 6 years ago

Currently BeagleBone-IO requires root privileges for:

The slots file is deprecated on v4.4+ kernels so the code accessing it can be removed. ADC can be enabled/disabled in /boot/uEnx.txt. ADC is enabled by default.

On v4.11+ the files used to control PWM can be written without root privileges. Note that udev is used to set permissions here so it will be necessary to wait for udev to complete its work before accessing the PWM files. See https://github.com/jadonk/bonescript/issues/161.

Resolving this issue would mean that BeagleBone-IO could be used without root privileges which would be an excellent enhancement.

fivdi commented 6 years ago

PR #49 removes all usage of the slots file from BeagleBone-IO.

fivdi commented 6 years ago

PR #51 allows PWM to be used without root privileges on Kernel v4.11+

fivdi commented 6 years ago

Fixed by the combination of #49 and #51.