Monday, December 21, 2009

udev rules needed for your android device

This blogpost will contain the udev-rules needed for making adb work.

This information is partly copied from here. I've posted it here because that source wasn't available anymore, and it was for htc-devices only.

To add the rules file you must do the following steps:

1. Login as root and create this file: /etc/udev/rules.d/50-android.rules.
   For Gusty/Hardy/Intrepid/Jaunty/Karmic, edit the file to read:
     SUBSYSTEM=="usb", SYSFS{idVendor}=="0bb4", MODE="0666"
   For Dapper and earlier, edit the file to read:
     SUBSYSTEM=="usb_device", SYSFS{idVendor}=="0bb4", MODE="0666"
2. Now execute:
   chmod a+rx /etc/udev/rules.d/50-android.rules
3. And make the rule active by restarting udev:
   sudo /etc/init.d/udev restart

It is important to note that this only works for HTC-devices. However you can make it work for any device. You'll just have to change the value of SYSFS{idVendor} into another value (read further).

You can obtain the value of SYSFS{idVendor} by connecting your device via usb and launching the command lsusb:
an example output:

Bus 002 Device 001: ID 1d6b:0001 Linux Foundation 1.1 root hub
Bus 003 Device 001: ID 1d6b:0001 Linux Foundation 1.1 root hub
Bus 001 Device 003: ID 0bb4:0c02 High Tech Computer Corp.
Bus 001 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub


As you can see this is for a HTC (High Tech Computer Corp.) Device. And you can read the id of the vendor after ID and before the colon. So if you have another device, just use the id printed out. This by putting it in the quotes, instead of 0bb4 in /etc/udev/rules.d/50-android.rules.

Monday, July 27, 2009

Clean Ubuntu install

In this post I wanna give you a rough sketch of how I wanna have my new ubuntu installation on my acer Aspire 5024 WLMi.

I have a HD with a capacity of 80GiB and I have divided it as follows:
/dev/sda1 fat32 21.53GiB (My Windows partitions for school-applications)
/dev/sda2 extended partition containing:
/dev/sda5 ext4 33,49GiB(My home partition with Mount point /home)
/dev/sda6 linux-swap 1GiB
/dev/sda7 ext4 (My root partition with Mount point /)

The reason why I have a root partition and a home partition is because it's very convenient when you want to reinstall your linuxinstallation.

I've done a fresh install of jaunty jackalope. When the installation of the OS was completed I first fixed my wireless with the following 2 steps:
  1. System -> Administration -> Hardware Drivers
    and activate Broadcom B43 wireless driver
  2. Then you'll have te add acer_acpi wireless=1 to the content of /etc/modules
Next I've made an installation script for some very usefull application.
In comment you can find more information. sh-install-script

I've also uploaded my configuration file for compiz fusion (note the compizconfig-settings-manager in the install-script). compizconfig-settingsfile (use right-click -> save as...)

This configuration file gives you the following handy features:
  • mouse movement to upper left corner gives you an overview of all windows
  • mouse movement to bottom left corner hides all your windows so you can acces your desktop easily
  • right-click/leftclick in de bottom right corner will change the active window (you can compare it with alt-tab en schift-alt-tab under windows/linux).
  • Upper left corner doesn't do anything. I have placed the shutdown button over there.

  • rotating cube: all you're desktoppanes are different sides on a cube. You can change to a desktop left or right from the current one by doing a middle-mouse-button-click on the corresponding edge.



As you can see I have a quite sober panels but I find them quite handy.