Android Emulator Apple Silicon Preview

No emulators at this point. IntelliJ has some lags in performance on M1 (because it is not native, and Intel built), but feels pretty usable. Yes, Android Studio and the M1 emulator are working. However keep in mind that sometimes Android Studio will start pushing to Swap massively about 1 hour of work in. 我已經在M1 MacBook Air上下載了Android Studio,但無法運行模擬器,這只會給我一個錯誤。我在Mac上搜索Android Studio要求,並說它需要Mac OS 10。.

The recent launch of Android Studio Arctic Fox (2020.3.1) Betahas created an exciting buzz amongst the global developer community. If you want to fetch more insight about this recent release, then keep reading further.

Today, with the help of this blog post, we will be sharing all the official updates that Android IDE has for you. So without any further ado, let’s get started!

The latest release of official Android IDE focuses on-

  • Design
  • Devices
  • Developer Productivity

It is a promising update for the developer community. But this is not all. There are many more improvements and features in the Beta version surrounding these themes. Let us develop a thorough understanding of them.

1. Design

Creating modern User Interfaces with Jetpack Compose has never been easy. But since we now have tools to bridge that gap, we can-

  • Create previews in different configurations
  • Navigate the code with Compose Preview
  • Test it in isolation with Deploy Preview to Device
  • Inspect the entire app with the Layout inspector

One can easily edit strings and numbers throughout the iterations and check updates immediately. With the help of Accessibility Scanner in Layout Editor, View-based layouts can be audited for accessibility problems.

Live Edit of literals- It allows developers to edit literals like numbers, booleans, and strings, in the code. It is easy to view the results instantly, as there is no need to wait for compilation.

Deploy Preview to Device- This feature deploys a snippet of UI to the emulator or device. One can test small parts of the code in the device, and there’s no need to start the complete app.

Accessibility Scanner for Layout Editor- Now, the Android Studio integrates with Android Accessibility Test Framework. This helps in finding accessibility issues in the layouts. While using Layout Editor, one can click on the error report button to launch the panel. It then reports accessibility-related issues and suggests possible fixes.

Compose Preview- It can be used to create previews of Compose UI.

Layout Inspector for Compose- It helps users understand how layouts are rendered on an emulator or running device.

2. Devices

Android app developers can now extend and reimagine apps beyond phones. For example, Google TV, Wear OS, and Android Auto. We now have system images, new emulators, and authentic simulations for different testing scenarios like-

  • The paring of watch and phone emulators with Wear OS Pairing
  • Taking a virtual run with Wear OS heart rate sensors
  • Switching channels with GoogleTV Remote Control
  • Driving with Automotive OS Sensor Replay

New Wear OS System Images- Users can now play and use the latest version of Wear OS.

Wear OS Paring- This guides developers through step-by-step paring of physical/virtual phones with Wear OS emulators directly in Android Studio.

Google TV Remote Control- The updated remote control panel has a mapping for new Google TV remote control features, like settings, user profile.

Heart Rate Sensor for Wear OS Emulators- This feature will help to test the Wear OS applications.

Automotive OS Sensor Replay- It helps in stimulating driving scenarios.

New Google TV System Images- This update helps in freely exploring the User Interface.

3. Developer Productivity

It ensures that the developer’s workspace and environment are completely ready for the latest systems and thoroughly optimized for quality and speed. The platform gives a significant boost to developer’s productivity. With a major update to Intellij 2020.3, developers can now rejoice new improvements and features like-

Android Emulator Apple Silicon Preview
  • Testing app with what Android 12 has to offer
  • Improving app performance with the updated UI for Memory Profiler
  • Understanding background task relationships with WorkManager Inspector
  • Using Non-Transitive R classes IDE Refactoring to increase build speed

Android 12 lint checks- This update offers the right guidance in context, like custom declarations, coarse location permission, media formats, and high sensor sampling rate permission.

IntelliJ Platform Update- It has features like a new Welcome screen, Debugger interactive hints, and various code editor enhancements. These additions will help in speeding up the workflow.

Extended controls in the Emulator tool window- The update is now providing access to all extended emulator controls. With Android Studio, the developers now have efficient tools for testing their applications like snapshots, navigation playback, and virtual sensors.

Android

Apple Silicon Support Preview- Android Studio Arctic Fox provides preview support for the new architecture of macOS on Apple Silicon.

Parallel device testing with Test Matrix- It can be used to run instrumentation tests across multiple devices.

Non-transitive R classes Refactoring- This will initiate faster builds for apps with multiple modules. It also ensures to prevent resource duplication.

Background Task Inspector- It can be used to monitor, visualize, and debug the app’s background workers.

Memory Profiler new recording UI- It can be utilized for different recording activities like native memory allocation, capturing a heap dump.

Download Android Studio Arctic Fox (2020.3.1) Beta and try these features yourself today. Don’t forget to share your experience with us. But until then, for more buzz from the tech world, stay tuned to this space!

Happy reading!

This is the second post that I dedicate to talk about configurations using the new M1 Apple processor. As I said in the previous post, these configurations are workarounds until stable versions are released, however, for me, they have been useful and I guess that someone in the same situation as me can benefit from that.

Using Android studio in the new Macbook Air

Android Emulator Apple Silicon Preview Download

When you install Android Studio you will get the following warning:

Unable to install Intel® HAXM

Your CPU does not support VT-x.

Unfortunately, your computer does not support hardware-accelerated virtualization.

Android emulator apple silicon preview download

Here are some of your options:

1 - Use a physical device for testing

2 - Develop on a Windows/OSX computer with an Intel processor that supports VT-x and NX

3 - Develop on a Linux computer that supports VT-x or SVM

4 - Use an Android Virtual Device based on an ARM system image

(This is 10x slower than hardware-accelerated virtualization)

Creating Android virtual device

Android virtual device Pixel_3a_API_30_x86 was successfully created

And also in the Android virtual device (AVD) screen you will read the following warning:

If you want to learn more regarding virtualization in processors you can read the following Wikipedia article, the thing is that our M1 processor doesn’t support VT-x, however, we have options to run an Android Virtual Device.

As the previous message was telling us, we have 4 options. The easiest way to proceed is to use a physical device, but what if you haven’t one available at the moment you are developing?

From now on, we will go with the option of using an Android virtual device based on an ARM system image as options 2 and 3 are not possible to execute.

Using the virtual emulator

The only thing that you have to do is to download the last available emulator for Apple silicon processors from Github https://github.com/741g/android-emulator-m1-preview/releases/tag/0.2

Once you have downloaded you have to right-click to the .dmg file and click open to skip the developer verification.

After installing the virtual emulator, we have to open it from the Applications menu.

After opening it you will see Virtual emulator in Android Studio available to deploy your Android application. Make sure to have Project tools available in Android Studio (View -> Tool Windows -> Project)

Android Emulator Apple Silicon Preview Software

After pressing the launch button you will get your Android application running in your ARM virtual emulator :-)

Conclusion

Apple Ii Emulator

In this post, we have seen that is possible to install Android Studio in Macbook Air M1 and use a virtual device even that your M1 doesn’t support VT-x. You can learn more about this emulator in the following references: