Adk Install on Ros

System Installation

Java:

# for oneiric
> sudo apt-get install java-6-openjdk 
# for lucid, enable 3rd party repositories and
> sudo apt-get install sun-java6-jdk 
> sudo update-alternatives --display java
> sudo update-alternatives --set java /usr/lib/jvm/java-6-sun/jre/bin/java

If on a 64 bit machine, the adk needs 32 bit emulation:

> sudo apt-get install ia32-libs

Ros Installation

Assuming you have a ros install already setup somewhere. We'll assume we're working with an installation in /opt/zeroconf.

Adk Download

Download the latest android development kit for linux (you can download older versions just by copying the link and replacing the version number). Untar somewhere appropriate (typical in /opt).

Append the following line to your setup.sh:

export PATH=${PATH}:/opt/android-sdk-linux/tools:/opt/android-sdk-linux/platform-tools

Android Devices

Udev

The final step is to make sure your device is recognised when you plug it in via usb to your pc. You'll need to set up udev to do that.

  • Plug the device into the usb on your pc.
  • Find the vendor id for your product:

> lsusb
> lsusb -s bus:devnum -v
  • Make a udev rule in /etc/udev/rules.d/51-android.rules:

# Samsung
SUBSYSTEM=="usb", ATTR{idVendor}=="04e8", MODE="0666", GROUP="plugdev"
SUBSYSTEM=="usb", ATTR{idProduct}=="681c", ATTR{idVendor}=="04e8", SYMLINK+="galaxytab"
# Motorola
SUBSYSTEM=="usb", ATTR{idVendor}=="22b8", MODE="0666", GROUP="plugdev"
# Lg
SUBSYSTEM=="usb", ATTR{idVendor}=="1004", MODE="0666", GROUP="plugdev"
Then restart udev and check it with adb:
  • Restart udev and check the adk can find your device.

> sudo restart udev
> adb devices

Wiki: zeroconf_android/ros_adk_setup (last edited 2012-02-26 06:49:15 by DanielStonier)