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.