vs2017 to create a new Android app, and then start to execute without debugging, and start reporting the following information:
--------------------------- Recommended AVD --------------------------- Running an x86 based Android Virtual Device (AVD) is 10x faster.<br/>We strongly recommend creating a new AVD. --------------------------- OK ---------------------------
What do you mean? That is to say, the virtual machine you are starting now is relatively slow, if you switch to an x86 format CPU, then the speed will be 10 times faster, or you don't start this ARM format. There is no solution to this: if you click OK, your virtual machine will not start. Just click Close on the right. It's just a hint anyway.
Summary: What kind of system is your computer? Otherwise, it will be more resource-intensive and stuck, and you will not be able to appreciate the smoothness of the new version of the virtual machine. I once felt that this was already a fight with the ios virtual machine in the Mac notebook. Of course, it is still not as smooth as entering people's homes. But at least there is no need to envy. Also available in the new version of the virtual machine are: positioning function, communication (making calls and SMS), taking photos, fingerprint recognition.
The solution is as follows:
vs2017-tools-android-android emulator manager, choose the emulator you need. Click Edit. CPU Select Intel x86_64, as shown below:
Then, continue to run the program with the following error:
1> Begin deploying Android_Accelerated_Nougat ... 1> is starting the emulator Android_Accelerated_Nougat ... 1>XXXX 1>emulator: ERROR: x86_64 emulation currently requires hardware acceleration! 1>Please ensure Intel HAXM is properly installed and usable. 1>CPU acceleration status: Please disable Hyper-V before using the Android Emulator. Start a command prompt as Administrator, run 'bcdedit /set hypervisorlaunchtype off', reboot. 1> Unable to start the emulator Android_Accelerated_Nougat.
The general tip is: CPU acceleration status: Please disable Hyper-V before using the Android emulator. Start the command prompt as administrator, run 'bcdedit / set hypervisorlaunchtype off', restart.
Solution:
Hyper-V is Microsoft's virtualization software, similar to VirtualBox and VMware, which can be used to create virtual machines. They are called hypervisors or Virtual Machine Monitors. Android Emulator is a very full-featured emulator that works with phonebooks, calls, and more (although you can't actually call from here). Even its built-in browser and Google Earth/Maps (with support for street reality!) can be connected to the Internet. Users can use keyboard input, mouse click simulator key input, and even use mouse clicks and drag screens to manipulate.
After the Hyper-V service is enabled in Windows, the emulator of Android Studio will find that the prompt hyper-V is not compatible
Solution: Turn off Hyper-V, there are two ways to turn off Hyper-V(The second method is recommended!!!!!! ):
1. Go to the Control Panel - Windows function to enable the virtual machine management function. Clear the checkbox content in the diagram and restart your computer.
2. Open the command prompt interface as an administrator:
Enter: bcdedit /set hypervisorlaunchtype off and then restart the computer (set to disable Hyper-V)
(Note: Command to re-enable hyper-v: bcdedit /set hypervisorlaunchtype auto)
After restarting the computer, you can install the Intel hardware acceleration function, which is introduced as follows: https://developer.xamarin.com/guides/android/deployment,_testing,_and_metrics/debug-on-emulator/android-sdk-emulator/#Hardware_Acceleration
Intel Hardware Accelerated Execution ManagerDownload address: https://software.intel.com/en-us/articles/intel-hardware-accelerated-execution-manager-intel-haxm
After installing haxm-windows_v6_2_1 is successful.
Launch vs2017 to debug the Android app, and you can successfully launch the Android emulator!!
|