如何在没有硬件加速的 Windows 8 上为 API 21 和 19 运行适用于 Intel x86 Atom 的 Android 模拟器?
声明:本页面是StackOverFlow热门问题的中英对照翻译,遵循CC BY-SA 4.0协议,如果您需要使用它,必须同样遵循CC BY-SA许可,注明原文地址和作者信息,同时你必须将它归于原作者(不是我):StackOverFlow
原文地址: http://stackoverflow.com/questions/26455756/
Warning: these are provided under cc-by-sa 4.0 license. You are free to use/share it, But you must attribute it to the original authors (not me):
StackOverFlow
How can I run Android emulator for Intel x86 Atom without hardware acceleration on Windows 8 for API 21 and 19?
提问by dcoder
I have not enabled Hyper V or hardware acceleration and don't want to either.
我没有启用 Hyper V 或硬件加速,也不想启用。
Is there any way that I can start android emulator for Intel x86 Atom Without hardware acceleration on Windows 8
有什么方法可以在 Windows 8 上启动没有硬件加速的 Intel x86 Atom 的 android 模拟器
I have created AVDs with every combination possible and each one has failed to start the AVD emulator instance , throwing the same error when starting
我已经用所有可能的组合创建了 AVD,并且每个组合都无法启动 AVD 模拟器实例,在启动时抛出相同的错误
emulator: ERROR: x86 emulation currently requires hardware acceleration! Please ensure Intel HAXM is properly installed and usable. CPU acceleration status: HAX kernel module is not installed!
模拟器:错误:x86 模拟当前需要硬件加速!请确保英特尔 HAXM 已正确安装和可用。CPU加速状态:未安装HAX内核模块!
OR is it that, the images given for Intel Atom 86 and 64 cannot run without HARDWARE ACCELERATION AND hyper V for API 21 and 19
或者,如果没有硬件加速和 API 21 和 19 的 hyper V,为 Intel Atom 86 和 64 提供的图像无法运行
I have found lots of similar question and read almost all documentation, but it is not clear if they can or cannot run without hyper v and hardware acceleration, hence this direct question
我发现了很多类似的问题并阅读了几乎所有的文档,但不清楚它们是否可以在没有 hyper v 和硬件加速的情况下运行,因此这个直接问题
How do you test on android in such cases ?
在这种情况下,您如何在 android 上进行测试?
回答by Eslam Sameh Ahmed
In current AVD manager you can't. You just have the opportunity to use ARM images which will not need hardware virtualization.
在当前的 AVD 管理器中,您不能。您只是有机会使用不需要硬件虚拟化的 ARM 映像。
To run ARM images:
要运行 ARM 映像:
- Open AVD manager.
- Create a new 'Virtual Device' OR right click an existing image and select 'Duplicate'
- Choose arm* instead of x86/x64.
- Continue with the wizard.
- Run!
- 打开 AVD 管理器。
- 创建一个新的“虚拟设备”或右键单击现有图像并选择“复制”
- 选择 arm* 而不是 x86/x64。
- 继续使用向导。
- 跑!
Although this is the available solution but still a slow one !!
虽然这是可用的解决方案,但仍然很慢!
回答by Graeme Gill
You can still force the use of the soft x86 emulator by running it from the command line and using the -no-accel option, i.e. from the SDK/tools directory:
您仍然可以通过从命令行运行并使用 -no-accel 选项来强制使用软 x86 模拟器,即从 SDK/tools 目录:
emulator -avd AVD_NAME -memory 768 -no-accel -gpu on
BUTthis still won't work with the current (V24) SDK, because the current x86 system images crash the soft x86 emulator :-(
但这个仍然不会与当前(V24)SDK的工作,因为当前的x86系统映像崩溃软x86模拟器:-(
The only way I got this working again was to downgrade the SDK tools to V22.3 from here: http://dl-ssl.google.com/android/repository/tools_r22.3-windows.zipand to buld an AVD using a downgraded system image, for instance https://dl-ssl.google.com/android/repository/sys-img/android/sysimg_x86-17_r02.zip. (So this is no help if you need to test on more recent versions of Android).
我重新开始工作的唯一方法是从这里将 SDK 工具降级到 V22.3:http://dl-ssl.google.com/android/repository/tools_r22.3-windows.zip并使用buld AVD降级的系统映像,例如https://dl-ssl.google.com/android/repository/sys-img/android/sysimg_x86-17_r02.zip。(因此,如果您需要在更新的 Android 版本上进行测试,这将无济于事)。
Google have moved on to an updated version of their emulator based on a more recent version of qemu, and provide binaries for arm and mips emulators, but have omitted to ship the x86 equivalent (there is no emulator-ranchu-x86.exe and emulator64-ranchu-x86.exe). If they did so, or if someone else went to the trouble of setting up and compiling their emulator source with the "x86" flag on, then _x86 soft emulation could conceivably be made to work again.
Google 已经转向基于更新版本的 qemu 的模拟器的更新版本,并为 arm 和 mips 模拟器提供二进制文件,但省略了 x86 等效版本(没有 emulator-ranchu-x86.exe 和 emulator64 -ranchu-x86.exe)。如果他们这样做了,或者如果其他人在设置和编译带有“x86”标志的模拟器源代码时遇到了麻烦,那么 _x86 软模拟可能会再次起作用。
回答by Daniel
Same issue as in Error in launching AVD:
1) Install the Intel x86 Emulator Accelerator (HAXM installer)from the Android SDK Manager;
1)从 Android SDK Manager安装Intel x86 Emulator Accelerator (HAXM installer);
2) Run (for Windows):
2)运行(对于Windows):
{SDK_FOLDER}\extras\intel\Hardware_Accelerated_Execution_Manager\intelhaxm.exe
or (for OSX):
或(对于 OSX):
{SDK_FOLDER}\extras\intel\Hardware_Accelerated_Execution_Manager\IntelHAXM_1.1.1_for_10_9_and_above.dmg
3) Start the emulator.
3) 启动模拟器。
回答by Ankur
Short Answer: No. Until recently(about 1 month ago), you could do that but with the latest updates, it is not possible. (see Update to Android SDK Tools 23.0.5 and avd doesn't start).
简短回答:否。直到最近(大约 1 个月前),您还可以这样做,但使用最新更新,这是不可能的。(请参阅更新到 Android SDK 工具 23.0.5 并且 avd 不启动)。
I was doing something similar: Doing development in a virtual machine and hence couldn't use the Hardware acceleration features as they are available only in the host machine. I was using Intel x86 images with Use Host GPUoption; as they were much faster than the ARM version even without hardware acceleration. But then, after this update, my emulator AVDs which were working earlier are no longer starting with the same exact error message. Also, both genymotion and Xamarin Android emulators can't be used as they also need hardware acceleration(they are actually VMs which use Hardware acceleration for speed, and hence can't be run inside another VM).
我正在做类似的事情:在虚拟机中进行开发,因此无法使用硬件加速功能,因为它们仅在主机中可用。我使用 Intel x86 图像和Use Host GPU选项;因为即使没有硬件加速,它们也比 ARM 版本快得多。但是,在此更新之后,我之前工作的模拟器 AVD 不再以完全相同的错误消息开头。此外,genymotion 和 Xamarin Android 模拟器都不能使用,因为它们也需要硬件加速(它们实际上是使用硬件加速来提高速度的 VM,因此不能在另一个 VM 中运行)。
I have found this solutionbut haven't tried it yet. The basic idea is that to still develop inside a VM; but for testing connect to an Emulator running on the host machine(and this Emulator VM can now use the hardware acceleration feature).
我找到了这个解决方案,但还没有尝试过。基本思想是仍然在虚拟机内部进行开发;但是为了测试连接到主机上运行的模拟器(并且这个模拟器 VM 现在可以使用硬件加速功能)。
回答by Mina Samir
The usage of the Hardware acceleration depends on the System Image you choose on the emulator.
硬件加速的使用取决于您在模拟器上选择的系统映像。
So,
所以,
Go to AVD manager, create virtual device, select hardware, click next.
Choose the System Image that does not require HAXM (hardware acceleration) for running. (That is appears at the right bottom of System image window.)
进入 AVD 管理器,创建虚拟设备,选择硬件,点击下一步。
选择不需要 HAXM(硬件加速)运行的系统映像。(它出现在系统图像窗口的右下角。)
Note: for other systems that require HAXM, there no way to run them without hardware acceleration.
注意:对于其他需要 HAXM 的系统,没有硬件加速就无法运行它们。
回答by Vicen?
I've run into the same problem, I found the solution at http://developer.android.com/tools/devices/emulator.html#vm-windows
我遇到了同样的问题,我在http://developer.android.com/tools/devices/emulator.html#vm-windows找到了解决方案
Just follow this simple steps:
只需按照以下简单步骤操作:
Start the Android SDK Manager, select Extras and then select
Intel Hardware Accelerated Execution Manager
.After the download completes, run [sdk]/extras/intel/Hardware_Accelerated_Execution_Manager/IntelHAXM.exe
Follow the on-screen instructions to complete installation.
启动 Android SDK Manager,选择 Extras,然后选择
Intel Hardware Accelerated Execution Manager
。下载完成后,运行[sdk]/extras/intel/Hardware_Accelerated_Execution_Manager/IntelHAXM.exe
按照屏幕上的说明完成安装。
回答by CommonsWare
Is there any way that I can start android emulator for intel x86 atom Without hardware acceleration on windows 8
有什么方法可以在 Windows 8 上启动没有硬件加速的 intel x86 atom 的 android 模拟器
Not with the standard Android SDK emulator, as it requires Intel's HAXM, and HAXM wants virtualization extensions to be enabled.
不是使用标准的 Android SDK 模拟器,因为它需要 Intel 的 HAXM,而 HAXM 想要启用虚拟化扩展。
Whether Genymotion or something else from another independent developer can support your desired combination, I cannot say.
Genymotion 或其他独立开发商的其他东西是否可以支持您想要的组合,我不能说。
回答by Gopi Raj
use bluestacks as a emulator for best performance. blusestack working fast without hardware based emulation
使用 bluestacks 作为模拟器以获得最佳性能。blusestack 无需基于硬件的仿真即可快速运行
To connect bluestack to android studio.
将 bluestack 连接到 android studio。
- Close Android Studio.
- Go to adb.exe location.(Bydefault its C:\Users\Tarun\AppData\Local\Android\sdk\platform-tools)
- Run
adb connect localhost:5555
from this location. - Start Android Studio and you will get Blue Stack as emulator when you run your app.
- 关闭 Android Studio。
- 转到 adb.exe 位置。(默认为 C:\Users\Tarun\AppData\Local\Android\sdk\platform-tools)
adb connect localhost:5555
从这个位置运行。- 启动 Android Studio,当您运行您的应用程序时,您将获得 Blue Stack 作为模拟器。
回答by OpenCode
refer intel.com's requirements : Important: Intel HAXM cannot be used on systems without an Intel processor, or with an Intel processor that lacks the hardware features described in the "Hardware Requirements" section above.To determine the capabilities of your Intel processor
请参阅 intel.com 的要求:重要提示:英特尔 HAXM 不能用于没有英特尔处理器的系统,或者英特尔处理器缺少上面“硬件要求”部分中描述的硬件功能。要确定您的英特尔处理器的功能
[Installation Instructions for Intel? Hardware Accelerated Execution Manager ] https://software.intel.com/en-us/android/articles/installation-instructions-for-intel-hardware-accelerated-execution-manager-mac-os-x
[英特尔的安装说明?硬件加速执行管理器] https://software.intel.com/en-us/android/articles/installation-instructions-for-intel-hardware-accelerated-execution-manager-mac-os-x
My PC does not support vt-x, I can not use android studio 1.0.2.
我的电脑不支持 vt-x,我不能使用 android studio 1.0.2。
回答by ludovic
yes is possible to run your android emulator without have a hardware accelerator. In fact to do that, you need to open your android virtual device. When you reached to system image configure, it suggest you which version of android image you want to use. Whatever version of android system image that you select,you need to make sure that,ABI is armeabi-v7aand, you target is System image ameabi-v7a with google APIs. And then complete the rest of task and check out your emulator.
是的,可以在没有硬件加速器的情况下运行您的 android 模拟器。事实上,要做到这一点,你需要打开你的安卓虚拟设备。当您到达系统映像配置时,它会建议您要使用哪个版本的 android 映像。无论您选择什么版本的 android 系统映像,您都需要确保 ABI 是armeabi-v7a,并且您的目标是带有 google API 的系统映像 ameabi-v7a。然后完成其余的任务并检查您的模拟器。