Hi.
I'm not very familiar with udev, so there may be inaccuracies.
First you need to find a pair of numbers idVendor:idProduct which correspond to your usb device (such as usb-tty converter). Say, I have a Logitech usb mouse and I want udev to create /dev/logitech_mouse each time I plug it in.
To identify the device, type
Code:
$ lsusb
Bus 001 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub
Bus 002 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub
Bus 003 Device 001: ID 1d6b:0001 Linux Foundation 1.1 root hub
Bus 004 Device 001: ID 1d6b:0001 Linux Foundation 1.1 root hub
Bus 005 Device 001: ID 1d6b:0001 Linux Foundation 1.1 root hub
Bus 006 Device 001: ID 1d6b:0001 Linux Foundation 1.1 root hub
Bus 007 Device 001: ID 1d6b:0001 Linux Foundation 1.1 root hub
Bus 008 Device 001: ID 1d6b:0001 Linux Foundation 1.1 root hub
Bus 002 Device 028: ID 064e:a102 Suyin Corp. Acer/Lenovo Webcam [CN0316]
Bus 003 Device 002: ID 138a:0001 Validity Sensors, Inc. VFS101 Fingeprint Reader
Bus 003 Device 007: ID 0a5c:2151 Broadcom Corp. Bluetooth
Bus 005 Device 004: ID 046d:c062 Logitech, Inc.
So, for my mouse, idVendor=046d and idProduct=c062.
Now, to create udev rule I open /etc/udev/rules.d/99-local.rules and put there something like this
Code:
# Logitech mouse, example
SUBSYSTEMS=="usb", ATTRS{idProduct}=="c062", ATTRS{idVendor}=="046d", NAME="%k", SYMLINK+="logitech_mouse", MODE="0660"
To restart udev type
Code:
sudo /etc/init.d/udev restart
Hope this helps.
EDIT: Note that udev rules cannot span multiple lines.