Wednesday, September 22, 2010

How to configure Huwawei E1550 USB modem on Ubuntu 10.04 ?

You need to add following rules file to configure the E1550 USB modem on Ubuntu 10.04.

$vi /etc/udev/rules.d/15-huwawei-155x.rules

SUBSYSTEM="usb",
ATTRS{idProduct}=="1446",
ATTRS{idVendor}=="12d1" ,
RUN+="/lib/udev/modem-modeswitch --vendor 0x12d1 --product 0x1446 --type option-zerocd"
 
Then save the file. That's it.

Brief look into above rules file. For that you need to know what udev means.

The udev provides a dynamic device directory containing only the files for actually presented devices.
Usually udev runs and receives events directly from the kernel if a device is added or removed from the system.
If a udev receives a device event, it matches its configured rules against the available device attributes provided in sysfs to identify the device.
The udev rules are read from the files located in the following locations,
  • default rules directory - /lib/udev/rules.d/
  • custom rules directory - /dev/udev/rules.d/
  • temporary rules directory - /dev/.udev/rules.d/

The rules files are stored and process in lexical order. Files with the same name in /etc/udev/rules.d have higher precedence than the files in /lib/udev/rules.d. This feature can be used to ignore a default rules file if needed.

You can find more information about udev from its man page.
man udev 
Also you can find more information about writing udev rules from here,
http://www.reactivated.net/writing_udev_rules.html

No comments:

Post a Comment