Linux (ubuntu12.04) mobile phone real-World debugging Android program on eclipse

Source: Internet
Author: User

simulator is too slow, and the effect of running the program on the emulator is still a bit different from the real machine, so we recommend that you try to use the real machine debugging. Connect your Android phone to your computer via a USB cable, followed by the following steps:

1. Create a new 51-android.rules file in the/etc/udev/rules.d/directory with the following file contents:

    SUBSYSTEM = = "USB", env{devtype} = = "Usb_device", MODE = "0666"


2.$ sudo chmod a+rx/etc/udev/rules.d/50-android.rules

3.$ Sudo/etc/init.d/udev Restart


4. Access the tools directory of the Android SDK Platform-tools run

$ sudo./adb kill-server
$ sudo./adb start-server


5.$ sudo adb devices

You should be able to see the device model you are connected to. If the device name is displayed as "??????? "That's probably the problem with your 51-android.rules file." Repeating the previous sections should be OK.

6. Open Eclipse and run your program to see the results of the run on your Android phone.

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.