I am trying to debug my application using a real device instead on the emulator. When I try to connect, it gives me the message:
USB device not found
I tried to unplug and plug it again, but it did not work. And I have also enabled USB debugging and unknown sources options in my device.
Any help is appreciated!
Thanks!
I had this problem with a Nexus 7 - it appeared in Device Manager fine but wasn't recognised by Android Studio. The device had USB debugging turned on. Eventually I noticed an icon in the top left hand corner that said "Connected as a media device. Touch for other USB options." When I selected this I was able to change from Media Device (MTP) to Camera (PTP) and then it started working.
If you are on windows, many times it will not recognize the device fully and because of driver issues, the device won't show up.
go to settings
control panel
hardware and sound
device manager
And look for any devices showing an error.
Many androids will show as an unknown USB device.
Select that device and try to update the drivers for it.
This solution works for every unrecognized android device... mostly general brands don´t come with usb debugging drivers...
go to settings
control panel
hardware and sound
device manager
And look for any devices showing an error. Many androids will show as
an unknown USB device or just Android
First thing you need will be your device IDs. You can get them opening up the device manager and finding the "Unknown Device" with a yellow exclamation point. Right click on it and select 'Properties', and then go to the 'Details' tab. Under the 'Property' drop down menu, select hardware IDs. There should be two strings:
USB\VID_2207&PID_0011&REV_0222&MI_01
USB\VID_2207&PID_0011&MI_01
Copy those strings somewhere and then navigate to where you downloaded the Google USB driver. Then you need to open up the file 'android_winusb.inf' in a text editor. I would recommend using Notepad++.
First, create a sub-section for your device. I called mine ';RCA 6378W2' but it doesn't really matter what you call it. Then, under the sub-section you created paste the Device ID strings you copied from the Device Manager, preceded by '%SingleAdbInterface%'. If you need help, look at this screenshot.
NOTE:
If you are using Windows 8 or 8.1, you will need to disable device driver signature checks before you'll be able to install the modified driver. Here's a quick video on how to disable device driver checks http://www.youtube.com/watch?v=NM1MN8QZhnk. Ignore the part at the beginning about 64 bit, your computer architecture doesn't matter.
Please look at this article, for more information and MacOS instructions.
Try a different cable, ideally an official Samsung one.
I had tried a crappy USB cable I had lying around and then tried another which was Samsung and works perfectly now.
Not sure why they would be different though but worked for me.
Found out for Samsung, Installing Kies also update the usb driver which solve my problem with connecting my Samsung Galaxy S Advance with Android 4.1.2 to Android Studio on Windows 7 64bit.
In this case the devise manager shows device driver is updated and working, but when I connect my phone Android Studio does not recognize my device.
I had the same problem with connecting my Galaxy Nexus to win7 x64. I solved it by getting drivers, they can be downloaded from here or also via Android SDK manager.
After you put your phone on developer mode, restart it. That worked for me, maybe it will work for you also. After restarting it, the phone was recognized, drivers were automatically installed. Note - I'm running on Windows 7.
I've been having this issue on Mac OSX Mavericks using Android Studio, using my Samsung Galaxy Express , I did a little trick, Run -> Edit Configurations - > Run -> Show chooser dialog. When I "play" and the dialog appeared, I connected my device and it did appear. ;)
You need to install the driver first. Follow the instructions on the Android's developers website:
http://developer.android.com/tools/extras/oem-usb.html
I had the same problem with a Samsung galaxy note 2. It was recognized on one pc but not on another one (both running windows 7 64b). After hours of struggling, I installed Kies (from the Samsung website) on the pc where Android Studio was unable to detect the smartphone (Kies was installed on the other one).
Like magic, Android Studio detected the phone !!! I noticed that the Kies installer installed some driver for the phone.
Consequently, for those meeting the same detection problem, I would strongly advise to first install Kies.
Galaxy S7, I had to go to Settings, Developer Options and allow USB Debugging. This asked to approve computer it was attached to and it showed up instantly.
I had tried restart the device, and it's work, popup and ask want to trust the mac for debug mode.
I am using Samung S8, I tried to install:
Intel Android Driver
Samsung USB driver
But the adb bridge driver was still missing.
I finally got it to work by installing the Samsung Smart Switch application which is a media manager application.
Updated at 2018-04-20: If you are struggle with the driver, just use http://adbdriver.com/downloads/
If you're using a USB Type-C cable, check if it has the charging and data transfer capability. Many USB Type-C cables are for charging only, and are not recognized by Android Studio.
Check installed drivers. If drivers ok, check device usb-port it could be damaged.
I have a Samsung Galaxy S4. Although visible from Devices, my phone was not listed as connected from Android Studio. I tried a few things independently, and then together, and found that only a combination of steps fixed the issue, so this is for you if measures listed above or on another site did not work on their own.
Enable USB debugging from "Developer Options"
Download Kies from Samsung. I believe Samsung US has replaced Kies with a new software called Smart Switch, but this did not resolve anything for me. I found a Samsung UK download of Kies that worked fine.
After connecting your phone to your PC via USB, go to your phone notifications and click on USB settings at the top. Switch it to Camera mode.
I repeat, only all 3 of these together fixed the issue, so if some fixes you have tried haven't worked, use these 3 and it could fix the problem for you. Best of luck.
Restart Android Studio Worked in my case
For me, this simple trick worked:
I actually enabled and disabled the listed USB Adapter for android in the device manager (Control Panel -> Hardware & Sound -> Device Manager). And holy moly it's working! :D
The solution for me was following the instructions at https://developer.android.com/studio/run/oem-usb.html#InstallingDriver. Specifically, the key part from that link that helped me to find the solution was this: "Install a USB Driver. First, find the appropriate driver for your device from the OEM drivers table below." This means that you cannot find a single link that applies to everyone as the solution. It will depend on your device! "So I visited the page to get OEM Drivers at https://developer.android.com/studio/run/oem-usb.html#Drivers. In my case, the device I was using was an LG K8 LTE. I had to go to http://www.lg.com/us/support/software-firmware-drivers#, Browse by product and I found the driver I needed under the Model Number "LGAS375 KG K8 ACG - AS375", Cell Phone Product. From http://www.lg.com/us/support-mobile/lg-LGAS375 I used the "Install the USB DRIVER" for Windows (http://tool.lime.gdms.lge.com/dn/downloader.dev?fileKey=UW00120120425).
Depending on the device model you are using, you will need to find the specific drivers that work for your phone, and that should work.
How to get connection to device working using adb command line:
USB debugging enabled on phone and phone connected.
I am exercising these commands on linux(redhat and ubuntu) but same commands work under the hood on windows. The device manager runs adb commands. You can find a console in your device manager or regular command-line works if you set up your paths to SDK.
If you can run adb and see something like ???????? in devices list ..
$ android-studio/sdk/platform-tools/adb devices
List of devices attached
???????????? no permissions
You might be running the adb server as a regular user.
You might have to run the adb server as root.
So kill the server as regular user and start it as root.
$ adb kill-server
$ which adb
$ sudo <fullpath>/android-studio/sdk/platform-tools/adb start-server
Now look at adb devices list, if it is first time this machine connects to this phone you will see "unauthorized".
$ adb devices
List of devices attached
MWS0216A31xxxxxx unauthorized
At this point on phone you should have dialog popped up and you can tap ok to authorize. Then you should see "device" in the devices list and commands like shell/push/pull/sync/backup... should work.
$ adb devices
List of devices attached
MWS0216A31xxxxxx device
$ adb shell "uname -a; df; ls /storage/sdcard0/Download"
Linux localhost 3.10.90-g2ff1b22 #1 SMP PREEMPT Tue Dec 27 17:12:50 CST 2016 aarch64
Filesystem Size Used Free Blksize
/dev 1.3G 108.0K 1.3G 4096
/sys/fs/cgroup 1.3G 12.0K 1.3G 4096
/mnt 1.3G 0.0K 1.3G 4096
/sys/fs/cgroup/pids: Permission denied
/system 2.4G 2.3G 106.8M 4096
/cust 492.0M 327.7M 164.3M 4096
/cache 248.0M 160.0K 247.8M 4096
/splash2: Permission denied
/3rdmodem 59.0M 4.9M 54.1M 1024
/3rdmodemnvm: Permission denied
. .
/storage 1.3G 0.0K 1.3G 4096
/data 25.1G 10.9G 14.2G 4096
/mnt/runtime/default/emulated: Permission denied
/storage/emulated 25.1G 11.2G 13.8G 4096
/mnt/runtime/read/emulated: Permission denied
/mnt/runtime/write/emulated: Permission denied
.
.
Lovely jubly. Hopefully.
For example:
My file path:
C:\...\sdk\extras\google\usb_driver\android_winusb.inf
My data to paste:
;Tablet PC
%SingleAdbInterface% = USB_Install, USB\VID_18D1&PID_0003&MI_01
%CompositeADBInterface% = USB_Install, USB\VID_18D1&PID_0003&REV_0230&MI_01
Well, in my case updating drivers, restarting Android Studio, restarting my phone, changing the USB mode or unplugging USB did not help.
Then I went to the dev settings in my phone, toggled the Dev. Mode off and back on, and it worked. AS was open and phone was plugged at the moment.
I had this problem occurring suddenly in Dell Ubuntu linux machine with Android Developer Studio. I did the following steps
1. I opened "System Settings"
2. Select the listed item "Software and Updates"
3. Click on the tab "Additional Drivers"
4. There was a mention about "Dell Inc: Unknown" and the option "Do not use use the device" selected. I selected the alternate driver mentioned and did an "Apply the Changes".
It started working.
I just ran adb command prompt and hit 'adb devices' and it showed daemon was not running. It installed itself and now i can able to see android devices there.
C:\...\...\source\repos\ABC\ABC\Ex.Android>adb devices
List of devices attached
* daemon not running; starting now at tcp:5037
* daemon started successfully
ZF22Q3T unauthorized
and Reload the project
Windows, many times it will not recognize the device fully and because of driver issues, the device won't show up.
1).go to settings
2).control panel
3).hardware and sound
4).device manager
Restarted my PC and worked in my case.
Related
My Android device isn't recognized by eclipse nor adb anymore.
My OS is Windows 7 64-bit, and I'm using a Nexus 4 with Stock Android 4.4.2.
Here are some details on the problem:
Yesterday I could run Android Projects from eclipse on my device with no problems. The only thing that I did on eclipse, which could have caused this problem, was installing the v7 appcompat support library from a resource to eclipse using this guide on developers.android (https://developer.android.com/tools/support-library/setup.html).
The device is still recognized as a normal multimedia drive in Windows when it's not in debug mode.
The device is in Developers mode and in Debug mode when I try to run an Android Project in eclipse or try to see if it's recognized by adb using adb devices in the console.
The Google USB drivers have been installed through the ADK Manager
The USB OEM drivers for Windows have already been installed according to the tutorial on the android-developers site (see: https://developer.android.com/tools/extras/oem-usb.html)
I tried to restart adb by using the commands adb kill-server and adb start-server, and again checked if the devices was recognized by using adb devices. The device was still not listed on the console.
Restarting windows & eclipse did not fix this problem.
What's the solution to this problem?
UPDATE: Thanks for the replies, the problem is solved (for now).
I tried the following suggestions in this order:
I restarted my device - this did not fix the problem
I set my device to PTP mode - this fixed the problem.
So I reset my device to MTP mode & debug mode again to check if it still would be recognised by adb for some reason. It definitly doesn't get recognised by adb when it's in MTP-mode. I don't know how it got recognised some days ago, because I never setmy device to PTP-mode. Anyway, the solution to my problem is that my Nexus 4 must be in PTP-Mode and of course in debug-mode to get recognised by adb.
I didn't try any other suggestions since my problem got solved with my current drivers.
Generally, I think your USB connection should be set to use MTP (Media Transfer), however, I couldn't get my computer to recognize my device (Nexus 4). Oddly, setting the USB connection to Camera got it working for me.
I recently had this issue (but before that debug over wifi was working fine) and since none of the above answers helped me let me share what I did.
Go to developer options
Find Select USB configurations and click it
Choose MTP (Media Transfer Protocol)
Note: If it's set to this option chose another option such as PTP first then set it to MTP again.
UPDATE:
PTP stands for “Picture Transfer Protocol.” When Android uses this protocol, it appears to the computer as a digital camera.
MTP is actually based on PTP, but adds more features, or “extensions.” PTP works similarly to MTP and is commonly used by digital cameras.
I also faced the same problem and tried almost everything possible from manually installing drivers to editing the winusb.inf file. But nothing worked for me.
Actually, the solution is quite simple. Its always there but we tend to miss it.
Prerequisites
Download the latest Android SDK and the latest drivers from here. Enable USB debugging and open Device Manager and keep it opened.
Steps
1) Connect your device and see if it is detected under "Android Devices" section. If it does, then its OK, otherwise, check the "Other devices" section and install the driver manually.
2) Be sure to check "Android Composite ADB Interface". This is the interface Android needs for ADB to work.
3) Go to "[SDK]/platform-tools", Shift-click there and open Command Prompt and type "adb devices" and see if your device is listed there with an unique ID.
4) If yes, then ADB have been successfully detected at this point. Next, write "adb reboot bootloader" to open the bootloader. At this point check Device Manager under "Android Devices", you will find "Android Bootlaoder Interface". Its not much important to us actually.
5) Next, using the volume down keys, move to "Recovery Mode".
6) THIS IS IMPORTANT - At this point, check the Device Manger under "Android Devices". If you do not see anything under this section or this section at all, then we need to manually install it.
7) Check the "Other devices" section and find your device listed there. Right click -> Update drivers -"Browse my computer..." -> "Let me pick from a list..." and select "ADB Composite Interface".
8) Now you can see your device listed under "Android Devices" even inside the Recovery.
9) Write "adb devices" at this point and you will see your device listed with the same ID.
10) Now, just write "adb sideload [update].zip" and your are done.
Hope this helps.
It may sound silly but in my case the USB cable was too long (even if good quality). It worked with my tablet but not with the phone.
To check this, if you run on Linux run lsusb to make sure that your device is at least officially connect to the usb port.
Try use PdaNet. you can download it from here
It installs missing drivers when you plugin your device.
Obviously make sure you "debug usb" option in "developers options" is on.
Another thing, it's important to uninstall any device's installed driver before using it.
Fundamentally, the issue has to do with not being able to get MTP+ADB working while for example PTP+ADB may work. In my case when I plugged Nexus 5, windows 7 will install only MTP driver completely ignoring ADB. I couldn't find a good solution for this problem anywhere else so here I provide steps (some of the steps I copied from other sources):
0) Unplug Nexus 5. Make sure you selected MTP and ADB.
1) Make sure that sdk\extras\google\usb_driverandroid_winusb.inf in Google SDK had the following lines (in two places in that file):
;Google Nexus (generic)
%CompositeAdbInterface% = USB_Install, USB\VID_18D1&PID_4EE2&MI_01
NOTE: VID_18D1 is Google VID, PID_4EE2 is PID for MTP+ADB, MI_01 means that ADB is on interface 1 (MTP is on interface 0).
You can check what is on what interface by plugging Nexus 5 into a Linux system and typing lsusb.
2) first delete all installed Google USB drivers. One good tool is called USBDeview and can be find at the following location:
http://www.nirsoft.net/utils/usb_devices_view.html
Download the tool and run it (there is no need to install it). Take a look at the colored status indicator on the far-left of the USBDeview window. Green indicates the the device functions properly. Pink means the device can unplug and works properly (although it may not actually work properly). Red indicates a disabled USB device. Gray (circled, below) means the device is installed, but not connected.
Second, remove all gray items with the words “Google”, “Linux”, “ADB”, or “Android” in the title.
3) Now delete old cached Google *.inf files. Open a Windows Explorer and navigate to the C:\Windows\INF directory. Somewhere in there there is an "oemN.inf" file (where N is a number that will vary on your system) that is a copy of the android_usb.inf -- the thing to do is to find which file and remove it. Windows keeps a cache of the INF files here and what we found is that sometimes an older cached copy is used instead of a newer version.
One simple way to find which one using the Windows Explorer:
- In the explorer's Search box, enter "androidwinusb86.cat" without the quotes.
- Typically the search will be empty because no filename has this pattern.
- Go to Tools/Folder Options, click Search Tab and click Always search file name and contents. Click Apply
- Search again. This time it should list a few files such as "oem90.inf" (you'll have one or more, with different numbers).
Now use the Windows Explorer and delete the "oemNN.*" files that matched above (only those with androidwinusb in them.).
4) We now want to disable installation of MTP by windows before windows discovers ADB. Now search for wpdmtp.* files in the same directory. Presence of these files will force install MTP disregarding ADB class in the same (composite) device. Move these files out of \inf folder
5) plug in the device again. This time, both MTP and Android ADB driver installation will fail.
6) Find Other devices in the Device Manager and when expanded it should show Nexus 5 and MTP. Right click and update Nexus 5 by navigating to the sdk\extras\google\usb_driver\android_winusb.inf.
Move wpdmtp.* files back to \inf folder. Right click MTP device and update.
7) If necessary, confirm on your Nexus 5 that this PC has access to the phone.
8) If everything went as expected you should see in Device Manager the following:
Expand Android Device. Right click Android Composite ADB Interface, select Properties, choose tab Details, under Property select Hardware Ids. You should see USB\VID_18D1&PID_4EE2&MI_01
Expand Portable devices. Right click Nexus 5, select Properties, choose tab Details, under Property select Hardware Ids. You should see USB\VID_18D1&PID_4EE2&MI_00
With USB connected, on android device Settings > Developer options > Revoke USB debug authorizations USB Debug. Remove the USB and connect again, then "Allow USB debugging".
For those people to whom none of the answers worked, try closing the chrome://inspect/#devices tab in Chrome if it is open. This worked for me.
Go to prompt command and type "adb devices". If it is empty, then make sure you allowed for "MTP Transfer" or similar and you enabled debugging on your phone.
To enable debugging, follow this tutorial:
https://www.kingoapp.com/root-tutorials/how-to-enable-usb-debugging-mode-on-android.htm
Then type "adb devices" again. If a device is listed in there, then it should work now.
Set your environmental variable Path to point to where the adb application is at: [directory of sdk folder]\platform-tools
Enabling Developer mode by tapping on Build Number 7 times worked for me.
Make sure you are connecting with a USB and not a lightning cable. I had this problem trying to connect using a cord with lightning cables on both ends and it would not list the device. But switching to a USB to lightning cable worked.
Check that the USB cable is indeed capable of transferring data. Some cheaper ones, especially those meant to charge non-phone/computer devices, might only support charging.
You can verify this by checking if the device shows up as mountable file system. In Linux, you can also use the command lsusb to check if it's being detected.
Find drivers for your device and install them
That will be the end of your device not detected problems
Windows have driver problems, sometimes messed by overriding the existing driver
You can also try uninstalling driver from Win7 and reinstalling
For those facing problem after upgrading their android device to android 10, same PTP Mode option will work as prescribed by user3135185
I tried all these, but nothing worked. Finally, I changed my old data connection USB-c cable, to a new one. Maybe with updates of windows/android studio, the older USB-c protocols are no longer recognized for transfer.
Download and install Moborobo software on your computer.
Connect your device with USB debugging through USB cable.
Now open moborobo and it will connect to your android.
Stay connected, now your device should recognize as adb devices and get
listed.
Android Studio 0.3.6
Fedora 18 3.11.7-100.fc18.x86_64
Nexus 5 Kitkat
Hello,
I have been using my Samsung Galaxy Tab 3 7.0 running Android 4.1.2 everything works fine with adb.
However, I have just bought a new Nexus 5 device, and when I do the following command adb devices it doesn't show my Nexus 5.
Under Android SDK Manager | Extras | Google USB Driver | status "Not compatiable with Linux"
Because I am running Fedora 18 if I need drivers what drivers for the USB do I need?
Because the Samsung works fine and I can deploy and run my apps, I think my setup is correct. So I am wondering if there is something wrong with my Nexus 5.
I have tried the following:
adb kill-server
adb start-server
Setting the Nexus 5 Camera PTP and media device MTP didn't work.
Many thanks for any suggestions,
I had a similar problem with my Nexus 4(Android version 4.4.2), it wasn't listed in adb devices.
Make sure USB debugging is enabled from device, and do the following on your PC:
Update Android SDK (Google USB Driver)
From PC Control Panel, System -> Device manager -> Right click Nexus 4 -> Update driver.
Set android-sdk-folder\extras\google\usb_driver as path to search, include subfolders checked.
If windows tells you that the driver is up to date, just uninstall the driver (right click on nexu4 -> uninstall driver) and start from step 2 again.
After that, open a cmd and type adb kill-server and then a adb devices, now it will include your device.
https://developer.android.com/studio/run/oem-usb.html
Follow these steps,
Enable Developer options in your device. To enable the developer mode, Settings->About phone, tap Build number option 7 times continuously
Go to Settings-> Developer options and Turn on USB debugging
Make sure you reconnected the device via USB and grant permission on the dialog that appears.
From the above steps it didn't work try this step, Go to Settings->Security and turn on Unknown Sources
What you need to do is this:
Settings | About Phone
Scroll to the bottom to build number.
Tap on build number about 7 times. Each time you will get a popup message saying you are x steps away from being a developer
When you get to the final step you will get a message saying now you are a developer
Go back into settings and you will see a new setting Developer options there you will see a lot of options for developers. Enable USB debugging
Re-connect you phone to the usb, and you should see you device under adb devices.
I hope this answer helps someone else.
This simple steps worked for me, I debug on my Nexus 5 and 5X devices on Windows 8.1.
The steps to follow are these:
1) Enable from Developers Options the Debug USB Mode
2) Unplug the device from the computer
3.1) Go to Settings → Storage, in the ActionBar, click the option menu and choose USB computer connection.
3.2) If you didn't find the 3.1) option then go to Settings → Developers Options → Select USB Configuration.
4) Select Camera (PTP) connection.
5) Plug the device and you should have a popup on the device allowing you to accept the computer's incoming connection, or something like that.
6) If it doesn't work try to toggle the Debug USB Mode in the Developers Options
Finally, you should see it now in the DDMS and voilà.
My windows solution:
Go here and download and unzip to an easy location:
http://developer.android.com/sdk/win-usb.html#top
Right click 'My Computer' or 'Computer'
Select properties
Select Device manager
Look for your device. It should have a yellow mark above it.
Click 'update driver software'.
select browse my computer for driver software.
select the usb_driver folder you saved earlier.
install it
and wala. magic.
For those who are still frustrated, if you are using the experimental ART runtime, try switching back to dalvik (in developer options on device)
Here is simple solution for Windows 7 and Nexus 5 on Android 5.
Download the Nexus 5 Drivers from http://androidhost.org/jelry
Extract the zip contents and place all files in a single folder on your desktop.
Connect your device to your computer.
Launch the Device Manager on your PC.
Now you should see the Nexus 5 listed in the hardware list.
Right-click the ‘Nexus 5′ line and then click on Update Driver Software.
Next, click the ‘browse my computer’ option.
In the new window click on ‘Browse…’ button.
Go to folder unzipped at step 2. Select the folder where you extract the USB Drivers. Click Next. – make sure to tick the subfolder box too.
Now, the Windows installer will search for Nexus 5 drivers, click Install when asked for permission.
Wait for the process to complete and then check the Device Manager list to confirm that the installation was successful.
Original: http://www.android.gs/download-and-install-google-nexus-5-usb-drivers-adb-fastboot/
Note: do not forget to enable USB debugging on your device :)
Something nobody has mentioned yet:
Some cables do NOT support data. I was sitting here wondering why my Nexus 5 was refusing to show up on OSX. It turned out I was using a cable that didn't support data.
I swapped to a different cable which did support it, and suddenly I was able to use USB debugging.
If anyone is trying to connect Nexus 5 to a formatted Windows XP then follow these steps:
Download and install media transfer protocol porting kit:
MTP porting kit
Download and install WMFDistributable-11 for XP:
WMFDist-11 XP
Download and install LG United Mobile Driver v3.10.1:
stackoverflow is not allowing to share more than 2 links, please google this.
Connect your device.
Go to Device Management
Right click on Nexus 5 and click Update Driver
Select Yes this time only
Select Install Software Automatically
Wait for sometime.. and enjoy transferring files
ADB and driver versions matter. The newer the device, the lower the chances of an older version ADB to work correctly.
Apps using their own ADB copy need to be updated or at least have their ADB updated manually.
When installing Helium / Carbon for instance, it uses an old / incomplete ADB. Newer devices might not link to the ADB server for this very reason.
What I'm writing here should work for any future devices on Windows and possibly *nix OSes.
First the systems must be prepared.
on Android:
activate developer mode, either from an app (like Helium, when prompted) or by accessing the about phone section, taping build number until the developer mode unlocks
in developer settings enable USB debugging
in security settings allow unknown sources
(when connected with USB cable) set USB connectivity to PTP mode (camera device, if so labeled)
in Windows:
uninstall older USB driver (with file removal) if there is one, but only when the device is connected and in developer mode, otherwise
that particular device won't be listed
install latest USB driver after the device has been plugged in and developer mode is active, the device will be listed as unknown or other in Device Manager; the drivers can be downloaded separately from Google Android support site, these are the same as vendor drivers, with only fewer ID's in inf file making the driver not being recognized for all Android devices
if the driver does not recognise the device, no problem, install it generically: Manual Install > Show All Devices > Have Disk > pick inf location of the Android USB driver and from the list select Android ADB Interface; there's not need to edit the inf by adding hardware ids, the end result is the same
each of the modes, PTP and MTP will have their own driver entry, so if the device asks for MTP, the same driver installation procedure must be followed, again
Once these steps are/were previously done correctly, adb must be tested.
If Android SDK was installed previously, open a command prompt where adb.exe is
and test the listing of the device.
adb start-server
IMPORTANT NOTE: This command will prompt the device to allow the communication between the computer it's been linked to on the first run. The prompt will also list an RSA key specific to the PC in question. Without this prompt on start-server, ADB will NOT work! Nor will any application relying on ADB.
adb devices
Must list the device(s). If the list is empty, and most likely the RSA prompt did not occur, then no communication will work. If the list is empty the current ADB (and SDK) must be updated or installed fresh (in the case of apps bringing in their own ADB runtime, like Helium / Carbon).
In the case of applications that do bring their own ADB, if the version is old, and these apps insist in using it instead of the SDK one, these files need to be replaced with the latest ones from Android SDK. Plain and simple copy & paste.
As for Android SDK, the only required packages to be installed are SDK Tools and Platform-tools. There, ADB.exe will need some support libraries, on Windows these files are AdbWinApi.dll and AdbWinUsbApi.dll. After all is done, the SDK can be uninstalled from SDK Manager while being able to retain the ADB tool if this is the only runtime used, depending on the case in question.
After doing all steps like enable debug, ... I had to put a sim card and reboot the phone
Solution for Windows 7 and Nexus 5 (should be applicable for any Nexus device):
I figured out that my system was installing the Nexus 5 default driver for windows automatically the moment I was connecting my Nexus 5 to my system through USB. So uninstalling the default driver was in vain and it gets installed automatically anyways.Moreover if you uninstall the default driver, you won't be able to locate Nexus 5 under Devices in Computer Management. So here is what i did and worked for me!
Computer-->right Click-->Manage-->Device Manager-->Portable Device-->Nexus 5-->Update Driver Software
Choose 'Browse my computer for driver software'
1.Make sure to give this location: %APPDATA%\Local\Android\sdk\extras\google\usb_driver
Click Next and you are done.
I have suffered the same issue and was able to solve it by simply changing on my Android device (Nexus 5X) in Developer options > Select USB Configuration to RNDIS (USB Ethernet)
For those trying to connect their android phone in adb with no luck and have tried every USB configuration (MTP, PTP, RNDIS). It is worthing noting that in my case with my Nexus 5X on Windows 7 I successfully connected the phone to adb only by choosing the Charging USB Configuration. With any other configuration (MTP, PTP, ...) it doesn't work.
USB Driver: Google USB Driver v11
ADB Version: Android Debug Bridge version 1.0.39
Madx's answer is a strong hint. Now I can make MTP work for my Ubuntu 20 and Nexus 5X (Android 8) device. MTP is an easy solution in Windows for smartphone users. However, to me and many Ubuntu/Linux users, current Ubuntu/Linux MTP tools "LOOK" messy and unstable for Android devices, e.g. No folder is shown for android phone in Nautilus.
Delving deeper I find it might be a security enhancement done by GOOGLE in the Android device/phone side. Direct internal data access remains a privilege for the developers. And one needs to set/reset MTP as a developer for Android device in order to make Ubuntu MTP tools work. There is nothing wrong with Ubuntu/Linux MTP tools.
The steps for MTP data access are an extension to Madx's answer:
(For Android device) Enable from Developers Options the Debug USB Mode.
Unplug the device from the computer.
3.1) Go to Settings → Storage, in the ActionBar, click the option menu and choose USB computer connection.
3.2) If you didn't find the 3.1) option then go to Settings → Developers Options → Select USB Configuration.
4.1) Select MTP connection.
4.2) Select Camera (PTP) connection.
4.3) Select MTP connection again. (This refreshs GOOGLE MTP protocol stack, I guess)
Plug the device and you should have a popup on the device allowing you to accept the computer's incoming connection, or something like that.
If it doesn't work try to toggle the Debug USB Mode in the Developers Options
And now file folders are shown up for N5X device in Nautilus.
Are these too much? There might be a bug in Android MTP implementation, and 4.2) & 4.3) are steps to WAKE Up Android MTP stack:-)
As a kind reminder, Windows and FTP are the last resorts for MTP.
Try executing :
sudo ./adb kill-server
sudo ./adb start-server
sudo ./adb devices
In my case:
The phone was connected as a media device.
Clicked on that message and got a menu. "USB computer connection"
In that menu chose to connect it as a camera (for devices that do not support MTP)
And then it worked.
Oh boy, I spent 3 hours for this simple thing and tried combination of above instructions.If it doesnt work for you, just try several combinations of above instructions and it will. I am on windows 7 and nexus 5. Issue I had was when I try to install driver from the google usb folder, windows 7 fails to install. Here are my steps:
-first uninstall all nexus drivers on windows 7. connect with USB cable, go to device manager and uninstall the driver; unplug the cable and repeat until no drivers are found and nexus shows up under "other devices" in device manager. I also configured nexus device as camera (PTP)
-follow #Dharani Kumar instructions. They make appropriate configuration changes for nexus device
-follow #Harshit Rathi instructions. They will ensure eclipse can show the device when windows detects the device
-unplug and replug the USB cable after a minute. Now you should see a pop up on nexus device. click it so that windows 7 will allow installing the driver from your local system. if you dont see this, restart your device or pc
-follow #Rick's instructions.you can download USB driver as listed by #jimbob
If you still have a problem, re read this entire thread and go from there (I spent hours on other web sites; those bits and pieces didnt help)
Go here and download and unzip to an easy location:
http://developer.android.com/sdk/win-usb.html#top
Download and install
I had the same problem, USB debugging enabled, device showing up in windows but I never got the question about RSA fingerprint when I connected my Nexus (6) device, nor did it show up in the Android Device Manager.
BUT
In the windows device manager I did have an entry saying it was an android device and Composite ADB interface etc. Still didn't work.
When I tried the previous tips about manually updating the drivers, Windows 8.1 just responded that "Windows has determined that the driver software for your device is up to date" this was not true. Looking at the driver details I saw that the driver was published by "ClockworkMod". I realized this must be because I had installed the Helium app sometime last year. So I uninstalled that, still had the same problem. Checked again, this time it was indeed google drivers, but version 7 published in 2012 (and not version 11 published 2014). I uninstalled these AS WELL and then tried the trick of reinstalling the driver from the SDK located in:
%localappdata%\Android\sdk\extras\google\usb_driver
Now when I replugged my device it finally works and can be debugged with Android Studio.
Indeed a driver problem.
Answer by Rick and MadX is the right way to do the steps (Thumbs Up for the answer)
In my case I am using
Akcess USB Type C Data Sync Cable For Nexus 5x, 5P - White
As Nexus 5x do not supply type C to usb cable I purchased it from some vendor.
Having the same issue. What I am doing stupidly is:-
I am connecting the cable in wrong way. After I reconnect it from upside down its working for me.
I might think that some of the Cables do not support debuggable. But its in my case.
This(Image) is my case the Type C should be as USB side symbol. A stupid solution, but work for me
I am attempting to install an Android app on my brand new Nexus 10. I have a .apk file. I have downloaded the Android SDK, installed "Android SDK Tools", "Android SDK Platform-tools", and Google USB Driver. I have checked the setting on my Nexus 10 for "Unknown Sources".
When I run "adb devices" from the command terminal, it doesn't list any devices. I attempted to follow this recommendation, because it was identical to a suggestion I had previously found here on Stack Overflow. After following those steps, "adb devices" still returns an empty list and to make it worse, when I connect my Nexus 10 to my PC, Windows doesn't show any folders within the device.
I have undone the steps in that link, along with everything else I have done so far, as well as uninstalling my Nexus 10 from Device Manager and reinstalling it, but I am still not seeing any folders in the device.
Is there anything I am missing to get my device to show up in ADB devices?
What can I do to get Windows to see the folders within the device?
Windows 8 wouldn't recognize my Nexus 10 device. Fixed by Setting the transfer mode to Camera (PTP) through the settings dialogue on the device.
Settings > Storage > Menu > USB Computer connection to "Camera (PTP)"
For Windows 8 users:
After trying every solution given here, with no success, I found this:
Go to Device Manager
Browse my computer for drivers -> Let me pick from a list of device drivers on my computer
Choose Android Device and then Android ADB Interface.
Now I have my devices listed at adb devices.
This situation seems to arise with some ADB drivers. I have encountered the same thing with a couple of Google devices and installing the Universal ADB windows driver has fixed it for me every time.
Use another cable.
Just found out that one of my regular charging cables had Vcc, Gnd pairs, but no Data+, Data-.
https://en.wikipedia.org/wiki/USB#Pinouts
Make sure to Enable USB debugging in Settings -> Developer options
Also, run "adb devices" after getting into the platform tools folder in the Android SDK (unless you have that folder on your system path already), otherwise the command won't be found.
The device may not be visible for debugging if it is in MTP mode. Some devices only work in PTP mode (or even in "charging only" mode).
This can be changed in Settings > Developer Options > Networking > Default USB configuration > PTP.
Also, you'll get a notification on your android device asking you for confirmation about USB configuration setting change and to allow it.
Note: You can turn on developer options by following the link below:
enable developer options
I have found a solution (for Windows 7):
Connect your Nexus 10 to PC
Go to Windows Device Manager
RClick on ADB Interface -> properties
Details -> Hardware Ids.
You will see two records like these:
USB\VID_18D1&PID_4EE2
USB\VID_18D1&PID_4EE2&MI_01
5 Open the android_winusb.inf file (I have it in "C:\Users\<username>\AppData\Local\Android\android-sdk\extras\google\usb_driver" directory)
6 Create such records in [Google.NTx86] and [Google.NTamd64] sections using Hardware Ids from properties of ADB interface:
;Google Nexus 10
%SingleAdbInterface% = USB_Install, USB\VID_18D1&PID_4EE2
%CompositeAdbInterface% = USB_Install, USB\VID_18D1&PID_4EE2&MI_01
7 Save the file, and update driver for ADB Interface with showing the path to "C:\Users\\AppData\Local\Android\android-sdk\extras\google\usb_driver" directory
Sometimes ADB loses connection to the device, and needs to be reset. If you have everything else working (ie USB driver installed, Developer settings enabled on the device), and still can't see your device, you need to reset the ADB process.
This is available in the DDMS Perspective (from within Eclipse), Devices tab (the triangle on the far right includes a menu item to perform the reset).
Otherwise from the command line, you can reset it with the following 2 commands:
adb kill-server
then
adb start-server
Enable Developer options in your device. To enable the developer mode, setting->About phone, tap Build number option 8 times continuously
Go to Settings-> Developer options and Turn on USB debugging
From the above steps it didn't work try this step, Go to Settings->Security and turn on Allow Unknown Resources
You have to download the drivers from the SDK manager (extras → Google USB Driver)
Then you have to install the USB driver in Windows (it works for me in Windows 8.1):
(Copy and paste from http://developer.android.com/tools/extras/oem-usb.html#InstallingDriver:)
Connect your Android-powered device to your computer's USB port.
Right-click on "Computer" from your desktop or Windows Explorer, and select "Manage".
Select "Devices" in the left pane.
Locate and expand "Other device" in the right pane.
Right-click the device name (such as Nexus S) and select "Update Driver Software." This will launch the "Hardware Update Wizard".
Select "Browse my computer for driver software" and click "Next."
Click "Browse" and locate the USB driver folder. (The Google USB Driver is located in <sdk>\extras\google\usb_driver\.)
Click "Next" to install the driver.
After downloading the Google drivers via Android SDK Manager (available via Eclipse, Intellij or Android Studio), I had to update the driver in Computer Management > Device Manager > Other Devices > ADB - right clicking and clicking on update driver and browsing for updated driver finally did the trick.
BTW, a total nightmare for me as well. I continue to be bewildered that setting up a dev environment should be the most difficult task imaginable, with each new inexplicable failure leading to another one. Jeesh! Good luck.
On my Windows 8.1 64bit (Nexus 5 did not show up), only manually installing the USB driver fixed it:
http://developer.android.com/sdk/win-usb.html
The "Google USB Driver" in "Android SDK Manager" was installed already.
I still get this once in a while and it usually works if I unplug it and plug it back in a different port. I'm on Linux but had the same thing happen on Windows before.
Installing Samsung Kies and using their tool to reinstall device drivers, is what finally worked for me with my Galaxy S3 and Tab S 8.4
Normally SDB will download the driver in the **android-sdk-windows\extras\google\usb_driver** path
Here are the steps that worked for me:
Enable USB debugging.
Do to device manager, right click on ADB device and click update driver software.
Select "Browse my computer for Driver Software"
Select "Let me pick from list of Device drivers on my computer"
Click on "Have Disk" option.
Select the driver path **android-sdk-windows\extras\google\usb_driver** (path of sdk)
7.Select 1st driver out of list of drivers shown.
And hopefully, it will work.
Edit: I recommend you DO NOT run ADB under VirtualBox if you are using a Windows Host. Somehow I got VirtualBox to lock the device drivers on the host, eventually making it so that the ADB wouldn't work on the client nor the host for any device I plugged in. To fix, I removed VirtualBox extensions on the host and ran http://www.nirsoft.net/utils/usb_devices_view.html to delete the incorrect drivers. I could not get the correct drivers to load while VirtualBox extensions were installed, and this problem was a complete bastard to diagnose and fix.
Edit 2: Also the following is probably out of date, now that Google have released an integrated ADB extension for Chrome.
What an installation nightmare... Here are the steps I needed to get my Nexus 10 recognised on an XP virtual machine running under VirtualBox:
If you get asked to install Nexus 10 drivers, make sure to untick "don't ask again" (you WANT to be asked again!).
Plug in the Nexus 10 USB connection
Turn on debugging in the Nexus 10 settings Developer menu (tap "About Tablet" 7 times to get that menu).
In your virtual machine settings (host), add the samsung Nexus 10 device to the USB Device Filters (important - selecting it from the devices menu didn't seem to work).
In guest install java jre (if you don't have java installed). In Control Panel, change Java settings so that java doesn't run in the browser (to help prevent security issues).
In guest get the adk zip file and put it somewhere permanent. I needed to delete the .android config directory from the user directory because I moved the directory.
Run the SDK Manager.exe - if it doesn't work, try running sdk\tools\android.bat which seems to give better error reporting.
From SDK Manager install the Google USB driver package.
Unplug the Nexus 10 and plug it in again, and install the Google USB driver package.
Restart the guest.
running c:>[...]\sdk\platformtools> adb devices finally shows me the device...
For the Blu Studio 5.5s ADB drivers, you have to go through this hoop. I am certain it is the same with all Blu phones or maybe for all non-Google mfg phones, I am not sure. First of all if you connect the Blu device with USB cable and USB Debuggin off, you will see that Windows 7 loads a generic driver for you to copy on/off files to the phone and SD storage. This will appear when the USB cable is first plugged in and appears as a device icon under Control Panel, Device Manager, Portable Devices, BLU STUDIO 5.5 S (or the device you are working with). Do not bother getting the hardware ID yet - just observe that this happens (which indicates you are good so far and don't have a bad cable or something).
Go to the phone and switch on USB Debugging in the Developer section of your phone. Notice that an additional item appears as an undefined device now in the device manager list, it will have the yellow exclamation mark and it may have the same name of the phone listed as you saw under Portable Devices. Ignore this item for the moment. Now, without doing anything to the phone (it should be already in USB debug mode) go back to the Portable Devices in Device Manager and right-click the BLU STUDIO 5.5 S or whatever phone you are working with that is listed there without the exclamation mark (listed under Portable Devices). Right click on the icon under Portable Devices, in this example the name that appears is BLU STUDIO 5.5 S. On that icon select Properties, Details, and under the pull down, select Hardware IDs and copy down what you see.
For BLU STUDIO 5.5 S I get:
USB\VID_0BB4&PID_0C02&REV_0216&MI_00
USB\VID_0BB4&PID_0C02&MI_00
(Note if you do this out of turn, the HW ID will be different with the phone USB debugging turned off. You want to copy the value that it changes to when the USB debugging is ON)
Now do as the instructions say above, of course customizing the lines you add the the INF file with those relating to your own phone, not the Nexus 10. Here is what to customize; when you downloaded the SDK you should have a file structure expanded from the ZIP such as this:
\adt-bundle-windows-x86_64-20140321\sdk\extras\google\usb_driver
Find the file named: android_winusb.inf in the usb_driver folder
Make a copy of it and name it anything, such as myname.inf
Edit the myname.inf and add the lines as instructed above only modified for your particular phone. For example, for the BLU STUDIO 5.5 S, I added the following 2 lines as instructed in the 2 locations as instructed.
;BLU STUDIO 5.5 S
%SingleAdbInterface% = USB_Install, USB\VID_0BB4&PID_0C02&REV_0216&MI_00
%CompositeAdbInterface% = USB_Install, USB\VID_0BB4&PID_0C02&MI_00
Note that you add these lines to both the 32 and 64 bit sections, matching how the example in the tutorial reads.
Now go back up to the unknown device that appeared in Device Manager when you switched on device USB debugging and right click on this item (has yellow exclamation mark), right click on it and then select Update Driver Software, and then Browse My Computer, Let Me Pick, click on the Have Disk button and browse to find the myname.inf. Continue to agree to all the prompts warning you it might not be the right driver. As the final step, Windows should have identified the device as Android ADB Interface and once that is done, you should be able to go back, open your CMD window and run the command "adb devices" as instructed in this tutorial and now you should see that the phone is now discovered and communicating.
Now you can go have fun with the adb command.
At first Thanks #rmsyk's post.
For my issue and after long time suffering with Meizu C9 Pro witch require just android ADB drivers (no special drivers) referring to manufacturer and it solved in my Windows 7 PC by the bellow steps.
Make Sure to
Install latest version of ADB & Fastboot with the needed drivers.
Enable Developer options & USB Debugging.
Enable Media File Transfer (MTP Mode).
Manually replace C:\Users\USERNAME\.android with the folder included here ,Then kill process 'adb.exe' if found from Windows Task Manager and use adb devices and finally my device listed successfully and just confirm the PC as trusted.
Notes:
Android Studio was uninstalled in earlier time and also i tried to reinstall but was not a solution at all.
Tried adb kill-server & adb start-server but was not a solution too.
As well as the usual settings (enable USB debugging) I also had to select Enable OEM unlock in the Developer options.
This supposedly makes the device less secure, but it's your device and you know what you want to do.
Once checked the device behaved as expected and appears in the adb devices list.
You can always reverse all these settings once you're finished.
Confirm you have the correct platform SDK tools
For Windows 10, had to manually download the latest platform SDK tools from Android as the version supplied through Visual Studio 2017 EMDK for Xamarin was not sufficient. Everything else except adb.exe devices worked.
https://developer.android.com/studio/releases/platform-tools
After the platform tools were manually downloaded, device showed up regardless of USB configuration (charging, MTP, etc.)
Installing an emulator device at this stage is also helpful to see whether the problem is with adb or your physical device.
List of devices attached
12345D1234 device
emulator-5554 device
There could be two reasons why adb devices command is not working for you. Either your phones USB drivers are not installed properly or you have not enabled USB debugging mode.
I created a tool that makes installing USB drivers a one click thing.
Just connect your phone in USB debugging mode to PC.
Run my tool
It will detect and install drivers specific to your phone and also install the latest ADB & Fastboot binaries with it.
The tool is available at my GitHub Repo
It's so easy, just turn off your Android device, and then hold down both "Volume Down" key and "Power" at the same time. Wait a few seconds till it start in recovery mode, done.
Now type adb devices, and you'll see your device.
I had the same problem with my Windows 8. The Android/SDK USB driver was installed correctly, but I forgot to install the USB driver from my phone. After installing the phone USB driver ADB works fine.
I hope this will help.
Turn on debugging in the Nexus settings Developer menu (tap "About Tablet" 7 times to get that menu).
Freaking Google tricks!
Have you had an android update recently? I updated to Lollipop and all the sudden I had no adb devices. Boo! I spent awhile trying a few things to no avail. Then I went into my developer options and lo and behold, "USB debugging" had been turned off. Silly Google. After turning it back on, it immediately showed up and I'm back in business!
GoTo DeviceManager, then right click on the android device and click uninstall driver.
Unplug and plug the device back...then a pop will come on your device while your pc installs the required drivers. Click "allow" on the popup.
You can see your device when you type "adb devices" in command prompt.
For Windows, just end all the processes related to Blue stacks or any such emulator if you are using.
Worked for me.
There's obviously a ton of different problems that could be causing this (and a ton of different solutions to go along with those problems). So think about all the solutions!
If you've gotten this phone and computer pair to work together before, but they aren't working any more, it might be a specific program on your computer rather than a problem on your phone. Some programs install/use their own adb, and only one of these can connect to your phone at a time. I think this makes a race condition, so sometimes it'll connect fine.
Some programs that run adb:
HTC Sync Manager - uninstall this.
chrome://inspect - lets you view localhost on your phone. Just close the window when you're done with it.
To have ADB in MTP mode
If you don't find any ADB device (nothing with exclamation mark) in the device manager (with all developers settings on phone checked), do this:
In Device Manager :
UpdateDriver->Manuel Install->Search on my computer->Select from installed driver list -> then select the one with the word usb in it (not MTP).
Edit: after that, you'll then have 2 or 3 peripheral, one for USB and one for ADB, install adb driver using usual method (see first answers)
For my Nexus 6P downloading drivers from Google helped resolved the issue. Here is the URL with documentation. And here you can download the driver itself.
P.S. I saw some people advice to download some drivers from random places on internet. While this might help it's too dangerous in my mind to download unknown drivers from unofficial places. So the one from Google worked well for me :)
I'm running on Windows 7, and I've updated all the drivers as it says on the Android developer website regarding using hardware devices. However, Eclipse is still not recognising my Nexus 4 when I try to run the application. The Android device chooser pops up, but it doesn't show anything on the hardware section. I've turned debugging, third-party apps, and mock locations all on on my phone as well.
Is this because the phone is still new? Is there a way of making my Nexus work with Eclipse?
Nothing is showing up under ADB devices in the command prompt.
I had a similar sounding situation with my Nexus 4. For me it was an issue with the drivers Windows was installing automatically. I followed the instructions in [Q]Computer won't recognize phone? - Post #8. I had some slight differences on Windows 7.
For me I,
Uninstalled the driver from Device Manager
Let it automatically install the generic 'MTP device driver'
Right clicked on the new device and selected 'Update Driver'
Selected 'Have Disk' and pointed it to [android-sdk-dir]\extras\google
Watched an 'ADB' driver install.
Opened Eclipse to successfully run on my Nexus 4.
Just to confirm a previous comment. I needed to switch my connection to Camera (PTP) mode in addition to enabling Developer options and then selecting USB Debugging from the newly appeared Developer Options.
To enable USB debugging, go to settings, about phone and then at the bottom tap build number seven times. This will enable the developer settings where you can enable USB debugging.
To fix/install Android USB driver on Windows 7/8 32bit/64bit:
Connect your Android-powered device to your computer's USB port.
Right-click on Computer from your desktop or Windows Explorer, and
select Manage.
Select Devices in the left pane.
Locate and expand Other device in the right pane.
Right-click the device name (Nexus 7 / Nexus 5 / Nexus 4) and select Update
Driver Software. This will launch the Hardware Update Wizard.
Select Browse my computer for driver software and click Next.
Click Browse and locate the USB driver folder. (The Google USB
Driver is located in <sdk>\extras\google\usb_driver\.)
Click Next to install the driver.
If it still doesn't work try changing from MTP to PTP.
I had the same problem, but I didn't want to change to PTP mode. This is how I fixed it with MTP still enabled.
Uninstalled Google USB Driver from Eclipse in the Android SDK Manager.
Uninstalled the driver from Device Manager - click box for "delete driver from my computer"
Unplugged and re-plugged my phone into the computer.
Windows "improperly" installed drivers for the Nexus 4.
The Nexus 4 was now showing up in My Computer like a drive.
Reinstall Google USB Driver in SDK Manager.
Update Nexus 4 driver in Device Manager.
Everything works.
I had the same problem and none of the above worked, but the following solution worked for me:
On my Nexus 4:
Go to Settings
Choose Developer options (from the end of the list after pressing seven times on "About phone")
Check the "USB debugging" and press OK.
For what it's worth, in my case I was able to fix the problem simply by changing my USB connection mode from Media device (MTP) to Camera (PTP).
I had to resort to a clean install of Windows 7 x64 to fix this issue.
I tried all steps/variants in the other answers. No luck. Device Manager would show my 'Android Device / Android Composite ADB Interface' working properly with the 7.0.0.1 driver from Google, but nothing could get 'adb devices' to show my Nexus 4.
I used USBDeview to uninstall every USB device that had connected to my computer except my keyboard and mouse. No luck.
I enabled 'Show hidden devices' in Device Manager and uninstalled anything related to USB. No luck.
I added Google's vendor ID to adb_usb.ini. No luck. I deleted adb_usb.ini and ran 'android update adb'. No luck.
I brought my Nexus 4 to my brother's apartment to confirm it wasn't faulty. Worked on his machine without a hiccup.
I'm glad the clean install worked, because further troubleshooting was going to require swapping motherboards or buying a MacBook.
Boy, that escalated quickly.
Changing USB mode from MTP to PTP worked for me.
How to do it on Windows 8 (I think, it will work for Windows 7 too)
Open Android SDK Manager and delete Google Usb Driver
Open Control Panel -> Devices Manager -> Find your Nexus -> right click -> delete device
Unplug your device
Open Android SDK Manager and install Google Usb Driver
Connect your device
Open Control Panel -> Devices Manager -> Find your Nexus -> right click -> update drivers -> Manual update -> open android-sdk folder (enable checkbox for subfolders) -> install driver from Google Inc
adb kill-server; adb start-server; adb devices should show your nexus
Do not forget, that Android 4.2 now want you to submit RSA key from your computer, look at your device screen.
To enable developers options on Android 4.2: Open Settings -> About phone -> Tap on Build Number 7 times.
Just to add to the above posts for anybody struggling to get their Nexus 4 recognized by Eclipse - ADT. In the past the device was recognized by Eclipse ADT without any issues!
I ran into the same problems as the original question. Every approach I tried wouldn't work...
Toggling "USB debug" selection
Toggling "Allow 3rd party" apps selection
Allowing Mock locations
Reinstalling driver
Restarting adb.exe
Simple solution in the end
Go to Settings -> Storage -> USB Computer Condition (Menu option from Storage Screen)
Change from Media Device (MTP) to Camera (PTP)
You need to install USB drivers only if you use Windows (If you're using MAC/Linux, most likely it will work fine without any driver installations)
in the following link they describe how to do it:
http://developer.android.com/tools/extras/oem-usb.html
In short:
Connect your Android-powered device to your computer's USB port.
Right-click on Computer from your desktop or Windows Explorer, and select Manage.
Select Devices in the left pane.
Locate and expand Other device in the right pane.
Right-click the device name (such as Nexus S) and select Update Driver Software. This will launch 6. the Hardware Update Wizard.
Select Browse my computer for driver software and click Next.
Click Browse and locate the USB driver folder. (The Google USB Driver is located in \extras\google\usb_driver.)
Click Next to install the driver.
My symptoms were the composite device (this contains all of the actual USB devices such as the ADB interface, camera, etc) was not being installed. This has a hardware id of:
USB\VID_18D1&PID_4EE6&REV_0228
USB\VID_18D1&PID_4EE6
The composite device's children will have &MI_## after them. If you see those, then this is not the same issue.
I resolved this by coping usb.inf to %windir%\inf from a virtual machine of Windows 7. The hardware detected and installed fine after.
I have 2 Nexus 4 devices. One was connecting to ADB without any problems, the second one never showed up when I used the adb devices command. An additional symptom was, that the second phone did not show up as a portable device in Windows Explorer when the phone was set to Media mode.
At some point I found that a temporary solution for the second Nexus was to switch it to PTP mode. Then it was found by the adb devices command. The weired thing was that the first phone worked in both modes all the time!
Finally I found this solution that now allows me to connect both phones in both modes:
set USB mode of the phone to MTP (Media)
Using PC device manager uninstall the device ->Android Device ->Android ADB Interface
Make sure to check the box "Delete the driver software"!
then set the USB mode of the phone to PTP (Camera)
Using PC device manager uninstall the device ->Portable Devies ->Nexus 4
Then unplug the USB and plug it back in (ensuring that its set to MTP (Media) and I found that the device was correctly registered in Device manager as a ->Portable Devies ->Nexus 4
Solution found at: http://forum.xda-developers.com/showthread.php?p=34910298#post34910298
If you have a similar problem to connect your Nexus to ADB then I recommend to first switch it to PTP mode. If your problem vanishes with that step, I recommend to go through the additional steps listed above as MTP will probably be the mode you will want to set your phone to most of the time.
Follow Google's instructions for this, OEM USB Drivers.
In case none of the answers work perhaps the following clarifications will help. I followed the top answer and tried to load the program with ADB from the command line to reduce the possible complications and this did not work.
Once enabling PTP mode the ADB devices command would find my Nexus 4, but I could not push to it. I had to use Eclipse and in order for the dialog to display to accept the RSA key described below.
Note: When you connect a device running Android 4.2.2 or higher to your computer, the system shows a dialog asking whether to accept an RSA key.
On Windows 7, with Samsung Nexus S, it showed nothing in Device Manager, the adb devices command showed no devices, but when plugged in device said USB debugging was on and connected.
I used Andrea's Feb 2 answer to install the Google USB driver, which created the /gooogle/usb_driver directory and used RobertNovelo's Mar 7 answer to go to the link and follow the instructions. The device showed up in Device Manager under 'other'. I right clicked on it and selected update driver, and now it shows up in Device Manager under 'Android device', and now command line adb devices lists it.
I had a similar problem, and none of the previous solutions worked for me, and I've just solved it by myself (after a few hours of frustration), so I'm going to share my solution.
My computer suddenly stopped recognizing any Android device I've plugged in after it installed Android Composite ADB Interface for my Nexus 4. I was not able to uninstall the driver, because any attempt to do so by Device Manager was unsuccessful (Device Manager stopped responding every time).
So I've solved it this way:
Switch Windows into safe mode
Uninstall Android Composite ADB Interface
Install old SAMSUNG Android ADB Interface
Switch Windows into normal mode
Plug-in Android device (Nexus 4 in my case)
Windows recognized the device as Nexus 4
Install driver from android-sdk/extras/google folder
Everything works again! :)
I have a way to fix your problem:
Download Nexus Root Toolkit v2.0.4: http://www.wugfresh.com/nrt/
Install and select your diver and choose the Google API. For example, I chose Nexus 4 and selected Google API 4.4.4
Click "full driver installation guide..." and click step 3 tab. Choose the Google drivers.
My Windows 7 installation was not finding a driver at all. The xda-forums post has the right folder to tell Windows where the drivers are -- {SDK directory}/extras/google/usb-driver.
If you don't have the extras/Google folder + Tim Bellis, go to the SDK Manager in your IDE and look for the Google USB driver in the Extras category, and install it. I cannot tell you how to do this in Eclipse, but if you have IntelliJ IDEA, it's near the bottom of the list, checkmark it and click "Install packages".
(Windows 7) My solution to this was to find the device in Device Manager, uninstall the existing driver and install a new one from the android folder in your user account using the include subdirectories option.
All the best.
Some of you may have experienced this issue. If you don't find the USB driver (like me, I downloaded a bundle of Eclipse and the Android SDK), go to <sdk>/SDK Manager. Open it and select USB Driver from the options to install and you are ready. I had to do the PTP mode too.
If you have problems to install the ADB driver under Windows 8.1, try this solution: ADB Driver and Windows 8.1
For me, it was Nexus 4 and Windows 7. I reinstalled the drivers, changed to PTP - basically went through everything.
Clicking the tab that said MainActivity.java rather than activity_main.xml in Eclipse fixed it for me.
My solution is very silly. I had tried all the solutions above and wasted so many hours. Then I found out the solution when I browsed developer options. I didn't check mark the "USB debugging" option. The silly me assumed turns on developer options mean turns on USB debugging, but I was wrong.
It was a driver missing problem with me. I had enabled the USB debugging, tried changing the USB cable, tried reinstalling the Google USB drivers, but nothing came to my rescue.
Then ultimately I downloaded the device drivers as suggested here.
To make sure whether you have a device driver problem, go to:
Computer->right click
Manage
Device Manager
And see if you have your Nexus shown as an "Android device" or as a device in "Others".
If it shows in "Others", your problem should be resolved by downloading & extracting this and then following these steps:
Right click on your device after finding it in Device Manager as per the above mentioned three steps.
Say Update driver software.
Say Browse My computer for driver software
Pinpoint it to the location where you had downloaded the drivers from the above link.
Finally, your device will show up as follows:
As soon as you do this, a popup will show up on your device asking for permission to debug. Once you accept, you are ready!
adb doesn't recognize my Nexus 10 on Windows 7. Here's what I've done:
Installed the SDK and USB driver from Google. Windows 7 sees the tablet as an 'Android ADB Interface.'
Put the tablet in developer mode by clicking on 'About tablet' and clicking the build number seven times
Put the tablet in Camera (PTP) mode by going to Storage > USB Computer Connection.
Started and restarted the tablet, my computer, and the adb server repeatedly.
None of this helps. When I run 'adb devices,' it gives me an empty list. What else can I do?
Thanks.
I had the same problem on Windows 7.
First make sure the Nexus 10 developer mode and USB debugging is on ( if you dont see developer options, tap on About Settings -> Tablet -> Build Number a several time and it should activate developer mode)
Check if your ADB driver is in good shape by going into the Device Manager. If not un-install the ADB device manager and re-install it by pointing Windows to Android SDK location (It should pick up the driver automatically).
Once it is installed and still it does not work. Go into Settings-> Storage -> USB Computer Connection and select PTP option. Reconnect tablet to the USB.
Hope it helps!.
I had some problems with this as well. I was on win 8.
Install the SDK and USB driver from Google. USB driver is available in 'Android SDK Manager' in eclipse.
Put the tablet in developer mode by clicking on 'About tablet' and clicking the build number seven times (crazy)
Open Windows Device Manager and right click 'Android ADB Interface'
Click Properties
Driver Tab
Update Driver
Select 'Browse my computer for driver software' Select the 'sdk' folder under the location you installed your sdk in step 1 (e.g. D:\Dev\Software\adt-bundle-windows-x86_64-20130219\sdk)
Not sure why windows didn't auto-detect it but it didn't. Could have been because google doesn't actually 'install' the driver into windows or perhaps it was because I had the HTC USB drivers installed because of my old phone.
I started with the same problem as you, but managed to get my adb connection working on a Fedora 16 system as follows:
Inserted 0x18d1 into adb_usb.ini (I do not bother with the device ID)
Inserted the following extra line into 99-android.rules. It's not the quite the same as yours but I leave you to experiment.
SUBSYSTEM=="usb", ATTR{idVendor}=="18d1", MODE="0666", GROUP="plugdev", OWNER="johnp"
Pressed the settings->about->version number 7 times.
Rebooted tablet and noticed that a new section is created in settings called "developer options".
Enabled USB debugging in settings->about->developer options.
On Fedora performed adb kill-server.
On Fedora performed adb start-server.
On Fedora performed adb devices.
I now see a new USB device in the list. When I go to my development environment (Eclipse) I see the device there as well.
For those who are still stuck after following the other good answers, try a different USB port ...plus adb restarts just to make sure. That had me stalled for ages.
I had the same issue, but I downloaded the drivers from this application and it started working. I used this same technique on Windows 7 and Windows 8
Followed these instruction installed the correct ADB-drivers for me on Windows 7 http://developer.android.com/tools/extras/oem-usb.html
I have been struggling with the same problem for a month. I tried other Nexus 10's, other ports, other computers ... everything. I thought I tried other USB cables too, but maybe not enough, as when a friend gave me yet another cable debugging worked.
It turns out the problem for me was that the EMI protection of the PC fires off when Nexus 10 is connected via a bad cable to a bad (front-case) port. It is a big tablet, so my guess is it draws a lot of current, and this combined with a badly shielded cable makes the PC freak out.
So my suggestion to people who couldn't solve the problem in any other way is: get a good USB cable (one where the connectors are bulky - means better shielding), rather than a cheap one.
On the picture: the red cable is bad, the black one is good.
Have fun,
-Stan
All I had to do was restart the tablet.
You should have done at least two things to get your device recognized on Linux:
specify USB manufacturer and device ID in your hot-plug manager
add an entry to ~/.android/adb_usb.ini using USB manuacturer ID
You may find manufacturer and device IDs with 'lsusb' command (that's LSUSB in lower case).
As strange as it sounds, try switching the tablet between media device and camera mode. On the 10 ADB only works for me in camera mode, while on the 7 it only works in media device mode.
Try a different usb port. Worked for me on windows 8.1 with Nexus5/10.