ADB Android debugger download

Source: Internet
Author: User


ADB is a 10 thousand-capable tool that allows you to manage the status of Android devices. For more information about ADB, see: http://developer.android. com/GUIDE/developing/tools/adb.html.

ADB has the following functions:

  1. Download and install the APK application on the host and start running on the target device;
  2. Start the shell of the target device on the host;
  3. Use the ddms (Dalvik debug monitor server, which runs on the upper layer of ADB) tool to debug applications running on the device;
  4. Copy files between the host and the device;

Download ADB and install the configuration host (Ubuntu-12.04)

ADB is part of the android SDK package. You can find it at http://developer.android.com/sdk/index.html. After installing the android SDK in the following steps, run the following command to configure the environment variable:

$ Export Path = <android_sdk_path>/platform-tools/: <android_sdk_path>/tools/: $ path

There are three methods to connect hosts and devices through ADB:

  1. Use USB
  2. Network

Use USB

First, ensure the USB connection between the host and the device, and enable USB debugging with the developer option in the device.

Create/etc/udev/rules as administrator. d/51-android.rules file to enable the host to detect the device and add the device ID to the file, for example, 18d1. If it is a USB device, use the lsusb command to view the ID of the USB device that is currently connected to the host.

Subsystem = "USB", sysfs {idvendor} = "18d1", mode = "0666"

Save and exit.

Run the following command:

$ Chmod A + R/etc/udev/rules. d/51-android.rules

Note: We recommend that you change the configuration and then restart the host system.

Finally, check whether the device is connected to the ADB devices. If the device is connected, for example:

List of devices attached

20100720

Device

Network-Ethernet

Ensure that the Ethernet of the host and device is enabled;

View the network settings of a device:

# Netcfg

Lo up 127.0.0.1/8 0x00000049 00: 00: 00: 00: 00: 00

Sit0 down 0.0.0.0/0 0 0x00000080 00: 00: 00: 00: 00: 00

Eth0 up 192.168.0.100/22 0x00001043 96: CD: DF: 8B: C6: 2b

Use setprop to configure the device's ADB daemon:

# Setprop service. ADB. tcp. port 5555

If the network configuration is successful through the above steps, you can run the following command to restart the ADB service of the target board:

# Stop adbd

# Start adbd

Run the following command on the host to establish an ADB connection:

$ Export adbhost = <target's IP address>

$ ADB kill-Server

$ ADB start-Server

$ ADB connect <target_ip_address>: 5555

Run the following command to check whether the connection is connected:

$ ADB Devices

If the connection is established, there will be a list of devices:

List of devices attached

172.24.191.26: 5555 Device

Start the shell of the target board

$ ADB Shell

 

ADB Windows PC connected via USB

The general steps are as follows:

  1. Download the latest Android SDK
  2. Configure Environment Variables
  3. Download Android USB driver (https://dl-ssl.google.com/android/repository/usb_driver_r03-windows.zip) decompress to (I. e. c: \ android_sdk \ usb_driver)
  4. Modify (or create a file) "% USERPROFILE % \. Android \ adb_usb.ini ":

    > Echo 0x18d1> "% USERPROFILE % \. Android \ adb_usb.ini"
  5. Modify android_winusb.inf file configuration EVM/Beagle vendor and product IDs:

    In the [Google. ntx86] section, add:

    ; Ti EVM

    % Singleadbinterface % = usb_install, USB \ vid_18d1 & pid_9018

    % Compositeadbinterface % = usb_install, USB \ vid_18d1 & pid_9018 & mi_01

If it is amd64-bit, add it under the Google. ntamd64 segment.

6. Connect the USB boot device;

7. If it is normal, Windows will prompt you to install the device driver;

Answer "no, not this time" to the question about running Windows Update to search for software.

• Choose "Install the hardware that I manually select from a list (advanced)" This is the 2nd option, then click

"Next"

• Select "show all devices", then click "Next"

• You are going to see a grayed-out text box with "(retrieving a list of all devices)", click the "have disk ..."

Button

• Browse "to your driver folder (C: \ android_sdk \ usb_driver). It will be looking of A. inf file so select

"Android_winusb.inf" and click "open" then "OK". It's the only file there so you shouldn't go wrong.

• Select "android ADB interface" then click the "Next" button.

• A warning will appear, answer "yes" but read the warning anyway.

• Click the "close" when the Wizard is completed.

8. After the normal settings are complete,

> ADB kill-Server

> ADB start-Server

Then you can use the command.

Basic operation device name order:

1. Install APK

$ ADB install <package>. APK

To install it on an external device, add-S

2. Uninstall APK

Method 1:

ADB shell PM list packages

ADB uninstall <package name>

Method 2:

Go to settings-uninstall the application

Uninstall the default program that comes with the system:

$ ADB Shell

# Rm/system/APP/app.apk

3. Copy files between the host and the device

ADB push <local> <remote>

ADB pull <remote> <local>

 

Refer to: Ti devkit userguide.

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.