So I have Visual Studio 2015 installed along with Xamarin and the Android SDK, etc... After being frustrated by the slowness of the default AVD(Android Virtual Device) I took some advice to get the Xamarin Android Player.
I went through the installation process and can run a virtual device instance by itself but I cannot get this to open from Visual Studio such that when I compile my Android app's code it opens in the Xamarin Android Player instead of the slow default AVD opening.
See image below:
I had the same issue. What I did was to open up my xamarin android player and then downloaded some of the devices and then restarted VS 2015. This came up.
I know this is a year old now, but thought it was worth pointing out for others that come across this question like I did. It looks like we may be better off using an emulator that isn't the Xamarin Android Player as it has been depreciated.
https://developer.xamarin.com/guides/android/deployment,_testing,_and_metrics/debug-on-emulator/
Related
a bit of a reverse question.... We're looking to develop apps using vs 2017 and Xamarin. However, we simply can't get the Android emulator to work with a usb webcam on a windows 10 PC.
We've just running the emulator, no visual studio code and using the camera app on the emulator. We've tried all the different version of the OS, all have the same result... If we set the front or back camera to emulate, we see the black and white checkerboard but if we set it to webcam(0), we get a could not connect to camera error msg.
We have also tried all the suggestions in similar questions, i.e. clear the memory, increasing sdcard.size etc.
Android studio's emulator has an error "can't connect to camera"
Android Emulator unable to open/connect with real webcam
Nothing seems to work...and none of the above answers have a positive answer (other than use a different emulator, which we are about to try)
So my question is "has anybody ever got this to work" or we hunting for a unicorn and it just doesn't work?
Well to be honest, the unicorn was there the first time I connected my cheap Genius USB camera from 2007 into my Windows 8.1 PC and configured the Back Camera as Webcam(0) in the Android emulator, to test a barcode scanning app made with Cordova 7.1.0 CLI.
I would suggest you to try with Android system images from different API levels (I think I used Android 5.1 or 6.0 for my tests) and also, why not, update the Android SDK tools. (I used the old SDK tools 24 at the time). If using the standalone SDK manager instead of Android Studio (like I do) follow these steps to update your SDK tools to version 27.
I hope this helps, anyway, you now know that the unicorn may be elusive but it can be found if you have the proper settings.
I'm having trouble getting any android emulator other than "Xamarin Android Player" to work (only with older versions of android).
What kind of virtual device/settings/properties should I use so that I can test newer versions of android and not have to wait 15 minutes for the emulator to startup?
is there a "Go-to" virtual device/emulator setup that doesn't take 15+ minutes to load?
(using windows 10/Visual Studio 17/2015)
The Xamarin android player has been discontinued for a while. As a visual studio user you should probably be moving onto the Visual Studio Android Emulator. There is a guide here on setup
https://learn.microsoft.com/en-us/xamarin/android/get-started/installation/android-emulator/
it is also available with visual studio 2017, and if i remember correctly is an option available in the Vs2017 installer.
I highly suggest Genymotion for most uses. You can download the free version which works well for most basic things (there are also a few small things you can do using the adb command prompt without having to buy the full version, such as taking screenshots).
Link to free version
They have a good list of different devices. I have also recently even got it successfully connecting to my Parallels Windows machine while the emulator is running on my Mac. Let me know if you need help with this specific scenario.
The other option for you is the Visual Studio Android Emulator. When it first cam out I tried using it but was not able to because I would need to run it on a Parallels VM which does not allow nested virtualization.
I have created a Windows Phone 7 app using XNA 4.0 that I now want to port over to Android MonoGame. I am currently using a trial edition of Xamarin Business and I want to use an emulator to test the game as I do not currently have access to a physical Android phone. I have downloaded both Xamarin Android Player and Oracle VM VirtualBox 5.0.4 (I think that's the version I've installed, at least). When I open Xamarin Android Player, I'm just presented with the message:
Unable to find VirtualBox
Error when attempting to find VirtualBox please check it's installed and try again.
Xamarin Android Player will now exit.
No version of Visual Studio or VirtualBox is open and running when I'm opening Android Player. Does anyone know how to fix this issue so that I can the emulator running and test the MonoGame version of the app?
After installing the latest preview release, v0.6.5.0 as of writing this, I ran into the same issue. It appears that Xamarin Android Player is expecting VirtualBox to be registered with the %PATH% environment variable, but it doesn't happen during the install process by default.
In this case, you just add C:\Program Files\Oracle\VirtualBox to PATH and you should be able to restart the Android Player just fine to begin downloading emulator images.
Here is a command-line approach to append this location to the existing PATH variable.
setx PATH "%PATH%;C:\Program Files\Oracle\VirtualBox"
You can also do the same edit through the Environment Variables screen found under the System Properties screen.
Just run as admin (Right hand click)
When using Visual Studio 2015 to develop c++ for Android the emulator only works if you are running a Pro version of Windows, for those using Visual Studio Community who are probably also running on a Home version of windows (like me) the Emulator will not work.
Is there an alternative available that can integrate with the VS debugger?
*** Edit
I have been looking at this list Android emulators although this seems to be aimed at android gaming on PC rather than App development. So was wondering if anyone had managed to integrate one of these with Visual Studio?
Both the below options come with the caveat that I have not used either.
Xamarin Android Player
Apparently Xamarin had issues with the default Android Emulator. Primarily that it was slow, and clunky, and they were getting a lot of complaints about it from Xamarin users (despite it not being their product/fault).
They decided to create their own emulator to get around this, and it can be found here.
It should be noted that (at time of writing) this is still in Preview by the looks of things. So bugs may be present.
From what I can see on the download page, it doesn't appear like you need Xamarin to actually use it. In any case, it's worth a shot.
GenyMotion
Another option is GenyMotion. There is a free version for personal use only (with limited functionality), or a paid option that provides more capability.
Android player link has changed to here: https://developer.xamarin.com/releases/android/android-player/
I had problems starting the android VMs, even after restarting the host. There seems to be some incompatibilities between Windows 10 Home and Virtualbox 5.0.4 that Android player installs. Installing Virtuallbox 5.1.2 after installing Android player seems to have resolved this.
EDIT: I haven't had a chance to test integration with Visual Studio yet.
Everything seems to be working as expected within Visual Studio. Both of the VM devices I created in Android Player are visible in the drop down of the run menu. Visual Studio will start the selected VM when I debug the default blank android app.
The only hiccup is that Visual Studio doesn't wait long enough for the emulator to start before attempting to deploy the app. So I have to start the run again or remember to start the VM from Android Player before debugging.
I'm new to Android programming. I have installed Android SDK and the Android Studio IDE. I have started by reading this. I copied this code in eclipse and then run my code as Android application. The problem is that when the emulator appears I can't unlock the phone! Also it is too slow and I can't do anything. What are the other options to run Android app?
If you run Windows or Mac and your hardware is not enough to use emulator, you may check BlueStacks (http://www.bluestacks.com). It's like a Android player for PC.