I have the opposite of this problem: Android Studio doesn't see device
Android studio sees the device and can deploy to/ run on device no problem.
But I'm trying to use apache cordova and cannot see the device online from the command line.
adb devices
shows my device number, and "offline".
I've tried all of the recommended steps here https://stackoverflow.com/a/9966660/210757
Any suggestions?
Related
I am trying to test an application on my Android phone (Samsung Galaxy S8), but I cannot see it in the available devices menu in Android Studio. I can see it as a USB device is not recognized as an Android device.
This seems strange, considering that I have enabled developer mode on my phone. Furthermore, when I check to see that the driver for the device updated to the latest version, it shows that it is updated correctly.
If you are sure you did everything right, but you are still facing this problem, try to run this command in cmd:
adb kill-server
After that reconnect your phone and run:
adb start-server
And check if your phone is in devices lists by run:
adb devices
(In some cases you should restart the Android studio)
I want to run my code on the phone. But Android does not recognize my device. I also did the connection assistant.
But the following error is given. please guide me.
Needed informations
Is ADB installed with Android Studio, or have you got external tool?
Is there a generic Android USB Device driver installed? It's provided with Android Studio, and should be obtained with SDK Tools.
Possible solution
If even AVD cannot be recognized, it could be fault of built-in ADB server. I would recommend installing ADB as an external program, e.g. from here (ClockworkMod page).
After installation, reboot PC and plug your phone in. If phone is visible, check for availability via adb devices command from CMD/terminal. Don't launch Android Studio yet, as it has its own instance of ADB server and you wouldn't be able to launch second one from console.
If phone is visible, use adb kill-server command to finish the console instance, and launch Android Studio. Everything should be detected, if not - you really should submit that bug...
If phone is not visible all the time after issuing adb devices, there is a chance that not all drivers are installed. Check ASUS for drivers, if they were installed automatically - install them manually.
Hope it will help!
Have a look at PdaNet+
Install both the desktop client and the corresponding android application from the google play store. Once you plug in your device it will prompt you that your device has been connected and adb should recognise it.
Google Sdk adb fastboot usb driver installed.. there is no issues and even not alerting any error message but app build is failing..
There is no use even after installing CTP 3.1 for VS 2013.
Kindly help me on it
As Alan says, VS will try to launch the app on the device if you have selected the "device" option and are trying to run or debug the app on the device. Does building to Ripple work? If its failing only for device, Can you please attach the complete build log?
VS uses ADB to connect to the device and so even though you have installed the driver, the ADB might not be able to see the device.
Can you run the following command to see if ADB lists the connected device:
C:\Program Files (x86)\Android\android-sdk\platform-tools\adb.exe devices
Also please check whether your device shows up in the windows device manager.
Let me know what you find.
I have Visual Studio 2013 with Xamarin Android and iOS. Then I have some emulators there, but I don't like them. How do I connect my phone, so that Visual Studio or Xamarin anyway detects my phone and try my application in my phone. My phone is a Sony.
If you want to work with physical android device you have to install drivers for that device.
Use adb to test if you installed drivers correctly via "adb devices" command. Once adb detects your device VisualStudio and XamarinStudio will also see your device and you will be able to debug on device.
When I type adb devices -l this is the output:
$ adb devices -l
List of devices attached
VS9854G22b261d6 offline
I think that VS9854G22b261d6 is my phone. I had to install LG drivers before that would show up.
It seems like the solution to that "offline" problem is to update the android sdk. But, cordova requires an older SDK (api version 19, right?) So how can I make both adb and cordova happy?
I'm on Windows 8.1 and I have a Verizon LG G3 device. I have enabled USB debugging on the device. When I type cordova run android it starts the emulator and deploys to that. I am expecting this to deploy onto my connected device instead of onto an emulator. The "hello world" app deploys fine to the emulator, but I'm trying to deploy it to my device and I can't figure out why it's not even trying to do that.
When I type cordova run android this is the output:
...
BUILD SUCCESSFUL
Total time: 2 seconds
Built the following apk(s):
C:\...\cordova\platforms\android\ant-build\CordovaApp-debug.apk
WARNING : No started emulators found, starting an emulator.
Waiting for emulator...
### Error: could not find emulator icon resource: android_icon_32.png
In my case, I plugged into a different USB port and then it said "unauthorized". I changed the USB connection to camera and then the device asked me to authorize it. Then adb devices said "device" and cordova run android worked as expected. Seems to be a ton of different solutions to the same problem. This is all I needed.