Reputation: 3988
I am using the Android plugin for Eclipse, and when I try to run my program using a real device through the Android Device Chooser, my phone is not listed as a device. I have updated Eclipse, all of the Android packages, and the USB driver, but it still isn't showing up. My phone is running Android 2.1, which is also the target version listed in the Eclipse project.
Also it happens that the device shows up as an unknown target and the serial number as question marks as shown in the screenshot.
Upvotes: 87
Views: 95156
Reputation: 12302
On Window Machine Just Install adbdriver. It will autometicall get competible drivers for the connected Android Device
.
I hope this will help everyone who is facing this issue.
Upvotes: 2
Reputation: 8124
Hope this solution will fix your mood this time!
Issue: My Android Device isn't recognized by the Eclipse ADT, why?
Cause: Device Driver was missing as it seemed at the end when I fixed it!
How to Fix:
Cheers!!!
Hope this helps to someone else to clearly get to the solution!
Upvotes: 1
Reputation: 2356
After adding file to udev
directory according to Yekmer Simsek, your /var/log/syslog
will be showing this in log, when you RE-plug your device:
Jul 3 16:18:10 jupiter kernel: [16866.411654] usb 2-1.2: USB disconnect, device number 7
Jul 3 16:18:15 jupiter kernel: [16871.221603] usb 2-1.2: new high-speed USB device number 8 using ehci-pci
Jul 3 16:18:15 jupiter kernel: [16871.315693] usb 2-1.2: New USB device found, idVendor=18d1, idProduct=d002
Jul 3 16:18:15 jupiter kernel: [16871.315704] usb 2-1.2: New USB device strings: Mfr=1, Product=2, SerialNumber=3
Jul 3 16:18:15 jupiter kernel: [16871.315710] usb 2-1.2: Product: Nexus 5
Jul 3 16:18:15 jupiter kernel: [16871.315715] usb 2-1.2: Manufacturer: LGE
Jul 3 16:18:15 jupiter kernel: [16871.315719] usb 2-1.2: SerialNumber: 0650f8e00ae573dc
Jul 3 16:18:15 jupiter mtp-probe: checking bus 2, device 8: "/sys/devices/pci0000:00/0000:00:1d.0/usb2/2-1/2-1.2"
Jul 3 16:18:15 jupiter mtp-probe: bus: 2, device: 8 was not an MTP device
Upvotes: 0
Reputation: 23344
The device was not showing up because of the following line in android manifest file---
<uses-sdk android:minSdkVersion="18"
android:targetSdkVersion="18"/>
I changed it to---
<uses-sdk android:minSdkVersion="8"
android:targetSdkVersion="19"/>
Now it worked.
Upvotes: 0
Reputation: 1384
Ensure Debug mode is turned on, as well as allowing installations from unknown locations, if the problem continues, unplugging the device, rebooting and plugging the device back in should work. Another common problem is not having USB drivers installed, to solve this go on to SDK Manager and in Extras, download/update USB drivers
Upvotes: 0
Reputation: 71
Check that your device connected as PTP device(Camera). Notification Bar -> USB Connection. If your device connected as MTP(as common data storage) then AndroidStudio don't recognize it as debuggable device. At least that works for me and my Nexus.
Upvotes: 3
Reputation: 5296
A ridiculous thing worked for me, I ran the app then when the device window opened up I swapped which port the cord to the device was plugged into on my mac and bam found the device! Good luck this stuff can be tricky
Upvotes: 0
Reputation: 3383
Did you try from your command line (assumed linux)
adb devices
If you got a lot of question marks
List of devices attached
?????????????? device
Check what is the vendor ID of your device:
lsusb
> Bus 003 Device 006: ID 04e8:689e Samsung Electronics Co., Ltd
Vendor ID is '04e8' in this case.
You need to add your device to USB list
sudo vim /etc/udev/rules.d/51-android.rules
and put this line (use your own vendor ID).
SUBSYSTEM=="usb", SYSFS{idVendor}=="04e8", MODE="0666"
Alternatively try the following syntax as pointed out by mcordaro and Yekmer Simsek referring to the documentation
SUBSYSTEM=="usb", ATTR{idVendor}=="04e8", MODE="0666", GROUP="plugdev"
save it, and then
sudo chmod a+r /etc/udev/rules.d/51-android.rules
sudo service udev reload
and it should work now.
Upvotes: 98
Reputation: 227
I updated my Motorola drivers for my Droid 3 at some point, and then ADB could not find the device. After reading this question and top answer and still didn't work, I tried removing the driver first. Then unplugging the device, then replugging it in, Windows found and loaded the correct drivers. Joy! Hope this help someone else.
Upvotes: 0
Reputation: 37
Sometimes adb stops running on my mac, a simple:
adb kill-server
adb start-server
and restarting adb debug on the device will reconnect it.
Upvotes: 0
Reputation: 2021
Install pdaNet(http://pdanet.co/a/) In between the installation if you get this message "Skip USB or something" in a pop up, close the pop up, unplug device then plug device, continue installation. Now eclipse should list your device :)
Upvotes: 0
Reputation: 3968
Unfortunately, the above solutions didn't work on my Samsung device Ace 2. But Installing Samsung Kies solve the problem
Upvotes: 0
Reputation: 1340
I have the same problem with xiaomi phone. Eclipse can detect all my other devices (including samsung and huawei).
Tried all the above and finally found the solution: just key in " ##717717## " and call and it will work!
Upvotes: 0
Reputation: 7346
Another thing you can try is looking for the USB drivers from the manufacturers website. Windows Update does not always include these drivers. My Acer Iconia a700 tablet would not show up in Eclipse until I downloaded and installed the drivers from Acer's website.
Upvotes: 0
Reputation: 2289
I had the same problem and after trying many of the solutions posted above finally tried changing the cable and it worked instantly.
Upvotes: 2
Reputation: 11
If you are using Eclipse, then see if Eclipse inadvertently converted your project to be a native java project. Do this by right clicking on your project name in eclipse and selecting the option "Convert to Android Project"
Upvotes: 0
Reputation: 2096
There is one thing some could not remember. Like myself, if you tried to run adb with superuser credentials following a run with regular user credentials, don't expect success. First, you have to kill adb which was run with lousy rights and start it again with sudo:
marek@deb42:~$ sudo adb kill-server
marek@deb42:~$ sudo adb devices
Upvotes: 7
Reputation: 57169
I just had the same issue with the Motorola Droid. I had 3 devices and only 1 was detected in the ADB. The one that worked showed up in device manager as "android adb composite interface" and the 2 that did not work showed up as "android adb interface". In Windows 7 I did the following.
If USB Composite Device doesn't show up then try browsing to the usb_driver folder in your android sdk directory for step 5 then try step 5 and 6 again.
Note : If Android does not appear at the top of this list as described in #2 and/or you find a device ADB with no drivers then you probably need to install the device driver, which in my case (HTC Glacier) was located right on my phone.
Upvotes: 88
Reputation: 28349
I figured it out, though it sounds like we have different problems. However, just in case this helps you.
First of all your manifest has to have the android:debuggable="true" attribute in the Application node. You probably have this, and I don't know if it actually contributes to the device showing up or not.
In any event, the thing I was doing wrong was when I run or debug my configuration (in Eclipse) under the target tab (where it lists your emulator device setups) I had the Automatic radio button checked. If you flip that to manual it then gives you another dialog when you hit Run, and in THAT dialog, on the top, I see my device.
Lastly, (and I only see this on the Droid X) when you are in PC mode the device doesn't act as though it's connected to the machine. When you're in Mass Storage mode, everything works as expected BUT then the SD card is disabled, so, if your app happens to WRITE to the SD card it will fail at that point in execution. The Captivate (my other test device) does not suffer from the same problem.
Upvotes: 3