Create Android Virtual Device

Once you have installed the Android Studio, the first step is creating your Android Virtual Device for testing purposes. Android Studio might create a default virtual device with the latest Android version. Creating another virtual device with a lower version of Android (Usually 2.3.3) is helpful if you have a limited RAM size. Additionally, it is always better to test your applications in both latest and lower versions of Android devices. For example if you are using a very high resolution image in your application, it might work on latest version of Android, but it will throw a java.lang.OutOfMemory in lower version of Android. On the other hand accessing Internet within the main thread is allowed in lower version, but it will throw android.os.NetworkOnMainThreadException from Android 3.0 (Honeycomb). Other than the versions of Android, creating Android Virtual Devices with various device types allows you to test the behavior of your application in different devices.

To create an Android 2.3.3 virtual device, you need to install the required SDK tools first. Open your Android Studio and click on the “Configure” button.


Then click on the “SDK Manager” button.


In the appeared window, install the necessary tools you need for development. To install the Android 2.3.3, select the following items and install them.

  • SDK Platform
  • Intel x86 Atom System Image
  • Google APIs (Optional)

After the installation, select the “Manage AVDs...” from the Tools menu of SDK Manager.



In the appeared window click on the “Create” button.
In the “Create new Android Virtual Device” window, fill the following details and click OK.
If you have installed the "Intel x86 Emulator Accelerator (HAXM Installer)", selecting the x86 CPU will give you a high performance.


If there are any information message shown, just click OK and continue.


In the list of Android virtual devices, select the device which you have created and click on the Start button. In the appeared window just click “Launch” and wait until your device become available.



Now you are ready to develop and test your Android applications.
Previous
Next Post »

Contact Form

Name

Email *

Message *