How to get Android Studio Emulator working properly with Ryzen on Windows - actual instructions that don't suck

I recently built a new Ryzen computer and felt like getting back into Android development for some personal apps. Got Android Studio up and running without any major issues, but the emulator wouldn't run without HAXM (which doesn't work on AMD processors).


Intel HAXM is required to run this AVD. HAXM is not installed.
Install Intel HAXM for better emulation performance.
So one of the first results we all see when searching Google for "Android Studio Ryzen" is a blog post on Google's official Android developers blog titled Android Emulator - AMD Processor & Hyper-V Support, posted in July 2018.

For Windows, the instructions looked simple enough.

  1. ✔️Have an AMD Ryzen processor
  2. ✔️Android Studio v3.2 beta or higher
  3. ✔️Android Emulator v27.3.8 or higher
  4. ✔️x86 based Android Virtual Device image
  5. ✔️Windows 10 April 2018 or higher
  6. ✔️Windows Hypervisor Platform enabled
  7. ???
  8. ❌Profit

Yes yes all done, but why am I still getting the HAXM error message? I checked for any other blog posts with the AMD tag but in the past 2 years nothing else has been posted for Ryzen.

They also point you to a troubleshooting page which pretty much gave the same instructions as the blog post.

So what the hell am I doing wrong? Nothing. The docs are wrong.

Image result for principal skinner kids are wrong

There is one crucial step missing from most results on the first page of Google when it comes to this issue and I even had trouble finding it on Stack Overflow and Reddit.

By chance, I thought "if Intel needs HAXM drivers, maybe AMD does too". So I took a look in the SDK manager and there it was sitting quietly in the second tab.


  • Open up Android Studio
  • From the top menu, click on Tools > SDK Manager
  • Expand the tree from Appearance & Behaviour > System Settings > Android SDK
  • Click on SDK Tools
  • Tick "Android Emulator Hypervisor Driver for AMD Processors (installer)"
  • Click OK or Apply and let it install
  • Once its finished, open up your Android SDK folder and navigate to "sdk_path\extras\google\Android_Emulator_Hypervisor_Driver"
  • Right click "silent_install.bat" and run with Administrator rights

Now you should be able to run AVDs at a decent speed.

I wish Google would take the time to update their own docs regarding this. It's literally one or two extra lines.

Source

 
Copyright © Twig's Tech Tips
Theme by BloggerThemes & TopWPThemes Sponsored by iBlogtoBlog