Ubuntu USB udev permissions #25
White-Rabbit-Scientific
started this conversation in
General
Replies: 0 comments
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
-
In the documentation on docs.rs Kevin explains how to add permissions on Linux to enable access to the USB ports.
In my efforts to work thru this, I did the following (mostly the same as Kevin's instructions):
Move to .rules folder:
cd /etc/udev/rules.dCreate new .rules file using (required) admin privileges
sudo nano 70-plugdev-usb.rulesAdd to file per Kevin's instructions:
SUBSYSTEM=="usb", MODE="660", GROUP="plugdev"I think I could have been more permission-limiting by also adding to the file:
ATTRS{idProduct}=="XXXX", ATTRS{idVendor}=="YYYY",To find
XXXXandYYYY, uselsusbcommand to get the hex values of formatXXXX : YYYY.These are the same numbers required in the Rust code:
.find(|d| d.vendor_id() == 0xXXXX && d.product_id() == 0xYYYY)Reload udev rules:
sudo udevadm triggerNow my serial device fails due to "Stall" rather than lack of permissions. Yay !!!
Reference:
https://elinux.org/Accessing_Devices_without_Sudo
Beta Was this translation helpful? Give feedback.
All reactions