Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Deploying to Android device not found in Visual Studio

I'm trying to deploy an Apache Cordova app to an android device that's plugged into the machine. However when attempting to deploy, I receive the following error:

Unable to deploy to Android device, no attached device was found. If you recently attached a device, you may need to wait a few seconds before it is recognized.

As far as I'm aware, I've enabled all of the developer settings I need in order to deploy to the device. I've tried unplugging and plugging it back in, waiting a few seconds but to no avail.

I've tried changing the connection modes (HTC Sync, Disk Drive ect) however that hasn't made a difference.

The android device I'm trying to deploy to is pretty old (v3.35.61.3), so I've even tried to deploying to a different android device running the latest version of android however the same issue occurs.

This leads me to believe that it's an issue with Visual Studio not picking up any connected android devices. Perhaps I'm missing an install package?

like image 642
Mike Eason Avatar asked Dec 04 '15 13:12

Mike Eason


People also ask

Why is my device not showing in Android Studio?

If your device is not correctly detected in RAD Studio or in the system Device Manager, check the following: Ensure that your Android device is unlocked and not sleeping while connected via USB. Set the appropriate option in Settings or Developer Options. Make sure your Android device is enabled for USB debugging.


2 Answers

After smashing my head against a wall for a couple of hours, I managed to get this fixed.

I followed these instructions to install the SDKs for the target device.

There was still an issue where the abd devices command was still not showing up with any devices, I installed the Universal ABD driver which I found in this question and that worked for me.


EDIT

Some of you have found that the following can also fix the issue:

  1. Turn on the Developer Options on the device.
  2. Enable USB Debugging.

It might be worth trying this first, and if that doesn't work, try what I did.

like image 194
Mike Eason Avatar answered Sep 28 '22 14:09

Mike Eason


I ran in to this problem and I was sure I had everything installed. After some thought I tried to deploy again, and in the developer options on the device I turned usb debugging off and then back on, this got me a prompt to remember my computer's fingerprint. After that everything worked.

like image 20
roughandtmblrguy Avatar answered Sep 28 '22 13:09

roughandtmblrguy