# Install simulator

The Android emulator can be installed on both MacOSX and Windows; the iOS emulator can only be installed on MacOSX.

# ios simulator

MacOSX, to install the ios simulator, you need to install xcode; or search for xcode in the App store to complete the installation.

Open the xcode installation, press the shortcut key command+, to open the Preferences window, as shown below:

In the above window, click [Locations], click [Command Line Tools]

# Run App to iOS Simulator

Project Manager, select the project to be run, click the run icon on the toolbar, as shown below:

The effect of running the app project to the iOS simulator is as follows:

# 运行到iOS模拟器功能限制

iOS模拟器和真机使用不同的CPU架构,部分模块依赖的三方SDK没有包含模拟器或者对模拟器兼容不好,导致无法在模拟器上正常运行,目前已知无法在模拟上使用以下功能:

  • 讯飞语音识别
    由于讯飞语音识别在新版本XCode编译后无法兼容iOS8.x模拟器,HBuilderX1.5及以上版本标准基座模拟器版本不再支持讯飞语音识别功能

注意:2024年3月21日审计云端打包环境为XCode15.2,不再支持讯飞语音识别,推荐使用百度语音识别模块。

  • 直播推流(live-pusher)
    直播推流功能是基于又拍云的推流SDK实现,又拍云的SDK不支持iOS模拟器,标准基座模拟器版本无法运行直播推流相关功能,请使用真机运行体验此功能。

# Android emulator

There are many full-fledged Android emulators on the market, so I won't recommend them here. Search and install by yourself.

Of course, Google officially has its own emulator, you can install different versions of the emulator in Android Studio.

The android studio emulator is shown below:

# Run the App to the Android emulator

After the Android emulator is started, HBuilderX will recognize it as an Android phone named emulator-xxxx, where xxxx is the id of the emulator as shown below:

The effect of running the app project to the android emulator is as follows: