| # nomad.rules a udev rules file for NOMAD jukeboxes. |
| # Put this file in /etc/udev/rules.d |
| # |
| # This script sets the mode of the libnjb accessible devices |
| # to "666" meaning "read and write for everyone", really a security |
| # risk. Therefore think about it before applying this to your system. |
| # However since there are so many ways of managing permissions for |
| # devices we have no better idea. |
| # |
| # If you have a desktop user group, set MODE to "660" and tag |
| # on GROUP="jukebox" after the MODE rule. Subsitute GROUP |
| # "jukebox" for a good value for your system, this group should |
| # include desktop users (see your /etc/group). |
| # |
| # You can add a RUN="..." attribute to run some arbitrary script |
| # when the device is plugged in. |
| |
| # This rule, if enabled, creates a device node in the hierarchy |
| # /dev/bus/usb. This is already part of Fedora Core but I |
| # don't know about other distributions. Notice that this will |
| # require libusb to be patched too, or use libusb-0.1.12 or |
| # higher, or it just won't work. |
| # |
| # /dev/bus/usb identical to that of /proc/bus/usb. Most distributions |
| # using udev already has a rule like this. |
| |
| # ACTION=="add", SUBSYSTEM=="usb_device", \ |
| PROGRAM="/bin/sh -c 'K=%k; K=$${K#usbdev}; \ |
| printf bus/usb/%%03i/%%03i $${K%%%%.*} $${K#*.}'", \ |
| NAME="%c", MODE="0644" |
| |
| # Old erroneous rule used for debug purposes. |
| # ACTION=="add", SUBSYSTEM=="usb_device", PROGRAM="/bin/sh -c 'X=%k X=$${X#usbdev} B=$${X%%%%.*} D=$${X#*.}; echo bus/usb/$$B/$$D'", SYMLINK+="%c", RUN="/home/linus/bin/boxplugin %c" |
| |
| SUBSYSTEM!="usb_device", ACTION!="add", GOTO="nomad_rules_end" |
| |
| # Creative Nomad Jukebox |
| SYSFS{idVendor}=="0471", SYSFS{idProduct}=="0222", MODE="666" |
| # Creative Nomad Jukebox 2 |
| SYSFS{idVendor}=="041e", SYSFS{idProduct}=="4100", MODE="666" |
| # Creative Nomad Jukebox 3 |
| SYSFS{idVendor}=="041e", SYSFS{idProduct}=="4101", MODE="666" |
| # Creative Nomad Jukebox Zen |
| SYSFS{idVendor}=="041e", SYSFS{idProduct}=="4108", MODE="666" |
| # Creative Nomad Jukebox Zen USB 2.0 |
| SYSFS{idVendor}=="041e", SYSFS{idProduct}=="410b", MODE="666" |
| # Creative Nomad Jukebox Zen NX |
| SYSFS{idVendor}=="041e", SYSFS{idProduct}=="4109", MODE="666" |
| # Creative Nomad Jukebox Zen Xtra |
| SYSFS{idVendor}=="041e", SYSFS{idProduct}=="4110", MODE="666" |
| # Dell Digital Jukebox |
| SYSFS{idVendor}=="041e", SYSFS{idProduct}=="4111", MODE="666" |
| # Creative Nomad Jukebox Zen Touch |
| SYSFS{idVendor}=="041e", SYSFS{idProduct}=="411b", MODE="666" |
| # Creative Zen (Zen Micro variant) |
| SYSFS{idVendor}=="041e", SYSFS{idProduct}=="411d", MODE="666" |
| # Creative Nomad Jukebox Zen Micro |
| SYSFS{idVendor}=="041e", SYSFS{idProduct}=="411e", MODE="666" |
| # Second Generation Dell Digital Jukebox |
| SYSFS{idVendor}=="041e", SYSFS{idProduct}=="4126", MODE="666" |
| # Dell Pocket DJ |
| SYSFS{idVendor}=="041e", SYSFS{idProduct}=="4127", MODE="666" |
| # Creative Zen Sleek |
| SYSFS{idVendor}=="041e", SYSFS{idProduct}=="4136", MODE="666" |
| # Third Generation Dell Digital Jukebox |
| SYSFS{idVendor}=="041e", SYSFS{idProduct}=="412f", MODE="666" |
| |
| LABEL="nomad_rules_end" |