Android developer Guide (15) -- Managing Virtual Devices

Source: Internet
Author: User

Preface

This chapter is the developer Guide/Developing/Managing Virtual Devices, version: Android3.1 r1, translated from: "MeetAndroid", welcome to visit his blog: "http://blog.csdn.net/meetandroid ", thanks again for "MeetAndroid "! We look forward to your participation in translation of Android related information, contact me over140@gmail.com.

 

Statement

You are welcome to repost, but please keep the original source of the article :)

Blog Garden: http://www.cnblogs.com/

Android Chinese translation group: http://goo.gl/6vJQl

Original

Http://developer.android.com/guide/developing/devices/index.html

 

Manage Virtual Devices

An Android Virtual Device (AVD) is a simulator configuration. By defining hardware and software configurations, you can use the Android simulator to simulate an actual device.

The simplest way to create an AVD is to use a graphical AVD manager. You can clickWindow> Android SDK and AVD ManagerYou can also call the Android tool in the tools directory of the android SDK in the command line to start the SDK.

You can also create an AVD by passing appropriate option parameters to the android tool in the command line. For more information about how to use this method to create AVD, see manage virtual devices from the command line.

An AVD consists of the following content:

* Hardware configuration file: it defines the hardware functions of Virtual Devices. For example, you can define whether the device has a camera, whether it uses a physical QWERTY keyboard or dial, How much memory it has, and so on.

* Ing to a system image: You can define the version of the Android platform to be run on a virtual device. You can select a standard Android version or a system image packaged in the SDK append component.

* Other Options: You can specify the skin used when the simulator runs this AVD. It allows you to control the screen size, appearance, and so on. You can also specify the simulated SD card used by AVD.

* A dedicated storage area on the development machine: the user data (installed applications, settings, and so on) and analog SD cards of the device are stored in this area.

You can create multiple avds as needed based on the device type you want to simulate. To thoroughly test the application, you need to create an AVD for each specific device configuration (for example, different screen sizes and platform versions ). Test the application on each AVD to ensure its compatibility.

When selecting a system image for AVD, remember the following points:

* The API Level of the target device is very important because the application cannot run on a system image lower than the required API Level. The minimum API Level required by an application is specified by the minSdkVersion attribute in its manifest file. For more information about the relationship between the system API Level and the minSdkVersion of the application, see the specified minimum system API version.

* Create at least one AVD. The API Level of the target device is higher than that required by the application. This can test the forward compatibility of the application. The forward compatibility test ensures that users who have downloaded your application can receive system updates so that your application can continue to run normally.

* If your application declares the uses-library element in the manifest file, the application can only run in the system image that provides the extension library. If you want to run an application on the simulator, you need to pursue an AVD that contains the required library. Generally, creating such an AVD requires an additional component dedicated to this AVD platform (for example, the Google APIs additional component contains the Google Maps library ).

To learn how to manage AVD using a graphical tool, see manage AVD using the AVD manager. For more information about how to manage AVD in the command line, see manage AVD in the command line.

 

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.