Reputation: 3910
I've been at this for a while. My issue is with using my OnePlus in order to run apps over ADB. As expected, when I connect my OnePlus without USB Debugging enabled, it is connected as a "Portable Device" in my Device Manager. However, when I turn on USB Debugging, the device "disconnects" from the computer altogether (I can't even access the files on it).
I've tried numerous tutorials and driver installers, all unsuccessful. I have the latest Android Studio along with the latest ADB drivers. If anyone could point me in the right direction, that would be much appreciated!
Update: The (ancient) Samsung Galaxy SII works properly when connected to my computer. I can only assume this is an issue with my OnePlus.
Upvotes: 7
Views: 22552
Reputation: 1
I got it to work by:
Windows and Android Studio recognized the phone immediately after doing that.
For some reason, the popup asking what to do with the connected device wasn't showing in Windows 10 when plugging in the USB cable, setting the USB configuration manually on the phone made Windows recognize the device.
Upvotes: 0
Reputation: 358
After spending hours, this worked for my OnePlus5 on Ubuntu 16.04
Upvotes: 3
Reputation: 11
Enable the following options in one plus device. we can access ADB commands
By doing these following instructions, adb command can be used without even rooting the device
Upvotes: 0
Reputation: 1602
Try this out if above options doesn't work:
Upvotes: 0
Reputation: 31
None of the existing answers worked for me as I was trying to access my OnePlus 6T using adb on my Ubuntu machine. I then spotted that, with USB Debugging turned off, the laptop was mounting a read-only partition from the phone that included a Windows executable, a Mac OSX .dwg file, and a linux .sh script. Running the linux script and re-enabling USB Debugging then allowed adb to detect the phone.
I'll paste the shell-script below for completeness, but the main thing it's doing is adding the string 0x2a70
to the file ~/.android/adb_usb.ini
and then restarting the adb daemon.
# adb configuration script
PATH=$PATH:/bin:/sbin:/usr/sbin
ANDROID_HOME=~/.android
ANDROID_CONFIG=~/.android/adb_usb.ini
CUST_VID="0x2a70"
if [ -e $ANDROID_HOME ] ; then
echo "android home is exist!"
else
echo "creat android home!"
mkdir $ANDROID_HOME
fi
grep $CUST_VID $ANDROID_CONFIG 2>/dev/null
if [ $? -eq 0 ] ; then
echo VID $CUST_VID is already configured..
echo "adb should be OK!"
exit 0
else
echo config adb ...
echo $CUST_VID >> $ANDROID_CONFIG
fi
adb kill-server
if [ $? -eq 0 ] ; then
echo "OK! You can use adb now!"
exit 0
else
echo "try sudo exec adb.."
sudo adb kill-server
if [ $? -eq 0 ] ; then
echo "OK! You can use adb now!"
exit 0
else
echo "Please do command \"adb kill-server\""
fi
fi
exit 0
Upvotes: 1
Reputation: 8979
Make sure the cable is properly connected to your phone.
I know this sounds stupid, but this is what happened to me. I'm using a new phone case and when I connected the cable, phone was charging, but not visible for ADB. I found out that the cable is not fully plugged into the phone. When I took the phone out of the case, everything started to work as expected.
Upvotes: 0
Reputation: 391
use Automated installation http://adbdriver.com/downloads/
worked for me.
Upvotes: 0
Reputation: 852
Well in my case, I just followed this video: https://www.youtube.com/watch?v=wXtbAMarHQw
And if in case, while selecting for the Device Drivers your Device Manufacturer Name doesn't show up.. Don't worry got to Google and select Google Composite ADB Driver Interface and select it.
This procedure worked for me!!
Upvotes: 0
Reputation: 307
I managed to resolve this problem, albeit after many hours, by following these really helpful instructions. I also had to put device into PTP mode, as mentioned by @mattrick in an earlier answer.
If you don't have Android SDK installed, please install it first.
C:\Program Files (x86)\Android\android-sdk\extras\google\usb_driver
Hope this helps! Here's my source: visualgdb.com
Upvotes: 13
Reputation: 59
Go to your device manager, right click the phone and click update driver. There should be an option to select the driver from a list. Find Universal ADB Device on the list and select that.
Upvotes: 1
Reputation: 3910
I got it to work:
It turns out when your device is connected through Media Device (MTP), ADB will not be able to communicate. In this case, you have to connect as a Camera (PTP) for it to work. Super annoying, but an easy fix if anyone happens to have this same issue.
Upvotes: 12
Reputation: 101
I think the problem is due to ADB driver.
I also faced the same problem with micromax tab.
Try universal ADB driver. Install it and check.
Upvotes: 3