Connect your computer to your phone and install your phone driver usb-driver

Source: Internet
Author: User
Tags android sdk manager

Setting up a real-world development environment requires the following steps:

1. Declare the application to be debug in the application's manifest file;

2. Open the application debugging support;

For apps created through Eclipse, you can omit step 2, because debugging support for your app automatically opens when the Eclipse IDE launches the app.

Note: In the application development process, to manually enable debugging support in the manifest file, it is best to turn off debugging support before the app is released because a published app should not be able to be debugged.

3. Turn on the "USB debugging" feature on your phone.

4. Connect the computer to the phone with a USB cable, the first connection needs to install the mobile phone driver. You can choose to install locally, the Usb-driver folder in the Android SDK () to find the appropriate driver, if there are other drivers, also need to install, one can not be less, generally found in C:\WINDOWS\system32\drivers the corresponding files. After installation, you can use ADB devices to see if the device is recognized.


If the Usb_driver folder is not found in the Android SDK, this means that when installing the Android SDK, the Usb_driver package is not installed, you need to open the Android SDK Manager, find extras, and tick "Google USB Deriver "To install it. The driver package does not all support all devices at this time, it is necessary to download the official driver of the corresponding phone.

If it is a Mac OS x host, Plug and Play, omit this step.

If it is an Ubuntu Linux host, you will need to add a Udev rule file with USB settings for your development device. Each device vendor has a unique vendor ID (vendor ID) identifier, which is specified by setting the Attr{idvendor} attribute in the rule file.

1> run Lsusb view, as to which is you need, you can connect the phone to perform the LSUSB, unplug the phone and then perform the LSUSB, then the more out of that line, you want to connect the mobile device. If it looks like the following:

ID 15d9:0a37
Represents the ID of the USB device (this ID is set by the chip manufacturer and can uniquely represent the device)
15D9 Usb_device_descriptor.idvendor
0a37 usb_device_descriptor.idproduct

2> as root to edit the file/etc/udev/rules.d/51-android.rules, in the newly installed system, the default is not this file, you need to create it first.

sudo gedit/etc/udev/rules.d/51-android.rules

3> in the open 51-android.rules file, add the following line rule for each vendor:

subsystem== "USB", attr{idvendor}== "15d9", mode= "0666", group= "Plugdev"

Where the id "15d9" indicates that it is your mobile device; The value of mode indicates a read/write permission, and the group defines the owner user groups for the device node.

4> Execute command Enable rule:

sudo chmod a+r/etc/udev/rules.d/51-android.rules

The latest complete list of vendor IDs is available on the Android website (http://developer.android.com/tools/device.html#VendorIds).

5> Connect your phone to your PC and perform ADB device verification settings correctly.

If installed correctly, the device ID is displayed, otherwise it will be empty after execution.

Connect your computer to your phone and install your phone driver usb-driver

Related Article

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.