Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Debugging an Android app to the phone

I've gone through the page Using Hardware Devices. My manifest has

<application android:icon="@drawable/icon" 
    android:label="@string/app_name"
    android:debuggable="true">

My phone has Menu -> Settings -> Applications -> Development -> USB Debugging checked.

I have gone to the control panel on my Windows XP 64 bit installation and installed the USB drivers given to me by the SDK installer in android-sdk_r05-windows\android-sdk-windows\usb_driver. So my computer does recognize the Android device.

However.. when I run an app on Eclipse, it still insists on opening it up in an emulator rather than my phone. How can I fix that?

like image 734
tipu Avatar asked May 11 '10 16:05

tipu


1 Answers

I just picked up Android development again, and this is what worked for me using HTC Hero (2.1 update 1) on Eclipse (v. 3.6 (Helios), Service Release 1):

  • Start up Eclipse
  • Connect the phone
  • Ensure USB debugging is enabled
  • Set phone connection type to HTC sync, as opposed to charge only, etc.
    (You don't have to sync, but it need to be in this mode. A message will then be displayed in the task bar saying USB debugging is connected or something similar. Then follow AlexVolovoy's instructions (Right click on the Eclipse project -> Run As -> Run Configuration -> Target - Choose manual) and you should be good to go. Just remember to pick your phone from the list of targets.
like image 134
Hartigan Avatar answered Sep 22 '22 08:09

Hartigan