You are not logged in.
Sometimes I need to program microcontroller by USB programator from user account. To do this I created appropriate file in /etc/udev/rules.d/ with:
BUS!="usb", ACTION!="add", SUBSYSTEM!=="usb_device", GOTO="kcontrol_rules_end"
SYSFS{idProduct}=="0101", SYSFS{idVendor}=="1366", MODE="664", GROUP="plugdev"
LABEL="kcontrol_rules_end"and created group plugdev and added user to this group
The problem is that after every reboot I need to do:
# chgrp -R plugdev /dev/bus/usb/Is there any method to do above command instead of putting it in autostart?
###ADDED###
I noticed another problem. I suppose it regards to /dev/bus/usb permission. During booting I get:
udevd[149]: unknown key 'BUS' in /etc/udev/rules.d/45-jlink.rules:2
udevd[149]: invalid rule '/etc/udev/rules.d/45-jlink.rules:2'
udevd[149]: unknown key 'SYSFS{idVendor}' in /etc/udev/rules.d/45-jlink.rules:3
udevd[149]: invalid rule '/etc/udev/rules.d/45-jlink.rules:3'I have no idea what to do with that.
Last edited by koralgolek (2012-05-05 10:30:40)
Offline
Sometimes I need to program microcontroller by USB programator from user account. To do this I created appropriate file in /etc/udev/rules.d/ with:
I noticed another problem. I suppose it regards to /dev/bus/usb permission. During booting I get:
udevd[149]: unknown key 'BUS' in /etc/udev/rules.d/45-jlink.rules:2 udevd[149]: invalid rule '/etc/udev/rules.d/45-jlink.rules:2' udevd[149]: unknown key 'SYSFS{idVendor}' in /etc/udev/rules.d/45-jlink.rules:3 udevd[149]: invalid rule '/etc/udev/rules.d/45-jlink.rules:3'I have no idea what to do with that.
It's said right there - those keys do not exist. How did you come up with these rules?
As from some random udev rules I just checked out I cannot see any BUS key or SYSFS key
My advice would be: get rid of the BUS key (SUBSYSTEM should be enough anyway) and change SYSFS for ATTR.
Don't ask me why though - it's just what I found in some already present rules.. you can look at them as well, they're mostly in /lib/udev/rules.d/
good luck!
-miky
What happened to Arch's KISS? systemd sure is stupid but I must have missed the simple part ...
... and who is general Failure and why is he reading my harddisk?
Offline
mr.MikyMaus Thank You for advice
Now my udev rule looks like this:
ACTION!="add", SUBSYSTEM!=="usb_device", GOTO="kcontrol_rules_end"
ATTRS{idProduct}=="0101", ATTRS{idVendor}=="1366", MODE="664", GROUP="plugdev"
LABEL="kcontrol_rules_end"I got rid of BUS! and I changed SYSFS to ATTRS (ATTR is also acceptable)
Offline