Skip to content

Setup of Other Emulators

TrinityEmulator-Admin edited this page Apr 13, 2022 · 31 revisions

This page instructs you to set up other emulators we compare in our work, including DAOW, Bluestacks, VMWare Workstation, Google Android Emulator, Windows Subsystem of Android, and QEMU-KVM.

This is in case you want to run the experiments on the other emulators to compare the results.

Note that the setup of different emulators can be very different and tricky sometimes, and we may have left out certain details. If you do not wish to go through all the troubles, feel free to skip this. If you encounter some problems not described here, please contact us.

DAOW

  • Download

    Download here: https://www.gameloop.com/product/tencent-gaming-buddy

  • Configurations

    1. First enter settings. Note that before you can edit the settings, you need first to open the Google Play Store app below on the Me page, which will initiate the download of the DAOW engine.

    2. Edit the settings as suggested by the figure below. You need to manually restart DAOW for the settings to come into effect (right-click on the DAOW icon on your Windows Taskbar, click quit and start DAOW again to achieve this).

  • ADB Connection

    1. First you need to make sure adb permission has been turned on as shown in the figure above.

    2. DAOW does not allow conventional adb connections, you need to use the adb.exe executable packed with the binary files (normally in C:/Program Files/TxGameAssistant/ui/adb.exe). However, before you can establish actual connections, you'll have to start some apps first, e.g., Google Play Store.

    3. Establish adb connection through adb.exe connect localhost in Windows Terminal. Here adb.exe is the adb executable found in the former step.

  • Other Notes

    1. You may not find your installed apps anywhere. In this case, start the Google Play Store from DAOW, and then press the back button in the upper right corner as shown below.

Bluestacks

  • Download

    Download here: https://www.bluestacks.com/bluestacks-5.html

  • Configurations

    1. First enter settings.

    2. Edit the settings as suggested by the figure below.

  • ADB Connection

    1. First you need to make sure adb permission has been turned on as shown in the figure above.

    2. Establish connection through adb connect 127.0.0.1:5555.

VMWare Workstation

  • Download

    Download here: https://www.vmware.com/products/workstation-player.html (the Pro edition is also acceptable if you have already purchased it)

  • Configurations

    1. We assume you have some experience using VMWare. In that case, the configurations and installation of Android-x86 on VMWare should be similar to that of a typical Linux distribution (e.g., Ubuntu).

    2. First, download Android-x86_64 7.1.

    3. Create a new virtual machine with the downloaded ISO. During the process, configure the CPU core number to 4, memory to 4 GB, and storage to 64 GB. Also, enable the Accelerate 3D Graphics option in the Display settings. Network Adapter should be left to NAT.

    4. Finish configurations and boot the system. Install Android-x86, follow our guide here.

    5. After installation, you should change Android's screen resolution to 1920x1080 following the steps below.

      • Select the Debug mode boot option.

      • Enter and you'll see terminal-like interface. Type mount -o remount,rw /mnt and vi /mnt/grub/menu.lst

      • Edit configurations in the Vim. Type i to edit, and in the first option insert the phrase video=1920x1080. Then enter ESC and :wq to save the configurations.

      • Enter reboot -f to reboot the system and the resolution setting is done.

    6. After you have booted/installed the system, you may want to turn on Intel Houdini for supporting ARM-based apps. To this end, open the Terminal Emulator app built in the system, enter su and grant the app superuser privileges. And then type enable_nativebridge to turn on Houdini.

  • ADB Connection

    1. Make sure you have turned on and connected to the virtual machine's WiFi.

    2. Since we are behind NAT, you need first to acquire the local IP address by typing ifconfig in the Terminal Emulator app.

    3. Assume your IP address is 10.0.0.1, establish connection through adb connect 10.0.0.1:5555.

Google Android Emulator (GAE)

  • Download

    Google has provided a detailed guide on installing and running GAE, please refer to https://developer.android.com/studio/run/emulator. Generally, you need to install Android Studio to do all the work. But the process is quite simple.

  • Configuration

    1. When creating a virtual device on GAE (guide here), We recommend you choose an Android 11 image as it provides ARM support.
    2. You should configure the hardware profile (click Show advanced settings on the hardware profile configuration page) to a 4-core CPU, 4-GB memory, 64-GB storage, and 1920x108 display.
  • ADB Connection

    ADB connection is automatically established when GAE boots.

Windows Subsystem for Android (WSA)

  • Download

    Follow Microsoft's guide here. Note that you should have a Windows 11 host system and turn on Hyper-V as instructed here.

  • Configuration

    In WSA's settings page, go to developer options and choose the proper GPU for rendering.

  • ADB Connection

    Turn on ADB connection permission in the developer options and you can see the IP address of the ADB server. Use adb connect to connect to the address.

QEMU-KVM

  • Download QEMU-KVM runs only on Linux! Unfortunately, QEMU installed through package management services like apt is old and incomplete. We provide build and installation guide of the latest QEMU with graphics acceleration. Follow the below.

     sudo apt install ninja-build libsdl2-dev libpixman-1-dev libvirglrenderer-dev libepoxy-dev libgbm-dev
     git clone https://gitlab.com/qemu-project/qemu.git
     cd qemu
     git switch stable-5.0
     git submodule init
     git submodule update --recursive
     ./configure --target-list=x86_64-softmmu
     make -j$(nproc)
     sudo make install
    

    Other than QEMU, KVM support is also vital. In terminal type egrep -c '(vmx|svm)' /proc/cpuinfo to check support for KVM (number greater than 0 means KVM support is in place). Type sudo adduser `id -un` kvm to add the user to the KVM group.

  • Configuration

    1. Downlod Android-x86_64 7.1.
    2. Type qemu-img create -f qcow2 hda.img 64G to create an image file alongside the downloaded ISO file.
    3. Run QEMU-KVM with the following command at the directory where you store the IMG and ISO files:
      qemu-system-x86_64 \
      -enable-kvm \
      -m 4096 \
      -smp 4 \
      -cpu host \
      -soundhw hda \
      -machine usb=on -device usb-kbd \
      -serial mon:stdio \
      -boot menu=on \
      -net nic \
      -net user,hostfwd=tcp::5555-:5555 \
      -device virtio-vga,virgl=on \
      -display sdl,gl=on \
      -hda hda.img \
      -cdrom android-x86_64-7.1-r5.iso
      
    4. Install Android-x86, follow our guide here.
    5. Change Android's screen resolution following the step 5 of VMWare's configuration.
    6. After you have booted/installed the system, you may want to turn on Intel Houdini for supporting ARM-based apps. To this end, open the Terminal Emulator app built in the system, enter su and grant the app superuser privileges. And then type enable_nativebridge to turn on Houdini.
  • ADB Connection

    Establish ADB connection through adb connect 127.0.0.1:5555.