Share an android debug mode. When waiting for debugger occurs, it will shut down and use a clever solution, androiddebugger.

Source: Internet
Author: User

Share an android debug mode. When waiting for debugger occurs, it will shut down and use a clever solution, androiddebugger.

When android studio is used to develop programs, sometimes the waiting for debugger gets stuck on the interface and the software cannot run properly. Many netizens have shared some solutions, such:

1. Open cmd and enter the command line. In the directory where adb is located, run adb kill-server and adb start-server successively.

2. Open cmd and go to the command line. Enter netstat-ano | findstr "5037", find the PID of adb.exe and Android Studio, and delete it.

3. Restart your computer and phone.

However, I have used the above methods and have not solved the problem of waiting for debugger getting stuck on the interface. Instead of using the debug mode, I compile the app using the run method (see figure 1 ), after the app starts normally, select Attach debugger to Android process (see figure 2). the android studio will pop up a form containing the app package name (3), and click OK, breakpoint debugging is also possible. for more information, see Figure 4.

 

,

Figure 1 Figure 2

Figure 3 Figure 4

 

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.