5

I'm using Xamarin Studio and Xamarin Android Player on my windows 10 PC.

I'm having trouble starting Lollipop/Marshmallow (API 21/23) devices using the XAP, but on the other hand, launching Kitkat (API 19) works prefectly.

I've downloaded the required android SDK, tried reinstalling everything again and again but nothing works.

It seems wired, because it is not a problem with Virtual Box, nor with my PC or my XAP installation (if it was, than why Kitkat works?).

I've tried every solution I could possibly find, but nothing works.

Any ideas on what could cause this problem?( If further information is required, I will be happy to add :)

EDIT

It does not matter whether I start the devices through VS/XS/XAP. It all comes down to the same problem, but for the sake of simplicity, let's say I'm running them directly through XAP. Here is a screen shot of what happens when I launch Lollipop (which is API 22, and not 21, for a strange reason) :

For like 5 minutes, the following occur:

enter image description here

Than, forever:

enter image description here

And after a few hours it says booting or something like that, and than restarts to the first position.

With Kitkat, it just starts :).

Community
  • 1
  • 1
Eminem
  • 870
  • 5
  • 20
  • 2
    Are you starting the devices through Xamarin Studio or directly through XAP? Can you also attach a screen shot of what happens when you start Lollipop or Marshmallow? – Coding with Cookie Jan 10 '16 at 22:33
  • It doesn't seem to be an obvious error, but have you checked your logs in Virtual Box by right clicking the Image and grabbing the log files? – Jon Douglas Jan 13 '16 at 05:33
  • @JonDouglas I've opened a chat on this topic. I'll be glad if you visit there. – Eminem Jan 13 '16 at 10:34
  • When you reinstalled everything did you delete all the contents of the `C:\Users\username\AppData\Roaming\XamarinAndroidPlayer` directory? – Coding with Cookie Jan 16 '16 at 05:36
  • @CookData I have. It changed nothing. – Eminem Jan 17 '16 at 10:23
  • plz read this thread related to your tech support issues, https://forums.xamarin.com/discussion/39021/lollipop-support-is-now-available – petey Jan 18 '16 at 19:19
  • @petey I'm aware that hyper-v can cause problems. However, I'm using windows 10 home edition, which has no hyper-v availble, according to [here](http://www.tenforums.com/tutorials/2087-hyper-v-virtualization-setup-use-windows-10-a.html) – Eminem Jan 18 '16 at 20:56
  • Does Genymotion work for you with API 21/23 images? – Matt Harrington Jan 18 '16 at 23:40
  • @MattHarrington I cant run any devices using Genymotion. No matter what I do, It produces an error stating something like cannot start the device, something related to virtual box. – Eminem Jan 19 '16 at 15:47

8 Answers8

2

you probably missed the intel HAXM update.. may be a possible duplicate: Android 5.0 (API Level 21) AVD not launching Intel Atom x86_64

Community
  • 1
  • 1
ymz
  • 6,602
  • 1
  • 20
  • 39
  • I have installed the Intel x86 emulator accelerator 6.0.1 using the SDK manager. – Eminem Jan 19 '16 at 22:46
  • are you sure that you installed it? the sdk manager only downloads it to the sdk\extras folder – ymz Jan 19 '16 at 22:48
1

First off, it's difficult to determine the problem without more information. Please list or screenshot the build error(s) you receive when you try to debug your app on a XAP emulator.

But on a hunch... within the past week, I had a problem with similar symptoms. In my case, I had to update project packages in order for my Xamarin Forms project to run on the higher Android APIs.

Reference on how to update packages: https://developer.xamarin.com/guides/cross-platform/application_fundamentals/nuget_walkthrough/#Package_Updates

C. McCoy IV
  • 887
  • 7
  • 14
  • I'm not using Xamarin.Forms, but rather Xamarin.Android. Either way, I dont think the issue is related to NuGet packages, because I have not installed any new/special packages in my project (which is a "hello world"). – Eminem Jan 11 '16 at 15:45
1

It might be that hyper-v is causing the problem: "VirtualBox and Hyper-V cannot co-exist on the same machine".

Try to disable it using bcedit as explained in the link. For further reference, see this discussion

PhilLab
  • 4,777
  • 1
  • 25
  • 77
  • I am aware of this issue. However, as I wrote, I cant run only high API devices. KitKat (API 19) works fine, which means VirtualBox works like it is supposed to. – Eminem Jan 13 '16 at 10:45
1

After launching xamarin android player, manually launch virtual box. You should see the device listed on the left. There is a good chance it will say "stalled." If it says anything other than "Running," try reseting it or starting it.

enter image description here

jaybers
  • 1,991
  • 13
  • 18
1

I also had problems with XAP and my solution was to use Genymotion instead.

Omkommersind
  • 276
  • 5
  • 13
1

Did you try Genemotion

I think it is best Android emulator.

Sergey Buzin
  • 255
  • 2
  • 6
0

I would post a comment but my reputation is too low. I don't know if this emulator works with Xamarin studio but if you use Visual Studio it may be an option for you.

  • I would love to use Visual Studio emulator, but it requirse 6 GB of RAM, and hyper-v installed. I have only 4 GB RAM with Home edition. – Eminem Jan 19 '16 at 17:38
0

Here is the solution:

I had the similar issue and fix the issue as follows.

  • delete the existing device simulator

  • reinstalled the simulator again

  • deploy the solution again.

casillas
  • 16,351
  • 19
  • 115
  • 215