How to debug Android apps on a real machine (graphic)

Source: Internet
Author: User
Tags server port

1, first set the phone as the debug mode method: Set--application--Development--usb debugging, play √ 2, connect to the computer with the data cable, install Pea pod on the computer, the Pea pod will help you install the driver, install the Pea pod can connect on the mobile phone 3, Test if there is an appliance connected command with the ADB command: ADB devices See there is already a device, that is, a real machine for our connection note: Some people may be prompted not to find this adb command, because you did not add it to the PATH environment variable,  Or you can enter the tools directory under the SDK to run this command without error, or add the tools path to the environment variable, of course, the second method is recommended that sometimes the following error may occur: ADB server is an out of date.  Killing ... ADB server didn ' t ACK *
Failed to start daemon * The source is ADB server did not start

Check it out on the StackOverflow. Analyzed and collated as follows:

Original ADB server port binding failed

Continue to see which program is taking up

C:\users\xxxxxx>netstat-ano | Findstr "5037"        tcp    127.0.0.1:5037         0.0.0.0:0              LISTENING       4236        tcp    127.0.0.1:5037         127.0.0.1:49422        established     4236        TCP    127.0.0.1:49422        127.0.0.1:5037         established     3840  

Open Task Manager to kill this process with PID 4236. OK, so this problem is solved

4. Start debugging on the real machine select Run--run configurations in Eclipse, select the project you want to debug on the left, then switch right to the Target tab, which has three options, if you want to connect to the real machine debug, choose the first or second one, Here I directly select the first, click Run, wait a few seconds to appear the following interface here to see our real machine device, select the above real machine OK to run the program on the real machine

How to debug Android apps on a real machine (graphic)

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.