Programming Tutorials

Android Emulator

By: Ashley in Android Tutorials on 2011-08-12  

The difference between Emulator and Simulator

A simulator represents the real world object. It does the act of imitating the process by giving false appearance.  It is able to achieve this by using mathematical models and computer programs such as FlightSim, NS2.

An emulator performs exactly the same way as real. Example emulators are Xen, Qemu, VirtualBox, Wine.

What is QEMU?

QEMU is an Open source process emulator. It does CPU emulation of IA-32, x86-64, PPC, ARM, MIPS and SPARC. It emulates the full system. Able to run unmodified guest OS. Also able to run programs which are compiled for different architecture. Supported devices are HDD(COW), CDD, NIC, Sound, USB, SMB server, port redirection etc.

Android Emulator is based on QEMU emulator designed for virtual ARMv5 CPU with MMU. It has a 16bit LCD, a keyboard, Sound IO, flash memory partition (file image) and a GSM modem with simulated SIM. It runs full stack (kernel to Apps). It does dynamic binary translation from ARMv5 to x86.

Android Emulator is part of Android SDK. So you don't have to download it seperately. It can be used for application development to do prototypes, develop and test without the physical device. It supports AVD (Android Virtual Device) to emulate different hardware configurations, different software features and different skins. Regular keyboard and mouse can be used.

While running an android application on an Android emulator, application can use services, invoke other applications, access the network, play audio and video files, store and retrieve data, notify user, render graphical transitions and set different themes.

Android emulator also has debugging support for the following:

  • Log Kernel Output
  • Log Application output
  • Simulate application interrupts (SMS/Call arrival)
  • Simulate latency effects
  • simulate data loss

ADB is the Android Debugging Bridge which handles emulator as a real device and can handle multiple devices.

Starting android emulator

  • $android  (Start the AVD Manager)
  • $emulator -avd <avd-name>
  • You can also start it from eclipse by running your application.





Add Comment

* Required information
1000

Comments

No comments yet. Be the first!

Most Viewed Articles (in Android )

Is it safe to delete userdata-qemu.img userdata-qemu.img.qcow2 files

Performing Streamed Install adb: failed to install app buildoutputsapkdebugapp-debug.apk: Exception occurred while executing 'install': android.os.ParcelableException: java.io.IOException: Requested internal only, but not enough space

adb.exe: no devices/emulators found

compileSdkVersion vs buildToolsVersion in app/build.gradle

Emulator: WARNING | *** No gRPC protection active, consider launching with the -grpc-use-jwt flag.***

Reading and Writing a file to SD card sample program in Android

'adb' is not recognized as an internal or external command, operable program or batch file.

Progress bar and downloading a file sample program in Android

How to start the Android emulator

Intent in Android to call one activity from another activity.

Android Preferences - Using Preferences in Android Tutorial

Getting Started with Android

gradle build failed Caused by: java.lang.NoClassDefFoundError: javax/xml/bind/annotation/XmlSchema

Get Location of an android phone programmatically

Gallery sample program in Android

Latest Articles (in Android)

Keep your android phone awake while debugging

compileSdkVersion vs buildToolsVersion in app/build.gradle

gradle build failed Caused by: java.lang.NoClassDefFoundError: javax/xml/bind/annotation/XmlSchema

Gradle, npm, react-native - How are they related?

Emulator: glTexImage2D: got err pre :( 0x506 internal 0x8058 format 0x1908 type 0x1401

Emulator: WARNING | *** No gRPC protection active, consider launching with the -grpc-use-jwt flag.***

./gradlew assembleDebug '.' is not recognized as an internal or external command, operable program or batch file.

'adb' is not recognized as an internal or external command, operable program or batch file.

Performing Streamed Install adb: failed to install app buildoutputsapkdebugapp-debug.apk: Exception occurred while executing 'install': android.os.ParcelableException: java.io.IOException: Requested internal only, but not enough space

Is it safe to delete userdata-qemu.img userdata-qemu.img.qcow2 files

adb.exe: no devices/emulators found

How to start the Android emulator

Get Location of an android phone programmatically

Getting Started with Android

Solution to error: unable to open connection to server due to security error

Related Tutorials

Keep your android phone awake while debugging

compileSdkVersion vs buildToolsVersion in app/build.gradle

gradle build failed Caused by: java.lang.NoClassDefFoundError: javax/xml/bind/annotation/XmlSchema

Gradle, npm, react-native - How are they related?

Emulator: glTexImage2D: got err pre :( 0x506 internal 0x8058 format 0x1908 type 0x1401

Emulator: WARNING | *** No gRPC protection active, consider launching with the -grpc-use-jwt flag.***

./gradlew assembleDebug '.' is not recognized as an internal or external command, operable program or batch file.

'adb' is not recognized as an internal or external command, operable program or batch file.

Performing Streamed Install adb: failed to install app buildoutputsapkdebugapp-debug.apk: Exception occurred while executing 'install': android.os.ParcelableException: java.io.IOException: Requested internal only, but not enough space

Is it safe to delete userdata-qemu.img userdata-qemu.img.qcow2 files

adb.exe: no devices/emulators found

How to start the Android emulator

Get Location of an android phone programmatically

Getting Started with Android

Solution to error: unable to open connection to server due to security error