What is the Android Emulator?
The Android Development Tools (ADT) include an emulator to run an Android system. The emulator behaves like a real Android device (in most cases) and allows you to test your application without having a real device.You can configure the version of the Android system you would like to run, the size of the SD card, the screen resolution and other relevant settings. You can define several of them with different configurations.
These devices are called Android Virtual Device " and you can start several in parallel.
During the creation of an AVD you decide if
you want an Android
device or a
Google device.
An AVD created for Android will contain the programs from the Android Open Source Project. An AVD created for the Google API's will also contain several Google applications, most notable the Google Maps application.
If you want to use functionality which is only provided via the Google API's, e.g. Google Maps you must run this application on an AVD with Google API's.
An AVD created for Android will contain the programs from the Android Open Source Project. An AVD created for the Google API's will also contain several Google applications, most notable the Google Maps application.
If you want to use functionality which is only provided via the Google API's, e.g. Google Maps you must run this application on an AVD with Google API's.
The following shortcuts are useful for working with the
emulator.
Alt+Enter Maximizes the emulator. Nice for demos.
Ctrl+F11 changes the orientation of the emulator.
F8 Turns network on / off.
Alt+Enter Maximizes the emulator. Nice for demos.
Ctrl+F11 changes the orientation of the emulator.
F8 Turns network on / off.
The graphics of the emulator can use the native GPU of the
computer.
This makes the rendering in the emulator very fast. To enable this,
add the
You can also set the
GPU Emulation
property to the device configuration and set it to
true
.You can also set the
Enabled
flag for Snapshots. This will save the
state of the emulator and will
let it start much faster. Unfortunately currently native GPU
rendering and Snapshots do not work together.
Android 4.0 introduced that devices do not have to have hardware
button anymore. If you want to create such an AVD, add the
Hardware
Back/Home keys
property to the device configuration and set it to
false
.Create and run Android Virtual Device
To define an Android Virtual Device (ADV) open the AVD Manager dialog via → and press button.Enter the values similar to the following screenshot.
Select the Enabled for Snapshots box. This will make the second start of the virtual device much faster.
Press the button. This will create the AVD configuration and display it under the Virtual devices.
To test if your setup is correct, select your device and press the button
After some time your AVD starts. Do not interrupt this startup process, as this might corrupt the AVD.
After the AVD started, you can use the AVD via the mouse and via the virtual keyboard of the emulator.
(vogella.com)