Configuring android devices to work with ADB on UBUNTU


Step 1:

Connect your device to your computer using USB

Step 2:

Open terminal and type command lsusb

This will give you list of all the USB devices connected to your computer.

anshu@Anshu-Notebook:~/android-base/android_2_3$ lsusb
Bus 002 Device 011: ID 2080:0002
Bus 002 Device 006: ID 413c:8160 Dell Computer Corp.
Bus 002 Device 005: ID 413c:8162 Dell Computer Corp.
Bus 002 Device 004: ID 413c:8161 Dell Computer Corp.
Bus 002 Device 003: ID 0a5c:4500 Broadcom Corp. BCM2046B1 USB 2.0 Hub (part of BCM2046 Bluetooth)
Bus 002 Device 002: ID 8087:0020 Intel Corp. Integrated Rate Matching Hub
Bus 002 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub
Bus 001 Device 003: ID 0c45:641d Microdia
Bus 001 Device 002: ID 8087:0020 Intel Corp. Integrated Rate Matching Hub
Bus 001 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub

Step 3:

open file /etc/udev/rules.d/51-android.rules in root mode and add entries into it

anshu@Anshu-Notebook:~/android-base/android_2_3$ sudo gedit /etc/udev/rules.d/51-android.rules

add following entry into the file.

SUBSYSTEM=="usb", ATTR{idVendor}=="2080", ATTR{idProduct}=="0002", MODE="0666", OWNER="anshu"

please note that ATTR{idVendor} and ATTR{idProduct} should match with USB device’s vendor & product ids.

here in my case it is 2080 & 0002.

Step 4: Restart udev service

anshu@Anshu-Notebook:~/android-base/android_2_3$ sudo service udev restart
udev start/running, process 8858

Step 5: Restart adb

anshu@Anshu-Notebook:~/android-base/android_2_3$ adb kill-server
anshu@Anshu-Notebook:~/android-base/android_2_3$ adb start-server
* daemon not running. starting it now on port 5037 *
* daemon started successfully *
anshu@Anshu-Notebook:~/android-base/android_2_3$
Advertisements

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s