Android 4.

0 Compatibility Definition
Revision 1 Last updated: November 22, 2011 Copyright © 2011, Google Inc. All rights reserved. compatibility@android.com

Table of Contents
1. Introduction 2. Resources 3. Software 3.1. Managed API Compatibility 3.2. Soft API Compatibility 3.2.1. Permissions 3.2.2. Build Parameters 3.2.3. Intent Compatibility 3.2.3.1. Core Application Intents 3.2.3.2. Intent Overrides 3.2.3.3. Intent Namespaces 3.2.3.4. Broadcast Intents 3.3. Native API Compatibility 3.3.1 Application Binary Interfaces 3.4. Web Compatibility 3.4.1. WebView Compatibility 3.4.2. Browser Compatibility 3.5. API Behavioral Compatibility 3.6. API Namespaces 3.7. Virtual Machine Compatibility 3.8. User Interface Compatibility 3.8.1. Widgets 3.8.2. Notifications 3.8.3. Search 3.8.4. Toasts 3.8.5. Themes 3.8.6. Live Wallpapers 3.8.7. Recent Application Display 3.8.8. Input Management Settings 3.9 Device Administration 3.10 Accessibility 3.11 Text-to-Speech 4. Application Packaging Compatibility 5. Multimedia Compatibility 5.1. Media Codecs 5.2. Video Encoding 5.3. Audio Recording 5.4. Audio Latency 5.5. Network Protocols 6. Developer Tool Compatibility 7. Hardware Compatibility 7.1. Display and Graphics 7.1.1. Screen Configuration 7.1.2. Display Metrics 7.1.3. Screen Orientation 7.1.4. 2D and 3D Graphics Accleration 7.1.5. Legacy Application Compatibility Mode 7.1.6. Screen Types 7.1.7. Screen Technology 7.2. Input Devices 7.2.1. Keyboard 7.2.2. Non-touch Navigation 7.2.3. Navigation keys 7.2.4. Touchscreen input 7.3. Sensors 7.3.1. Accelerometer 7.3.2. Magnetometer 7.3.3. GPS 7.3.4. Gyroscope

7.3.5. Barometer 7.3.6. Thermometer 7.3.7. Photometer 7.3.8. Proximity Sensor 7.4. Data Connectivity 7.4.1. Telephony 7.4.2. IEEE 802.11 (WiFi) 7.4.3. Bluetooth 7.4.4. Near-Field Communications 7.4.5. Minimum Network Capability 7.5. Cameras 7.5.1. Rear-Facing Camera 7.5.2. Front-Facing Camera 7.5.3. Camera API Behavior 7.5.4. Camera Orientation 7.6. Memory and Storage 7.6.1. Minimum Memory and Storage 7.6.2. Application Shared Storage 7.7. USB 8. Performance Compatibility 9. Security Model Compatibility 9.1. Permissions 9.2. UID and Process Isolation 9.3. Filesystem Permissions 9.4. Alternate Execution Environments 10. Software Compatibility Testing 10.1. Compatibility Test Suite 10.2. CTS Verifier 10.3. Reference Applications 11. Updatable Software 12. Contact Us Appendix A - Bluetooth Test Procedure

"may" and "optional" is per the IETF standard defined in RFC2119 [Resources. 5.com/guide/developing/tools/index. note that certain component substitutions and modifications are explicitly forbidden by this document.android.html 36. ambiguous. Introduction This document enumerates the requirements that must be met in order for devices to be compatible with Android 4.txt Android Compatibility Program Overview: http://source.android.com/reference/android/content/pm/PackageManager.com/reference/android/os/Build.html R. "should".android. the Android Open Source Project [ Resources.com/guide/topics/manifest/manifest-intro.html#offline HTML5 video tag: http://dev. While some components can hypothetically be replaced with alternate implementations this practice is strongly discouraged. A "device implementation" or "implementation" is the hardware/software solution so developed.html 40. 2.com/reference/android/webkit/WebView. 3.com/reference/android/accessibilityservice/package-summary.html Android 4.com/guide/topics/ui/notifiers/notifications.com/guide/topics/admin/device-admin.android.html Hardware Acceleration: http://developer. 2. 11.html Android Permissions reference: http://developer. 29.android. 12. 10.android.html 33. ddms): http://developer. 26.com/guide/practices/ui_guidelines/widget_design.html android.android.content.com/reference/android/content/res/Configuration.android.html Android Open Source Project: http://source.html Android Device Administration: http://developer. 18.html Notifications: http://developer.android.android. Monkey testing tool: http://developer.html android. To be considered compatible with Android 4.style. 30.com/compatibility/4.android.content.com/reference/android/app/SearchManager.html Themes: http://developer.com/reference/android/view/accessibility/packagesummary.android. 15. "required".com/reference/android/speech/tts/package-summary.DisplayMetrics: http://developer. Android android. As used in this document.html 35.android.android.com/guide/practices/screens_support. IETF RFC2119 Requirement Levels: http://www.WebView class: http://developer.html Status Bar icon style guide: http://developer. "should not".com/reference/android/Manifest.org/html5/spec/Overview.com/compatibility/index.html Live Wallpapers: http://developer.app. Manifest files: http://developer. "recommended".html 37.w3.w3.1.android.w3. Text-To-Speech APIs: http://developer. 24.com/ API definitions and documentation: http://developer. 23.html HTML5: http://www.html android.android.html#statusbarstructure Search Manager: http://developer.org/rfc/rfc2119.android. 6. 16.com/guide/topics/graphics/renderscript.com/reference/android/widget/Toast.android. Eyes Free project: http://code.android.w3. 3] is both the reference and preferred implementation of Android.android.html . For this reason. Reference tool documentation (for adb.com/reference/packages.org/TR/geolocation-API/ HTML5/W3C webdatabase API: http://www. device implementations MUST meet the requirements presented in this Compatibility Definition.android. Android apk file description: http://developer.com/android/reference/available-resources. it is the responsibility of the device implementer to ensure compatibility with existing implementations. as passing the software tests will become substantially more difficult.pm.com/guide/practices/ui_guideline /icon_design.com/p/eyes-free 32. "must not".Configuration: http://developer. 21.google. 9. aapt.org/TR/webdatabase/ HTML5/W3C IndexedDB API: http://www. Supporting Multiple Screens: http://developer.PackageManager class and Hardware Features List: http://developer. android.com/reference/android/util/DisplayMetrics. Resources 1. The use of "must".google. "shall not". 19.org/specs/web-apps/current-work/multipage/ HTML5 offline capabilities: http://dev.html 34.html 38.html Renderscript: http://developer.com/guide/topics/ui/themes.html Toasts: http://developer. Where this definition or the software tests described in Section 10 is silent. or incomplete. 22. Finally. 20. including and beyond the Compatibility Test Suite.android.webkit. 14. 1].com/guide/topics/graphics/hardware-accel.0.html Android Accessibility Service APIs: http://developer. 17.android. 4.DevicePolicyManager class: http://developer. android.html Android Accessibility APIs: http://developer.android. including any documents incorporated via reference.html 31.w3.res.ietf.html Application Resources: http://code.com/guide/topics/fundamentals.com/reference/android/app/admin/DevicePolicyManager.os.0.whatwg.android.com/reference/android/R.org/TR/IndexedDB/ Dalvik Virtual Machine specification: available in the Android source code. Device implementers are strongly encouraged to base their implementations to the greatest extent possible on the "upstream" source code available from the Android Open Source Project.style class: http://developer. 13. 8. 25. "shall". 7.0 allowed version strings: http://source. 27.org/html5/spec/Overview.Build reference: http://developer.com/guide/developing/tools/monkey. at dalvik/docs AppWidgets: http://developer.html 39.com/resources/articles/live-wallpapers.0/versions.android.android. a "device implementer" or "implementer" is a person or organization developing a hardware/software solution running Android 4.0.permission.admin.android. 28.android.util.html#video HTML5/W3C geolocation API: http://www. It is the implementer's responsibility to ensure full behavioral compatibility with the standard Android implementation.android.

com/reference/android/hardware/Camera.DownloadManager class: http://developer.pdf MIFARE MF1S503X: http://www. The Android application programming interface (API) is the set of Android platform interfaces exposed to applications running in the managed VM environment.com/guide/appendix/media-formats.google. or include no-ops. Android also includes a significant runtime-only "soft" API.android. Managed API Compatibility The managed (Dalvik-based) execution environment is the primary vehicle for Android applications.html#setDisplayOrientation(int) android.Build.hardware.pdf Camera orientation API: http://developer. 7]. For Android 4.0 SDK [Resources.1.html 59.android.pdf MIFARE MF0ICU1: http://www.Camera: http://developer.os.com/reference/android/hardware/Camera.pdf MIFARE AN130511: http://www. Android Media Formats: http://developer.html Android Open Accessories: http://developer. 3.VERSION.2. This value MUST NOT be re-used for different builds made android.com/filetransfer 58.android.nxp.android. and similar aspects of Android applications that cannot be enforced at application compile time.0. this field MUST have the integer value 14.com/documents/data_sheet/MF1S703x. 43.com/p/apps-for-android 56. this field MUST have the integer value 14. Parameter android. 52. For Android 4. 42. in human-readable format. in a format accessible to third-party application code.RELEASE Comments The version of the currently-executing Android system.ietf. This field MUST have one of the string values defined in [Resources. 48. including all documented behaviors. 5]. 53. 6] that are intended to describe the current device.html Bluetooth API: http://developer.1. 3. the APIs MUST still be present and behave in a reasonable way.SDK android.android. Permissions Device implementers MUST support and enforce all permission constants as documented by the Permission reference page [Resources.VERSION. in the form of such things such as Intents.html 57.SensorEvent: http://developer.Build class [Resources. To provide consistent. of any documented API exposed by the Android 4. A value chosen by the device implementer designating the specific build of the currently-executing Android system.android. Android File Transfer: http://www.app.com/documents/application_note/AN130511.Build. Software 3. 54. the table below includes additional restrictions on the formats of these values to which device implementations MUST conform.nxp. See Section 7 for specific requirements for this scenario. 3. 44.html USB Host API: http://developer.html Android Security and Permissions reference: http://developer.nxp.pdf MIFARE AN130411: http://www. Device implementations MUST NOT omit any managed APIs.41.nxp. android. deviate from the documented behavior.com/guide/topics/usb/host.os. 3. 47. The version of the currently-executing Android system.2. In any cases where this Compatibility Definition or the Compatibility Test Suite disagrees with the SDK documentation. permissions.Build.os.com/documents/data_sheet/MF1S503x.android. android. 45. This Compatibility Definition permits some types of hardware for which Android includes APIs to be omitted by device implementations. Note that Section 10 lists additional requirements related to the Android security model. 49.com/reference/android/app/DownloadManager. 55.pdf MIFARE MF0ICU2: http://www.com/reference/android/bluetooth/package-summary. the SDK documentation is considered authoritative.com/reference/android/hardware/SensorEvent.android.SDK_INT .org/html/draft-pantos-http-live-streaming-03 Many of these resources are derived directly or indirectly from the Android 4. 4].com/documents/data_sheet/MF0ICU1.2.3. HTTP Live Streaming Draft Protocol: http://tools.os.VERSION.pdf MIFARE MF1S703X: http://www.nxp.com/documents/application_note/AN130411.html NDEF Push Protocol: http://source.0. 46.com/guide/topics/security/security.nxp. alter API interfaces or signatures.android. In such cases. 51.android. Device implementations MUST provide complete implementations. in a format accessible to third-party application code. Build Parameters The Android APIs include a number of constants on the android.hardware.html Apps for Android: http://code. meaningful values across device implementations. and will be functionally identical to the information in that SDK's documentation. Any technical details provided in the references included above are considered by inclusion to be part of this Compatibility Definition.com/compatibility/ndef-push-protocol.com/documents/short_data_sheet/MF0ICU2_SDS. The version of the currently-executing Android system. Soft API Compatibility In addition to the managed APIs from Section 3.com/guide/topics/usb/accessory.android.0 SDK. 50. in human-readable format. except where specifically allowed by this Compatibility Definition.1.

Build.PRODUCT android. There are no requirements on the specific format of this field.os._-]+$". For example. "userdebug"._-]+$". A comma-separated list of tags chosen by the device implementer that further distinguish the build. See Section 3._-]+$".Build.Build._-]+$".Build.os. The value of this field MUST be encodable as 7-bit ASCII and match the regular expression "^[a-zA-Z0-9. The value of this field MUST be encodable as 7-bit ASCII and match the regular expression "^[a-zA-Z0-9. The value of this field MUST be encodable as 7-bit ASCII and match the regular expression "^[a-zA-Z0-9._-]+$". who produced the device.2.CPU_ABI2 android. except that it MUST NOT be null or the empty string (""). There are no requirements on the specific format of this field. but SHOULD be a value sufficiently meaningful for end users to distinguish between software builds. The value of this field MUST be encodable as 7-bit ASCII and match the regular expression "^[a-zA-Z0-9.INCREMENTAL available to end users. android.MODEL android..3: Native API Compatibility. A value chosen by the device implementer identifying the specific configuration or revision of the body (sometimes called "industrial design") of the device. "unsigned.os. except that it MUST NOT be null or the empty string ("").Build.os.debug".Build.. The name of the second instruction set (CPU type + ABI convention) of native code. organization. A possible use of this field is to indicate the OEM and/or carrier who sold the device.3. This field can be the same as android. . The trade name of the Original Equipment Manufacturer (OEM) of the product. There are no requirements on the specific format of this field. The value of this field MUST be encodable as 7-bit ASCII and match the regular expression "^([a-zA-Z0-9]{0. A value chosen by the device implementer identifying the name of the company.Build.BOARD android. A string that uniquely identifies this build.MANUFACTURER android.os. A value chosen by the device implementer containing the development name or code name of the product (SKU).20})$".os.DEVICE android..Build.Build.USER 3.BRAND android. except that it MUST NOT be null or the empty string ("").os. By "honored". Intent Compatibility Device implementations MUST honor Android's loose-coupling Intent system. A value chosen by the device implementer identifying the specific internal hardware used by the device.os.VERSION. or "eng". if available. The value of this field MUST be encodable as 7-bit ASCII and match the regular expression "^[a-zA-Z0-9.Build. android. MUST be human-readable. in human readable format. There are no requirements on the specific format of this field. The value of this field MUST be encodable as 7-bit ASCII and match the regular expression "^[a-zA-Z09. It MUST follow this template: $(BRAND)/$(PRODUCT)/$(DEVICE):$(VERSION. in human-readable format. It SHOULD be reasonably humanreadable.os. but is not necessarily intended for view by end users. An identifier chosen by the device implementer to refer to a specific release._-]+$". individual.Build.0/IRK77/3359:userdebug/test-keys The fingerprint MUST NOT include whitespace characters.Build.android. A value representing the timestamp of when the build occurred. such as the underscore ("_") character. A value chosen by the device implementer specifying the runtime configuration of the build. See Section 3.INCREMENTAL):$(TYPE)/$(TAGS) android..os. The value of this field MUST be encodable as 7-bit ASCII.Build.TAGS android._-]+$".TYPE android.os.CPU_ABI android.ID android. There are no requirements on the specific format of this field. A string that uniquely identifies the host the build was built on.os. The value of this field MUST be encodable as 7-bit ASCII and match the regular expression "^[a-zA-Z0-9.Build.Build.HOST android.VERSION.os. they MUST be replaced in the build fingerprint with another character.HARDWARE android.Build. If other fields included in the template above have whitespace characters.Build. except that it MUST NOT be null or the empty string ("")..os.SERIAL A hardware serial number.._-]+$". The name of the instruction set (CPU type + ABI convention) of native code.os. The name of the hardware (from the kernel command line or /proc).RELEASE)/$(ID)/$(VERSION.. A value chosen by the device implementer containing the name of the device as known to the end user.FINGERPRINT For example: acme/mydevice/generic:4. A name or user ID of the user (or automated user) that generated the build. It SHOULD be reasonably human-readable. A possible use of this field is to indicate the specific revision of the board powering the device. etc.INCREMENTAL.TIME android. as described in the sections below. it is meant that the device implementer MUST provide an Android Activity or Service that specifies a matching Intent filter and binds to and implements correct behavior for each specified Intent pattern. in human readable format.os. The value of this field MUST be encodable as 7-bit ASCII and match the regular expression "^[a-zA-Z0-9..3: Native API Compatibility.Build.os. A typical use of this field is to indicate which build number or source-control change identifier was used to generate the build.os.os. except that it MUST NOT be null or the empty string (""). This SHOULD be the same name under which the device is marketed and sold to end users.Build. in human-readable format. This field SHOULD have one of the values corresponding to the three typical Android runtime configurations: "user".

1. such as contacts. or may have the value "true". 3.3.3. the attribute "android:exported" may be absent. the device implementation MUST support all Intent patterns defined by each core Android system app being replaced. via the android. 3. CATEGORY.3. any such alternative versions MUST honor the same Intent patterns provided by the upstream project. If a device implementation includes support for an Android ABI.3. For every Activity or Service defined in one of the core Android system apps that is not marked as non-public via an android:exported attribute with the value "false". However. if it does.* namespace. 3. Broadcast Intents Third-party applications rely on the platform to broadcast certain Intents to notify them of changes in the hardware or software environment.3. it SHOULD implement compatibility with the Android NDK. 3. That is. using the standard Java Native Interface (JNI) semantics. CATEGORY.txt.e. or prevent third-party applications from binding to and assuming control of these patterns. a device implementation MAY replace core Android system apps.so file compiled for the appropriate device hardware architecture.2. and so on. it must still honor the Intent pattern issued by third-party applications to pick a song.3. Broadcast Intents are described in the SDK documentation. device implementations MUST allow each Intent pattern referenced in Section 3.apk file as an ELF . device implementations MUST include a compontent of the same type implementing the same Intent filter patterns as the core Android system app. MUST be source-compatible (i. Android-compatible devices MUST broadcast the public broadcast Intents in response to appropriate system events. Device implementations MAY include Intent patterns using namespaces clearly and obviously associated with their own organization.os. This prohibition is analogous to that specified for Java language classes in Section 3. if a device contains an alternative music player. Android defines a number of Application Binary Interfaces (ABIs) in the Android NDK.CPU_ABI API . or Service components that are considered "public". As native code is highly dependent on the underlying processor technology.Build. calendar.2.3. The following applications are considered core Android system applications: Desk Clock Browser Calendar Contacts Gallery GlobalSearch Launcher Music Settings The core Android system applications include various Activity. in the file docs/CPU-ARCH-ABIS. or other key string in the android.3. however.2. Device implementers MAY replace these applications with alternative versions. In other words. Intent Overrides As Android is an extensible platform. Device implementers MUST NOT alter or extend any of the Intent patterns used by the core apps listed in Section 3. Native API Compatibility 3.* or com.6. For example.3. header compatible) and binary-compatible (for the ABI) with each required library in the list below MUST accurately report the native Application Binary Interface (ABI) supported by the device. or other key string in a package space belonging to another organization.1. Core Application Intents The Android upstream project defines a number of core applications. it: MUST include support for code running in the managed environment to call into native code.2.2 to be overridden by third-party applications. If a device implementation is compatible with one or more defined ABIs. device implementers MUST NOT attach special privileges to system applications' use of these Intent patterns.4.1 Application Binary Interfaces Managed code running in Dalvik can call into native code provided in the application .3. Intent Namespaces Device implementations MUST NOT include any Android component that honors any new Intent or Broadcast Intent patterns using an ACTION. Device implementers MUST NOT include any Android components that honor any new Intent or Broadcast Intent patterns using an ACTION.2.android. as below.2.2. The upstream Android open source implementation allows this by default. This prohibition specifically includes but is not limited to disabling the "Chooser" user interface which allows the user to select between multiple applications which all handle the same Intent pattern. music player. photo gallery.

and SHOULD support the HTML5/W3C IndexedDB API [Resources.webkit.Build. Device implementers MAY include customizations to the WebKit implementation. Native code compatibility is challenging.txt SHOULD be built using the source code and header files available in the upstream Android open source project The following native code APIs MUST be available to apps that include native code: libc (C library) libm (math library) Minimal support for C++ JNI interface liblog (Android logging) libz (Zlib compression) libdl (dynamic linker) libGLESv1_CM. Specifically: Device implementations' android. $(LOCALE).WebView component provided to third-party applications MUST be based on WebKit. in the file docs/CPU-ARCHABIS. 14] Additionally. Implementations MAY ship a custom user agent string in the standalone Browser application.1 audio support) libandroid.0. 3.Build. including rendering behavior. device implementations MUST support the HTML5/W3C webstorage API [ Resources. unless the developer explicitly enables them via the usual Android APIs. 13] geolocation [Resources. HTML5 APIs. The user agent string reported by the WebView MUST be in this format: Mozilla/5.os.so (native Android activity support) Support for OpenGL. WebView Compatibility The Android Open Source implementation uses the WebKit rendering engine to implement the android.0 (Linux.WebView. the android. even if an alternate Browser application is used.30 The value of the $(VERSION) string MUST be the same as the value for android. device implementations MUST support each of these APIs associated with HTML5 in the WebView: application cache/offline operation [Resources.MUST report only those ABIs documented in the latest version of the Android NDK. This build includes a specific set of functionality and security fixes for the WebView. as described in Section 3.webkit.ID The WebView component SHOULD include support for as much of HTML5 [ Resources. it should be repeated that device implementers are VERY strongly encouraged to use the upstream implementations of the libraries listed above to help ensure compatibility. $(MODEL) Build/$(BUILD)) AppleWebKit/534. and SHOULD refer to the current configured locale of the device The value of the $(MODEL) string MUST be the same as the value for android.so (OpenSL ES 1. it MUST NOT report support for any ABI at all. 16]. For this reason.so libOpenSLES.so (native OpenGL surface management) libjnigraphics.os. device implementers MUST use the specific upstream build of WebKit in the WebView implementation.WebView implementations MUST be based on the 534. like all JavaScript APIs.so (OpenMAX AL 1.so (OpenGL ES 1.os. If a device implementation is not compatible with an existing predefined ABI. MUST be disabled by default in a WebView.4. any such customizations MUST NOT alter the behavior of the WebView. Note that as the web development standards bodies are transitioning to favor IndexedDB over webstorage. The standalone Browser MAY be based on a browser technology other than WebKit. 11] as possible. 15].VERSION.0) libGLESv2.0 Mobile Safari/534.4. Because it is not feasible to develop a comprehensive test suite for a web rendering system. however. Minimally.0) libEGL.4.30 WebKit build from the upstream Android Open Source tree for Android 4. Android $(VERSION). 12] the <video> tag [Resources. Web Compatibility 3. as described below Note that future releases of the Android NDK may introduce support for additional ABIs.1. .RELEASE The value of the $(LOCALE) string SHOULD follow the ISO conventions for country code and language. However.so (OpenGL ES 2.MODEL The value of the $(BUILD) string MUST be the same as the value for android. IndexedDB is expected to become a required component in a future version of Android.4.2. 3.webkit. Browser Compatibility Device implementations MUST include a standalone Browser application for general user web browsing.Build.1.0. like Gecko) Version/4.30 (KHTML. U.1 audio support) libOpenMAXAL.0.

and SHOULD support the HTML5/W3C IndexedDB API [Resources. To ensure compatibility with third-party applications. or adding a new API). but such modifications MUST NOT impact the stated behavior and Java-language signature of any publicly exposed APIs.google. but not all. 3. and web) must be consistent with the preferred implementation of the upstream Android open source project [Resources.com and begin the process for contributing changes and code.7. ContentProvider. 3.* or similar namespace. The Compatibility Test Suite (CTS) tests significant portions of the platform for behavioral compatibility.* sun. device implementers MUST NOT make any prohibited modifications (see below) to these package namespaces: java. Additionally.5. those APIs MUST be packaged in an Android shared library so that only apps that explicitly use them (via the <uses-library> mechanism) are affected by the increased memory usage of such APIs. Device implementers MAY make internal-only modifications. Device implementers MAY add custom APIs. device implementers MUST NOT expose new APIs or alter existing APIs in the namespaces noted above. Device implementers MUST NOT add any publicly exposed elements (such as classes or interfaces. If a device implementer proposes to improve one of the package namespaces above (such as by adding useful new functionality to an existing API. Note that as the web development standards bodies are transitioning to favor IndexedDB over webstorage. native.* javax. soft. For instance.* com. 13] geolocation [Resources.android. 15]. device implementers MUST NOT add APIs to the com. or fields or methods to existing classes or interfaces) to the APIs above. but any such APIs MUST NOT be in a namespace owned by or referring to another organization. this section simply aims to reinforce those conventions and make them binding through inclusion in this compatibility definition. but those modifications MUST NOT be advertised or otherwise exposed to developers. Virtual Machine Compatibility Device implementations MUST support the full Dalvik Executable (DEX) bytecode specification and Dalvik Virtual Machine semantics [Resources. only Google may do so. device implementations MUST support each of these APIs associated with HTML5: application cache/offline operation [Resources. (See Section 7. or by removing classes or class fields. API Behavioral Compatibility The behaviors of each of the API types (managed.* android.1. 14] Additionally. Minimally. device implementations MUST support the HTML5/W3C webstorage API [ Resources. 11] as possible. Device implementations MUST configure Dalvik to allocate memory in accordance with the upstream Android platform. Some specific areas of compatibility are: Devices MUST NOT change the behavior or semantics of a standard Intent Devices MUST NOT alter the lifecycle or lifecycle semantics of a particular type of system component (such as Service. 3. Similarly. For this reason.) . Device implementers MAY modify the underlying implementation of the APIs. Google MUST NOT add APIs to other companies' namespaces.android. the implementer SHOULD visit source. 17].6.1 for screen size and screen density definitions. Activity. 16]. and as specified by the following table. 3]. API Namespaces Android follows the package and class namespace conventions defined by the Java programming language. if a device implementation includes custom APIs outside the standard Android namespace. IndexedDB is expected to become a required component in a future version of Android. It is the responsibility of the implementer to ensure behavioral compatibility with the Android Open Source Project. 12] the <video> tag [Resources. etc. device implementers SHOULD use the source code available via the Android Open Source Project where possible. A "publicly exposed element" is any construct which is not decorated with the "@hide" marker as used in the upstream Android source code.) Devices MUST NOT change the semantics of a standard permission The above list is not comprehensive.The standalone Browser application (whether based on the upstream WebKit Browser application or a third-party replacement) SHOULD include support for as much of HTML5 [Resources. rather than re-implement significant parts of the system. In other words. according to the information on that site. Note that the restrictions above correspond to standard conventions for naming APIs in the Java programming language.* Prohibited modifications include: Device implementations MUST NOT modify the publicly exposed APIs on the Android platform by changing any method or class signatures.

Themes . 21]. Device implementations MUST properly display and execute rich notifications. Additionally. Device implementations MUST implement the APIs that allow developers to reuse this user interface to provide search within their own applications. User Interface Compatibility 3. 18].Note that memory values specified below are considered minimum values. the default behavior SHOULD be to display web search engine results and suggestions. If no third-party applications are installed that make use of this functionality. and allow developers to supply results to the common global search user interface.4. sound files. 3. and to the extent possible with the device implementation hardware. system-wide user interface that allows users to enter queries. 22] that allow developers to incorporate search into their applications.5. For instance. view.8. etc. Android 4. and device implementations MAY allocate more memory per application. displays suggestions as users type. Screen Size small / normal / large small / normal / large small / normal / large xlarge xlarge xlarge Screen Density ldpi / mdpi tvdpi / hdpi xhdpi mdpi tvdpi / hdpi xhdpi Application Memory 16MB 32MB 64MB 32MB 64MB 128MB 3. Device implementations MUST display Toasts from applications to end users in some high-visibility manner. however. Device implementers MAY provide an alternative user experience for notifications than that provided by the reference Android Open Source implementation.0 includes support for rich notifications.8. it MUST correctly implement the vibration APIs. Device implementations MUST implement the APIs that allow third-party applications to add suggestions to the search box when it is run in global search mode. as above. (See the App Widget Design Guidelines in the Android SDK documentation [Resources. 3. that disappear after a brief period of time. Device implementations MUST include a single. and remove AppWidgets. configure. Device implementations MAY substitute an alternative to the reference Launcher (i. 23]) to display short non-modal strings to the end user. 18] for details.2. If a device implementation lacks hardware. and remove AppWidgets directly within the Launcher. view. view. The Android APIs allow developers to reuse this interface to provide search within their own apps. such as interactive Views for ongoing notifications.8. the corresponding APIs MUST be implemented as no-ops. if they are omitted. Alternative Launchers SHOULD include built-in support for AppWidgets. such alternative notification systems MUST support existing notification resources.8. The Android Open Source reference release includes a Launcher application that includes user interface affordances allowing the user to add. Device implementations MUST support notifications that use hardware features. using hardware and software features of the device. 3. 3.8. or in the Status/System Bar icon style guide [ Resources. and remove AppWidgets from the home screen. configure. Widgets Android defines a component type and corresponding API and lifecycle that allows applications to expose an "AppWidget" to the end user [Resources. vibration. system-wide search user interface capable of real-time suggestions in response to user input. Toasts Applications can use the "Toast" API (defined in [Resources. Some APIs allow applications to perform notifications or attract attention using hardware. and light. the implementation MUST correctly render all resources (icons. specifically sound. and expose user interface affordances to add. this functionality consists of a single.8. Alternative Launchers MAY omit these user interface elements. Note that this behavior is further detailed in Section 7. home screen). as documented in the Android APIs. as described in the SDK documentation. Notifications Android includes APIs that allow developers to notify users of notable events [ Resources. Search Android includes APIs [Resources. and displays results. Generally speaking.3. 19]. however. if a device implementation includes a vibrator. and expose their application's data into the global system search. Device implementations must be capable of rendering widgets that are 4 x 4 in the standard grid size.) provided for in the APIs [Resources.e. the device implementation MUST provide a separate application accessible from the Launcher that allows users to add. 20].1. shared.

. Device implementations MUST support third party accessibility service implementations through the android. Device implementations MAY alter or eliminate this user interface. 27]. device implementations MUST meet the following requirements. Live Wallpapers Android defines a component type and corresponding API and lifecycle that allows applications to expose one or more "Live Wallpapers" to the end user [Resources. such as enforcing password policies or performing remote wipe. 25]. and MUST display this interface in response to the android. 3. As an example. The Android 4. Device implementations determined to not run live wallpapers reliably as described above MUST NOT implement live wallpapers. Recent Application Display The upstream Android 4. 28]. and SHOULD support the full range of device administration policies defined in the Android SDK documentation [Resources. Device implementations MAY modify the DeviceDefault theme attributes exposed to applications [Resources. 30]. or else they may not be compatible with a future version of Android.8. 3. Specifically. Live wallpaper will not run reliably on hardware that does not support multiple OpenGL contexts because the live wallpaper use of an OpenGL context may conflict with other applications that also use an OpenGL context.6. Additionally. at a reasonable framerate with no adverse affects on other applications. however. malfunction.0 source code includes a user interface for displaying recent applications using a thumbnail image of the application's graphical state at the moment the user last left the application. Device implementations capable of running live wallpapers reliably as described above SHOULD implement live wallpapers. If device implementations do not support the full range of device administration policies. patterns.0 includes support for Input Management Engines.Settings. but MUST dislpay a message notifying the user that the device does not support device administration. 25]. or similar images with limited input capabilities that display as a wallpaper.0 or 2. Live Wallpapers are animations.8. Device implementations MUST NOT alter any of the Holo theme attributes exposed to applications [Resources. 3.0 provides platform APIs that enable accessibility service implementations to receive callbacks for user and system events and generate alternate feedback mechanisms. some live wallpapers may use an Open GL 1. 29].8.9 Device Administration Android 4.ACTION_ACCESSIBILITY_SETTINGS intent. and trackball/d-pad navigation [Resources. behind other applications. Input Management Settings Android 4. Device implementations MUST provide an implementation of the Android accessibility framework consistent with the default Android implementation.0 APIs allow custom app IMEs to specify user-tunable settings. with no limitations on functionality.Android provides "themes" as a mechanism for applications to apply styles across an entire Activity or application.0 introduced a new "Holo" or "holographic" theme as a set of defined styles for application developers to use if they want to match the Holo theme look and feel as defined by the Android SDK [Resources. In addition. Device implementations MUST provide an implementation of the DevicePolicyManager class [Resources.provider. 27]. device implementations SHOULD provide an implementation of an accessibility service on the device. 26]. Specifically. Android 4. they MUST NOT allow device administration applications to be enabled.0 context to render their content. Device implementations MUST generate AccessibilityEvents and deliver these events to all registered AccessibilityService implementations in a manner consistent with the default Android implementation. haptic feedback. 3. Android 4. Device implementations are strongly encouraged to use the upstream Android 4. Android 3. or run at unacceptably low frame rates.ACTION_ADD_DEVICE_ADMIN intent. 24].7. a future version of Android is planned to make more extensive use of this functionality.0 user interface (or a similar thumbnail-based interface) for recent applications.10 Accessibility Android 4. 3. such as text-to-speech. the hardware is considered incapable of running live wallpaper.DevicePolicyManager. through the Android Device Administration API [Resources. Hardware is considered capable of reliably running live wallpapers if it can run all live wallpapers.0 provides an accessibility layer that helps users with disabilities to navigate their devices more easily.0 includes features that allow security-aware applications to perform device administration functions at the system level. the device implementation MUST respond to the android. Device implementations MUST include a way for the user to access IME settings at all times when an IME that provides such user settings is displayed.accessibilityservice APIs [Resources. If limitations in the hardware cause wallpapers and/or applications to crash. Device implementations MUST provide a user-accessible mechanism to enable and disable accessibility services.8.admin. if a device does not support all device administration policies. consume excessive CPU or battery power.app.0 introduces a new "Device Default" theme as a set of defined styles for application developers to use if they want to match the look and feel of the device theme as defined by the device implementer.

. Devices implementations MUST NOT extend either the . 58] except where explicitly permitted in this document. device implementations MUST support the media formats.11 Text-to-Speech Android 4. Media Codecs Device implementations MUST support the core media formats specified in the Android SDK documentation [Resources. Device implementers SHOULD use the reference upstream implementation of Dalvik. 31]. decoders. Device implementations MUST meet these requirements related to the Android TTS framework: Device implementations MUST support the Android TTS framework APIs and SHOULD include a TTS engine supporting the languages available on the device. including in open source software or shareware.1. 33]. Specifically. Dalvik bytecode [Resources.0 includes APIs that allow applications to make use of text-to-speech (TTS) services. Device implementations MUST support installation of third-party TTS engines. headphone jack. Android Manifest [ Resources. 35]. 5. Note that the upstream Android open source software includes a full-featured TTS engine implementation. encoders. and allows service providers to provide implementations of TTS services [Resources. 32]. 17]. etc. All of these codecs are provided as software implementations in the preferred Android implementation from the Android Open Source Project.apk [Resources. Please note that neither Google nor the Open Handset Alliance make any representation that these codecs are unencumbered by third-party patents. 3. or renderscript bytecode formats in such a way that would prevent those files from installing and running correctly on other compatible devices. may require patent licenses from the relevant patent holders. Those intending to use this source code in hardware or software products are advised that implementations of this code. Note that these tables do not list specific bitrate requirements for most video codecs because current device hardware does not necessarily support bitrates that map exactly to the required bitrates specified by the relevant standards. file types and container formats defined in the tables below. device implementations SHOULD support the highest bitrate practical on the hardware. 5. 4. Device implementations MUST provide a user-accessible interface that allows users to select a TTS engine for use at the system level. Multimedia Compatibility Device implementations MUST include at least one form of audio output. and the reference implementation's package management system. external speaker connection. such as speakers. 34].and SHOULD provide a mechanism for users to enable the accessibility service during device setup. Application Packaging Compatibility Device implementations MUST install and run Android ". up to the limits defined by the specifications.apk" files as generated by the "aapt" tool included in the official Android SDK [Resources. Instead. An open source implementation of an accessibility service is available from the Eyes Free project [Resources.

and 16-bit linear PCM (rates up to limit of hardware) PCM/WAVE REQUIRED WAVE (.ogg) Matroska (. encode in Android 4.75 to 12.wav) JPEG GIF REQUIRED REQUIRED REQUIRED Base+progressive JPEG (.rtx) OTA (.ts. REQUIRED 4. Mono/Stereo 8320Kbps constant (CBR) or variable bitrate (VBR) FLAC (.hardware. REQUIRED 9 rates from 6.xmf. . 16-bit recommended.0+.microphone .3gp) REQUIRED Required for device AMR-WB implementations that include microphone hardware and define android.hardware.aac. .1+) FLAC recommended on devices with 44.rtttl.gif) .1 kHz output.mxmf) RTTTL/RTX (.2 kbps sampled @ 8kHz 3GPP (. not seekable.1 kHz is REQUIRED (Android 3. . as the 48 to 44. Support for ringtone formats RTTTL/RTX. DLS Version 1 and 2. and iMelody 1 (.3gp) MPEG-4 (.3gp) Audio Mono/Stereo (no multichannel).mid.0+) AAC LC/LTP Required for device implementations that include microphone hardware and define android.60 kbit/s to 23.Type Format / Codec Encoder REQUIRED Decoder Details File Type(s) / Container Formats 3GPP (. .mp3) Type 0 and MIDI Type 0 and 1.mp4.microphone . REQUIRED HE-AACv1 (AAC+) REQUIRED Mono/Stereo content in any combination of standard bit rates up to 160 kbps and sampling rates from 8 to 48kHz REQUIRED HE-AACv2 (enhanced AAC+) REQUIRED Required for device AMR-NB implementations that include microphone hardware and define android. OTA.imy) Vorbis REQUIRED Ogg (.85 kbit/s sampled @ 16kHz 3GPP (.mkv) 8.jpg) GIF (. ADIF not supported) MPEG-TS (.microphone . XMF MIDI REQUIRED and Mobile XMF.m4a) ADTS raw AAC (. no dither applied for 24-bit.hardware.1 kHz downsampler does not include a low-pass filter).1+.flac) only MP3 REQUIRED MP3 (. decode in Android 3. Sample rates up to 48 kHz (but up to 44.ota) iMelody (. Android 3.

these requirements are optional in Android 4.mp4) MPEG-TS REQUIRED Baseline Profile (BP) (.media.bmp) WebP (.hardware.263 3GPP (.AudioSource.0+) VP8 (Android 2.VOICE_RECOGNITION audio source: Noise reduction processing.front .3+) 5.front .mp4) H. REQUIRED 3GPP (.Image PNG BMP WEBP REQUIRED REQUIRED REQUIRED PNG (.0 are very strongly encouraged to meet these requirements in Android 4. In addition to the above recording specifications. Existing and new devices that run Android 4.AudioRecord API to start recording an audio stream.webp) REQUIRED REQUIRED Required for device implementations that include camera hardware and define android.png) BMP (. Audio Recording When an application has used the android.0 but will be required by a future version. from 100 Hz to 4000 Hz Audio input sensitivity SHOULD be set such that a 90 dB sound power level (SPL) source at 1000 Hz yields RMS of 2500 for 16-bit samples.hardware. That is.hardware.3gp) REQUIRED MPEG-4 (.3gp) REQUIRED Required for device implementations that include camera hardware and define android.webm) and Matroska (. if present. ±3 dB. if present.microphone MUST sample and record audio with each of these behaviors: The device SHOULD exhibit approximately flat amplitude versus frequency characteristics.2 Video Encoding Android device implementations that include a rear-facing camera and declare android. or they will not be able to attain Android compatibility when upgraded to the future version. not seekable.hardware.camera SHOULD support the following video encoding profiles. the Compatibility Definition for a future version is planned to change these to "MUST".media.mkv. MPEG-4 (. Total harmonic distortion SHOULD be less than 1% from 100 Hz to 4000 Hz at 90 dB SPL input level.0+) Video H.3gp) WebM (.hardware.camera or android.hardware. device implementations that include microphone hardware and declare android. PCM amplitude levels SHOULD linearly track input SPL changes over at least a 30 dB range from -18 dB to +12 dB re 90 dB SPL at the microphone.camera or android.0.3. .264 Baseline Profile SD (High quality) H.264 AVC MPEG-4 SP REQUIRED REQUIRED 3GPP (.camera. AAC audio only. Android 3. Android 4.264 Baseline Profile 480 x 360 px 30 fps 500 Kbps or higher AAC-LC 2 (stereo) 128 Kbps HD (When supported by hardware) H.ts.camera. when an application has started recording an audio stream using the android. specifically. Note: while some of the requirements outlined above are stated as "SHOULD" for Android 4. MUST be disabled.0. MUST be disabled. SD (Low quality) Video codec H.3.MediaRecorder. Automatic gain control.264 Baseline Profile 1280 x 720 px 30 fps 2 Mbps or higher AAC-LC 2 (stereo) 192 Kbps Video resolution 176 x 144 px Video frame rate 12 fps Video bitrate Audio codec 56 Kbps AAC-LC Audio channels 1 (mono) Audio bitrate 24 Kbps 5.

devices MUST support the following media network protocols: RTSP (RTP. and there MUST be a user-accessible mechanism to turn on the Android Debug Bridge. That is. Many classes of applications rely on short latencies. however Microsoft Windows systems typically require a driver for new Android devices. 59] 6.content.) If a device implementation is unrecognized by the adb tool as provided in the standard Android SDK. it MAY report support for low-latency audio. device implementers MUST provide Windows drivers allowing developers to connect to the device using the adb protocol. Windows Vista. support for ddms SHOULD be inactive by default. 33] Device implementations MUST support all ddms features as documented in the Android SDK. Developer Tool Compatibility Device implementations MUST support the Android Developer Tools provided in the Android SDK. and make it available for applications to use.4.audio. 33] Device implementations MUST support all adb functions as documented in the Android SDK. Most Linux-based systems and Apple Macintosh systems recognize Android devices using the standard Android SDK tools. without additional support. when the audio system has been recently used but is currently idle (that is.5. when the audio system and microphone has been idle and powered down prior to the request "continuous input latency" is defined to be when an ambient sound occurs and when the sample corresponding to that sound is delivered to a recording application via its callback. For the purposes of this section: "cold output latency" is defined to be the interval between when an application requests audio playback and when sound begins playing. Network Protocols Devices MUST support the media network protocols for audio and video playback as specified in the Android SDK documentation [Resources. These drivers MUST be provided for Windows XP. If a device implementation meets the requirements of this section. new vendor IDs and sometimes new device IDs require custom USB drivers for Windows systems. the Compatibility Definition for a future version is planned to change these to "MUST". Android-compatible devices MUST be compatible with: Android Debug Bridge (known as adb) [Resources. and Windows 7. these requirements are optional in Android 4.5. 58]. (For instance. while the device is currently playing back audio "cold input latency" is defined to be the interval between when an application requests audio recording and when the first sample is delivered to the application via its callback.hardware. 36] Device implementations MUST include the Monkey framework.0 are very strongly encouraged to meet these requirements in Android 4. device implementations SHOULD exhibit each of these properties: cold output latency of 100 milliseconds or less warm output latency of 10 milliseconds or less continuous output latency of 45 milliseconds or less cold input latency of 100 milliseconds or less continuous input latency of 50 milliseconds or less Note: while the requirements outlined above are stated as "SHOULD" for Android 4. if the device implementation does not meet these requirements it MUST NOT report support for low-latency audio. As ddms uses adb. . Device implementations that include microphone hardware and declare android. when the audio system has been idle and powered down prior to the request "warm output latency" is defined to be the interval between when an application requests audio playback and when sound begins playing. Version 3 [Resources. [Resources.0. Specifically. as above.microphone SHOULD meet all audio latency requirements outlined in this section. silent) "continuous output latency" is defined to be the interval between when an application issues a sample to be played and when the speaker physically plays the corresponding sound. Dalvik Debug Monitor Service (known as ddms) [Resources.low-latency" via the android. or they will not be able to attain Android compatibility when upgraded to the future version. Specifically. See Section 7 for details on the conditions under which microphone hardware may be omitted by device implementations.pm. 37] Conversely. Audio Latency Audio latency is broadly defined as the interval between when an application requests an audio playback or record operation.0 but will be required by a future version. Existing and new devices that run Android 4. SDP) HTTP(S) progressive streaming HTTP(S) Live Streaming draft protocol. while the device is in recording mode Using the above definitions.0. by reporting the feature "android. 5.hardware.PackageManager class. and when the device implementation actually begins the operation. Monkey [Resources. The device-side adb daemon MUST be inactive by default. but MUST be supported whenever the user has activated the Android Debug Bridge. to achieve real-time effects such sound effects or VOIP communication. in both 32-bit and 64-bit versions.

known as 'ldpi' 160 dpi. 120 dpi. 38]. The units referenced by the requirements in this section are defined as follows: "Physical diagonal size" is the distance in inches between two opposing corners of the illuminated portion of the display.1. normal. known as 'hdpi' . For example. known as 'mdpi' 213 dpi.1.pm. Devices MUST NOT change their reported screen size at any time.content. large. known as 'tvdpi' 240 dpi. "Aspect ratio" is the ratio of the longer dimension of the screen to the shorter dimension. 7. calculated as: pixels = dps * (density / 160). and allows applications to query the device screen size (aka "screen layout") via android. Device implementations MUST accurately report accurate hardware configuration information via the getSystemAvailableFeatures() and hasSystemFeature(String) methods on the class.85 (16:9). [Resources. Screen Aspect Ratio The aspect ratio MUST be between 1. Hardware Compatibility If a device includes a particular hardware component that has a corresponding API for third-party developers. If an API in the SDK interacts with a hardware component that is stated to be optional and the device implementation does not possess that component: complete class definitions (as documented by the SDK) for the component's APIs MUST still be present the API's behaviors MUST be implemented as no-ops in some reasonable fashion API methods MUST return null values where permitted by the SDK documentation API methods MUST return no-op implementations of classes where null values are not permitted by the SDK documentation API methods MUST NOT throw exceptions not documented by the SDK documentation A typical example of a scenario where these requirements apply is the telephony API: even on non-phone devices.xml file.util. to ensure that third-party applications run well on a variety of hardware configurations [Resources. and xlarge screens. devices MUST have screen sizes of at least 2.779. "dpi" (meaning "dots per inch") is the number of pixels encompassed by a linear horizontal or vertical span of 1".DisplayMetrics APIs. device implementations must report the correct screen size according to the following logical density-independent pixel (dp) screen dimensions. as described in the Android SDK documentation.res. these APIs must be implemented as reasonable no-ops.1. and MUST execute applications at this standard density.Configuration. Display and Graphics Android 4. Device implementations MUST report the correct screen size as defined in the Android SDK documentation [Resources.3333 (4:3) and 1. Applications optionally indicate which screen sizes they support via the <supports-screens> attribute in the AndroidManifest. both horizontal and vertical dpi must fall within the range. Specifically. as detailed in this section. Devices MUST properly implement these APIs and behaviors. a display of 480x854 pixels would be 854 / 480 = 1.0 includes facilities that automatically adjust application assets and UI layouts appropriately for the device.PackageManager 7. 37] android. Devices MUST have screen sizes of at least 426 dp x 320 dp ('small') Devices that report screen size 'normal' MUST have screen sizes of at least 470 dp x 320 dp Devices that report screen size 'large' MUST have screen sizes of at least 640 dp x 480 dp Devices that report screen size 'xlarge' MUST have screen sizes of at least 960 dp x 720 dp In addition. A "density-independent pixel" or ("dp") is the virtual pixel unit normalized to a 160 dpi screen. the device implementation MUST implement that API as described in the Android SDK documentation. Device implementations MUST correctly honor applications' stated support for small. Screen Configuration Screen Size The Android UI framework supports a variety of different screen sizes.5 inches in physical diagonal size. Screen Density The Android UI framework defines a set of standard logical densities to help application developers target application resources. Device implementations MUST report one of the following logical Android framework densities through the android.7. or roughly "16:9".content. Where dpi values are listed. 38] and determined by the upstream Android platform.screenLayout with the SCREENLAYOUT_SIZE_MASK.

0 The native C/C++ OpenGL APIs (that is. However.hardware. 7. Devices MUST NOT change the reported screen size or density when changing orientation.3.util. For example. whenever queried via the android.4. 2D and 3D Graphics Acceleration Device implementations MUST support both OpenGL ES 1.1. via the getString() method in the OpenGL API. Window or View level through the use of a manifest tag android:hardwareAccelerated or direct API calls [ Resources. 8]. That is.0 includes a TextureView object that lets developers directly integrate hardware-accelerated OpenGL ES textures as rendering targets in a UI hierarchy. device implementations MUST exhibit behavior consistent with the Android SDK documentation on hardware acceleration [Resources. Device implementations MUST also support Android Renderscript. 38]. Legacy Application Compatibility Mode Android 4.0. 9].1. and conversely MUST NOT report extension strings that they do not support.0 and 2. Android 4. That is.so.landscape) and android.hardware. Device implementations MUST support the TextureView API. Device implementations are not required by Android 4. In Android 4. However.0 includes support for applications to optionally specify that they require specific OpenGL texture compression formats.getOrientation().landscape. MUST only report 7. Display Metrics Device implementations MUST report correct values for all display metrics defined in android.0 specifies a "compatibility mode" in which the framework operates in an 'normal' screen size equivalent (320dp width) mode for the benefit of legacy applications not developed for old versions of Android that pre-date screen-size independence.2.hardware.portrait and/or android. and MUST exhibit consistent behavior with the upstream Android implementation. If the standard Android framework density that is numerically closest to the physical density results in a screen size that is smaller than the smallest supported compatible screen size (320 dp width). device implementations MUST enable hardware acceleration by default. Note that Android 4.320 dpi.6.0.1. Devices MUST report the correct value for the device's current orientation. Screen Orientation Devices MUST support dynamic orientation by applications to either portrait or landscape screen orientation. Android 3. Device implementations MUST include support for legacy application compatibility mode as implemented by the upstream Android open source code.orientation. 7. 7. as detailed in the Android SDK documentation [Resources.0. such as a television or laptop.5.res.screen. device implementations SHOULD report the next lowest standard Android framework density. known as 'xhdpi' Device implementations SHOULD define the standard Android framework density that is numerically closest to the physical density of the screen.view.0 introduced a mechanism for applications to declare that they wanted to enable hardware acceleration for 2D graphics at the Application.0 and 2. or other APIs.0 and 2. a device with a fixed-orientation landscape screen. Device implementations MAY implement any desired OpenGL ES extensions. android.0 and 2. 9]. MUST report at least one supported orientation. those available to apps via libGLES_v1CM.0.Display. Screen Types . libGLES_v2. That is: The managed APIs (such as via the GLES10. In addition. device implementations MUST NOT alter the triggers or thresholds at which compatibility mode is activated.so) MUST report support for OpenGL ES 1.screen.content. Activity.1.so.screen. the device must respect the application's request for a specific screen orientation. unless that logical density pushes the reported screen size below the minimum supported. These formats are typically vendor-specific. or libEGL.0 to implement any specific texture compression format. as embodied and detailed in the Android SDK documentations.getString() method) MUST report support for OpenGL ES 1. 7. Devices MUST report which screen orientations they support ( android. device implementations MUST report via the OpenGL ES managed and native APIs all extension strings that they do support. they SHOULD accurately report any texture compression formats that they do support.Configuration.DisplayMetrics [Resources.1. and MUST disable hardware acceleration if the developer so requests by setting android:hardwareAccelerated="false" or disabling hardware acceleration directly through the Android View APIs. Device implementations MAY select either portrait or landscape orientation as the default. Device implementations MUST also correctly identify themselves as supporting OpenGL ES 1. and MUST NOT alter the behavior of the compatibility mode itself.

0.2. or wheel) MUST report the correct value for android. Typically the screen is physically integrated with the device.2. Variable-Pixel Device Implementations Variable-pixel device implementations MUST support one or both of 1280x720. Variable-pixel display implementations: the device implementation either has no embedded screen and includes a video output port such as VGA or HDMI for display. The display technology used MUST be comprised of square pixels.content.i. or very close to. Non-touch Navigation Device implementations: MAY omit a non-touch navigation option (that is. 7. Input Devices 7. tablets. Device implementations with variable-pixel displays MUST NOT support any other screen configuration or mode.2. soft keyboard) as detailed at http://developer. Examples include televisions. If it contains a video output port that displays at 720p or 1080p. For example. or has an embedded screen that can change pixel dimensions.2. compatible with Input Management Engines. Specifically: Devices MUST support displays capable of rendering 16-bit color graphics and SHOULD support displays capable of 24-bit color graphics. set-top boxes. a user of a set-top box may replace a 720p display with a 1080p display.navigation [Resources. Device implementations with variable-pixel screens MAY change screen configuration or mode at runtime or boot-time. and the device implementation may adjust accordingly. 720p or 1080p).Configuration.2.com MUST provide at least one soft keyboard implementation (regardless of whether a hard keyboard is present) MAY include additional soft keyboard implementations MAY include a hardware keyboard MUST NOT include a hardware keyboard that does not match one of the formats specified in android.res. Devices MUST support all of these APIs as defined by the Android SDK unless specifically allowed in this document. . However.7.android. QWERTY. The device MUST report screen dimensions that are the same as. variable-pixel device implementations MUST report the following configuration buckets for these pixel dimensions: 1280x720 (also known as 720p): 'large' screen size. Fixed-Pixel Device Implementations Fixed-pixel device implementations MAY use screens of any pixel dimensions. 7. Examples include mobile phones.content. if that display is ever used for running apps. The device MUST report the same logical density as the fixed-pixel display. the device implementation MUST scale the output so that applications are only executed in a large mdpi window. 39] MUST provide a reasonable alternative user interface mechanism for the selection and editing of text. d-pad.1.Device implementation screens are classified as one of two types: Fixed-pixel display implementations: the screen is a single panel that supports only a single pixel width and height.1 and 7. Devices MUST support displays capable of rendering animations. Screen Technology The Android platform includes APIs that allow applications to render rich graphics to the display. regardless of whether the fixed-pixel display or video output port is in use. the fixed-pixel display.e. and so on. may omit a trackball. device implementations with variable pixel dimensions are restricted to 720p or 1080p in Android 4. 'tvdpi' (213 dpi) density 1920x1080 (also known as 1080p): 'large' screen size. For example. or 1920x1080 (that is. Keyboard Device implementations: MUST include support for the Input Management Framework (which allows third party developers to create Input Management Engines . The upstream Android open source software includes a selection mechanism suitable for use with devices that lack non-touch navigation inputs.1.res. as the fixed-pixel display.Configuration. or 12-key) 7. 39] (that is.keyboard [Resources. and MUST be configured to report screen size and density buckets as noted above. 'xhdpi' (320 dpi) density For clarity.1. a tablet that is 7" diagonal size with a 1024x600 pixel resolution is considered a fixed-pixel large mdpi display implementation. as detailed in Sections 7.1. Additionally. the device MUST meet the following requirements: The device MUST report the same screen configuration and display metrics. and so on. provided that they meet the requirements defined this Compatibility Definition. Fixed-pixel implementations MAY include a video output port for use with an external display.

Sensors Android 4. etc. Device implementations MUST present the navigation keys in an unobtrusive "low profile" (eg. device implementations that do possess a microphone: MUST report the android. If a device includes a particular sensor type that has a corresponding API for third-party developers. Device implementations MUST make these functions available to the user at all times when running applications. which corresponds to a high-fidelity non-touch (that is.1.0 includes the feature android.pm. Device implementations that include a touchscreen (single-touch or better) MUST also report android. Device implementations that do not include a touchscreen (and rely on a pointer device only) MUST NOT report any touchscreen feature.2. and the linear acceleration sensor.content.0 includes APIs for accessing a variety of sensor types. if a touchscreen supports multiple pointers MUST report the value of android. Touchscreen input Device implementations: MUST have a pointer input system of some kind (either mouse-like. it MUST NOT report the android.faketouch.3 SHOULD meet the audio latency requirements in Section 5.4 7. Menu and Back functions are essential to the Android navigation paradigm. the documented behavior of the Android SDK is to be considered authoritative.Configuration [Resources. as provided for in the following subsections. gestures.3. Device implementations MUST display the navigation keys when applications do not specify a system UI mode.hardware. meaning they can be derived from data provided by one or more other sensors.1. when they include the prerequisite physical sensors. if a device implementation omits a microphone. per Section 7.hardware. touch panel.microphone feature constant. metric) values for each sensor type as defined in the Android SDK documentation [Resources.PackageManager class. Android 4. not available to applications. Device implementations MUST hide the navigation keys when applications specify SYSTEM_UI_FLAG_HIDE_NAVIGATION.3. (Examples include the orientation sensor. Some sensor types are synthetic.content.hardware. Navigation keys The Home. [Resources. by returning true or false as appropriate when applications attempt to register listeners.res. Device implementations MAY use a distinct portion of the screen to display the navigation keys.2. device implementations: MUST accurately report the presence or absence of sensors per the android.hardware. or specify SYSTEM_UI_FLAG_VISIBLE. Microphone Device implementations MAY omit a microphone. However. the device implementation MUST implement that API as described in the Android SDK documentation. These functions MAY be implemented via dedicated physical buttons (such as mechanical or capacitive touch buttons). pointerbased) input device such as a mouse or trackpad that can adequately emulate touch-based input (including basic gesture support). or touch) MAY have a touchscreen of any modality (such as capacitive or resistive) SHOULD support fully independently tracked pointers.getSensorList() and similar methods MUST behave reasonably for all other sensor APIs (for example.) Device implementations SHOULD implement these sensor types.0 supports both implementations. dimmed) mode when applications specify SYSTEM_UI_FLAG_LOW_PROFILE. etc. not calling sensor listeners when the corresponding sensors are not present.4. Device implementation MUST present a Menu key to applications when targetSdkVersion < 10 and SHOULD NOT present a Menu key when the targetSdkVersion >= 10. 37] MUST return an accurate list of supported sensors via the SensorManager.5. 41] The list above is not comprehensive.faketouch. or MAY be implemented using dedicated software keys. Device implementations MUST make available a portion of the display to applications that meets the requirements defined in Section 7. and MUST NOT obscure or otherwise interfere with the portion of the screen available to applications.faketouch. and must implement the audio recording API as noops.microphone feature constant SHOULD meet the audio quality requirements in Section 5.7.e.hardware. Note that Android 4. and MUST report only android. Devices implementations generally MAY omit these sensors. 7.2. MUST meet these requirements: Device implementation navigation keys MUST use a distinct portion of the screen. . and indicates that the device supports an emulated subset of touchscreen functionality.) MUST report all sensor measurements using the relevant International System of Units (i. Conversely. For example. but if so. 7. 39] reflecting corresponding to the type of the specific touchscreen on the device Device implementations MUST report the correct feature corresponding to the type of input used.

or rad^2 / s). approximately 1. rather than only when the data changes. If a device implementation has a proximity sensor.4. GPS Device implementations SHOULD include a GPS receiver. It MUST NOT measure any other temperature. it: MUST be able to deliver events at 10 Hz or greater MUST comply with the Android sensor coordinate system as detailed in the Android APIs (see [ Resources.05 m/s^2 7.3. 41]) MUST be capable of measuring from freefall up to twice gravity (2g) or more on any three-dimensional vector MUST have 8-bits of accuracy or more MUST have a standard deviation no greater than 0.3. if you measure the variance of the gyro at 1 Hz sampling rate it should be no greater than 1e-7 rad^2/s^2. angular change sensor.3.3.e. it: MUST be able to deliver events at 5 Hz or greater MUST have adequate precision to enable estimating altitude 7. 41]). MUST be capable of sampling a range of field strengths adequate to cover the geomagnetic field MUST have 8-bits of accuracy or more MUST have a standard deviation no greater than 0.e.e.e. compass.e.0 APIs introduce a notion of a "streaming" sensor. 7.5.) 7.7. If a device implementation does include a proximity sensor.000 degrees per second) MUST be able to deliver events at 100 Hz or greater MUST have 12-bits of accuracy or more MUST have a variance no greater than 1e-7 rad^2 / s^2 per Hz (variance per Hz. but must be constrained by this value. it SHOULD include some form of "assisted GPS" technique to minimize GPS lock-on time. Accelerometer Device implementations SHOULD include a 3-axis accelerometer. it: MUST be temperature compensated MUST be capable of measuring orientation changes up to 5.7.8. it MUST be have 1-bit of accuracy or more. If a device implementation includes a proximity sensor with any other orientation. ambient light sensor. Barometer Device implementations MAY include a barometer (i. (Note that this sensor type is deprecated in the Android 4. The constant latency must be removed.3. The variance is allowed to vary with the sampling rate. it MUST measure the temperature of the device CPU.2.) 7.3.3. as the primary intent of this sensor type is to detect a phone in use by the user.3. If a device implementation includes a gyroscope. ambient air pressure sensor. Gyroscope Device implementations SHOULD include a gyroscope (i.0 SDK documentation to be a streaming sensor. .) If a device does include a 3-axis magnetometer.3. Magnetometer Device implementations SHOULD include a 3-axis magnetometer (i.) If a device implementation does include a thermometer. If a device implementation does include a 3-axis accelerometer. Thermometer Device implementations MAY but SHOULD NOT include a thermometer (i. Photometer Device implementations MAY include a photometer (i. Proximity Sensor Device implementations MAY include a proximity sensor. In other words. it MUST NOT be accessible through this API.) If a device implementation includes a barometer. MUST have timestamps as close to when the hardware event happened as possible.0 APIs. If a device implementation does include a GPS receiver. it: MUST be able to deliver events at 50 Hz or greater MUST comply with the Android sensor coordinate system as detailed in the Android APIs (see [ Resources. it MUST measure the proximity of an object in the same direction as the screen. which is one that returns data continuously.The Android 4.1.5 µT 7. temperature sensor. the proximity sensor MUST be oriented to detect objects close to the screen. 7. 7. Device implementations MUST continuously provide periodic data samples for any API indicated by the Android 4.) Devices SHOULD NOT include a gyroscope sensor unless a 3-axis accelerometer is also included.5*Pi radians/second (that is. That is.

4. it cannot be fully tested by unit tests running on a single device. SHOULD enable Android Beam by default MUST poll for all supported technologies while in NFC discovery mode. then it: MUST report the android.3.4.0) via the following NFC standards: NfcA (ISO14443-3A) NfcB (ISO14443-3B) NfcF (JIS 6319-4) NfcV (ISO 15693) IsoDep (ISO 14443-4) NFC Forum Tag Types 1.) If a device implementation does include support for 802. However. regardless of whether they use a cellular network for data connectivity.content. such as 'Touch to Beam'. etc.enableForegroundNdefPush.2. since Bluetooth is a communications protocol between devices.4.4. device implementations MUST also pass the human-driven Bluetooth test procedure described in Appendix A.PackageManager. That is.nfc. OBEX. 2. While these voice calls may or may not be packet-switched. Android 4.0 APIs and this document refers specifically to hardware related to placing voice calls and sending SMS messages via a GSM or CDMA network. for instance. 42].11 (WiFi) Android 4. and android. 3. If no default SNEP server is found then the client MUST attempt to send to an NPP server.0 (defined by the NFC Forum) NDEF Push Protocol [Resources.ACTION_NDEF_DISCOVERED intent. [Resources.setNdefPushMessage.hasSystemFeature() method.nfc feature from the android.NfcAdapter. Device implementations that do not include telephony hardware MUST implement the full APIs as no-ops. IEEE 802.1. 43] SNEP 1.NfcAdapter.0 considered independent of any data connectivity that may be implemented using the same network.nfc.0 is compatible with devices that are not phones. Device implementations that do include a Bluetooth transceiver MUST enable the RFCOMM-based Bluetooth API as described in the SDK documentation [Resources. Device implementations SHOULD implement relevant Bluetooth profiles.0 (defined by the NFC Forum) MUST include support for Android Beam: MUST implement the SNEP default server.setNdefPushMessageCallback. AVRCP. Data Connectivity 7. as appropriate for the device. and android. such as A2DP. The Compatibility Test Suite includes cases that cover basic operation of the Android RFCOMM Bluetooth API. they are for the purposes of Android 4.4. SHOULD use a gesture or on-screen confirmation. it MUST implement full support for the API for that technology. .hardware. 7. If a device implementation does include NFC hardware. Consequently. 7.0 MAY be used on devices that do not include telephony hardware. Android 4.hardware. before sending outbound P2P NDEF messages. etc. MUST implement the NPP server.0 (defined by the NFC Forum) SDP 1. 4 (defined by the NFC Forum) MUST be capable of transmitting and receiving data via the following peer-to-peer standards and protocols: ISO 18092 LLCP 1. if a device implementation does include GSM or CDMA telephony.pm. 7.nfc.7. 37] MUST be capable of reading and writing NDEF messages via the following NFC standards: MUST be capable of acting as an NFC Forum reader/writer (as defined by the NFC Forum technical specification NFCForum-TS-DigitalProtocol-1.11.4. However.NfcAdapter. Bluetooth Device implementations SHOULD include a Bluetooth transceiver. Messages received by the NPP server MUST be processed the same way as the SNEP default server.0 device implementations SHOULD include support for one or more forms of 802. it MUST implement the corresponding Android API. MUST allow foreground activities to set the outbound P2P NDEF message using android. Disabling Android Beam in settings MUST NOT disable dispatch of incoming NDEF message. Near-Field Communications Device implementations SHOULD include a transceiver and related hardware for Near-Field Communications (NFC). the Android "telephony" functionality and APIs refer specifically to voice calls and SMS.telephony" feature or any sub-features. Telephony "Telephony" as used by the Android 4.11 (b/g/a/n. In other words. MUST implement a SNEP client and attempt to send outbound P2P NDEF to the default SNEP server when Android Beam is enabled. Valid NDEF messages received by the default SNEP server MUST be dispatched to applications using the android. device implementations that cannot place calls or send/receive SMS messages MUST NOT report the "android.nfc.

the camera API in Android 4.5.content. 44]. it MUST NOT declare the android.nfc feature from the android.11g. like a traditional camera.pm. If a device implementation supports MIFARE in the reader/writer role. 640x480 pixels) MUST NOT use a front-facing camera as the default for the Camera API. and MUST implement the Android 4.11 (WiFi).PackageManager. If a device implementation includes a front-facing camera.PreviewCallback. a camera typically used to image the user.SHOULD be in NFC discovery mode while the device is awake with the screen active and the lock-screen unlocked. such as 802. or software auto-focus implemented in the camera driver (transparent to application software) MAY have fixed-focus or EDOF (extended depth of field) hardware MAY include a flash. device implementations MUST include support for at least one data standard capable of 200Kbit/sec or greater. etc. MUST NOT implement the corresponding Android APIs nor report the com. even if it is the only camera on the device. 7. unless the application has explicitly enabled the flash by enabling the FLASH_MODE_AUTO or FLASH_MODE_ON attributes of a Camera. MAY include features (such as auto-focus. such as for video conferencing and similar applications. If the Camera includes a flash. (Note that publicly available links are not available for the JIS. device implementations MAY include reader/writer support for the following MIFARE technologies. but only to third-party applications using Camera.5. Front-Facing Camera Device implementations MAY include a front-facing camera. mirror) the stream displayed by an app in a CameraPreview.1. that is. it: MUST have a resolution of at least 2 megapixels SHOULD have either hardware auto-focus.hasSystemFeature() method [Resources. 7.nxp. HSPA. etc. 48]. it images scenes on the far side of the device. A front-facing camera is a camera located on the same side of the device as the display.5.hardware. EV-DO. the flash lamp MUST NOT be lit while an android. [Resources. MF0ICU2 [Resources. MUST horizontally reflect (i.2.mifare from the android. MIFARE Classic (NXP MF1S503x [Resources.nfc.PreviewCallback instance has been registered on a Camera preview surface.hardware.) Additionally. Rear-Facing Camera Device implementations SHOULD include a rear-facing camera. 37] Note that this is not a standard Android feature.4.nfc feature. Device implementations where a physical networking standard (such as Ethernet) is the primary data connection SHOULD also include support for at least one common wireless data standard. 7.0 NFC API as a no-op. Devices MAY implement more than one form of data connectivity. the camera preview MUST be mirrored horizontally relative to .nxp. as follows: If the device implementation is capable of being rotated by user (such as automatically via an accelerometer or manually via user input). it: MUST implement the corresponding Android APIs as documented by the Android SDK MUST report the feature com. A rear-facing camera is a camera located on the side of the device opposite the display.NdefRecord represent a protocol-independent data representation format. As the classes android. that is.hardware.nfc. 44]) MIFARE Ultralight (NXP MF0ICU1 [Resources. flash.mifare feature unless it also implements general NFC support as described in this section If a device implementation does not include NFC hardware. it: MUST have a resolution of at least VGA (that is. That is. Minimum Network Capability Device implementations MUST include support for one or more forms of data networking. MF1S703x [Resources.NdefMessage and android.0 includes APIs for these MIFARE types.0 has specific support for front-facing cameras. and as such does not appear as a constant on the PackageManager class.e. 802. 49]) Note that Android 4. device implementations MUST implement these APIs even if they do not include support for NFC or declare the android. ISO. 46]) NDEF on MIFARE Classic (NXP AN130511 [Resources.PackageManager. 46]. and MAY include a front-facing camera.1. 7. Examples of technologies that satisfy this requirement include EDGE. If a device implementation includes a rear-facing camera.) available to rear-facing cameras as described in Section 7.5. and NFC Forum specifications cited above.Camera.5. Specifically. Ethernet. and device implementations MUST NOT configure the API to to treat a front-facing camera as the default rear-facing camera. Note that this constraint does not apply to the device's built-in system camera application.pm. Cameras Device implementations SHOULD include a rear-facing camera.Parameters object. AN130411 [Resources. 37].content.hasSystemFeature() method.

That is.setPreviewFormat(int).Parameters.Parameters.) Note that this does apply to front-facing cameras.) Device implementations MUST implement the full Camera API included in the Android 4.hardware.6. the preview MUST be mirrored along the device's default horizontal axis. 51]). Camera API Behavior Device implementations MUST implement the following behaviors for the camera-related APIs. That is. 7. but the device implementation MUST support conversion to YV12.hardware. Device implementations MUST have at least 350MB of non-volatile storage available for application private data. Memory and Storage 7.0 SDK documentation [Resources.hardware. 50] method.YCbCr_420_SP for preview data provided to application callbacks. the API callbacks must still be "faked" as described.Camera.Camera. Application Shared Storage Device implementations MUST offer shared storage for applications. 7.ACTION_NEW_PICTURE intent whenever a new picture is taken by the camera and the entry of the picture has been added to the media store. Device implementations MUST broadcast the Camera.AutoFocusCallback instances (even though this has no relevance to a non-autofocus camera.hardware. That is.Camera.6. (If the device implementation does not support postview. The shared storage provided MUST be at least 1GB in size.5. device implementations MUST support all standard Camera parameters if the hardware allows.hardware. Otherwise.5. This applies regardless of the device's natural orientation.PreviewCallback instance and the system calls the onPreviewFrame() onPreviewFrame() method when the preview format is YCbCr_420_SP. MUST be oriented so that the long dimension of the camera aligns with the screen's long dimention. 3. Minimum Memory and Storage Device implementations MUST have at least 340MB of memory available to the kernel and userspace.Camera.6. that is. the API must behave as documented. 7. Device implementations MUST be configured with shared storage mounted by default. Device implementations MUST support the YV12 format (as denoted by the android. if present.3. for instance.setParameters() method other than those documented as constants on the android. If the current application has explicitly requested that the Camera display be rotated via a call to the android. Conversely. 2.and rear-facing cameras. and so on that is not under the kernel's control. The device implementation of the Download Manager MUST be capable of downloading individual files of at least 100MB in size to the default "cache" location.Camera. cameras MUST capture images in the landscape orientation. If the shared .setDisplayOrientation() [Resources. NV21 MUST be the default. (The hardware video decoder and camera may use any native pixel format. Device implementations MUST NOT honor or recognize string constants passed to the android. cameras that lack autofocus MUST still call any registered android.Camera.Parameters class.hardware. if the underlying hardware supports the feature. Device implementations MUST recognize and honor each parameter name defined as a constant on the android.ImageFormat. Camera Orientation Both front. regardless of whether the device includes hardware autofocus or other capabilities.Camera. If an application has never called android. this requirement obviously does not apply. it applies to landscape-primary devices as well as portrait-primary devices. If the device hardware does not support a feature. The Android APIs include a Download Manager that applications may use to download data files [ Resources. even though most front-facing cameras do not support autofocus.hardware.and rear-facing cameras. 56]. The 340MB MUST be in addition to any memory dedicated to hardware components such as radio. If an application registers an android. the /data partition MUST be at least 350MB. when the device is held in the landscape orientation.4.ACTION_NEW_VIDEO intent whenever a new video is recorded by the camera and the entry of the picture has been added to the media store. the data in the byte[] passed into must further be in the NV21 encoding format.2.) MUST NOT mirror the final captured still image or video streams returned to application callbacks or committed to media storage 7.PixelFormat. and MUST NOT support custom Camera parameter types.hardware.the device's current orientation.graphics. the camera preview MUST be mirrored horizontally relative to the orientation specified by the application. for both front. then the device MUST use android. For instance. "out of the box".YV12 constant) for camera previews for both front. Device implementations MUST broadcast the Camera. MUST mirror the image displayed by the postview in the same manner as the camera preview image stream.1. video.and rear-facing cameras: 1. That is.

it MUST provide a host computer with access to the contents of shared storage by some other means. Device implementations MAY use USB mass storage. Device implementations MAY have hardware for user-accessible removable storage. If a device implementation includes an SD card slot to satisfy the shared storage requirement. Performance Compatibility Device implementations MUST meet the key performance metrics of an Android 4. such as a network file system. Alternatively. but SHOULD use Media Transfer Protocol. and SHOULD include a USB host port. Application Launch Time Browser: less than 1300ms Contacts: less than 700ms Settings: less than 700ms When multiple applications have been Simultaneous Applications launched. USB Device implementations SHOULD include a USB client port.usb.11) 8.accessory [Resources. The device implementation SHOULD report a USB interface name of 'MTP'. Regardless of the form of shared storage used. and MUST declare support for the hardware feature android.host [Resources.permission. such as USB mass storage (UMS) or Media Transfer Protocol (MTP). Alternatively. 51] If a device implementation includes a USB host port: it MAY use a non-standard port form factor. If a device implementation includes a USB client port: the port MUST be connectable to a USB host with a standard USB-A port the port SHOULD use the micro USB form factor on the device side it MUST allow a host connected to the device to access the contents of the shared storage volume using either USB mass storage or Media Transfer Protocol it MUST implement the Android Open Accessory API and specification as documented in the Android SDK documentation. If a device implementation omits a USB client port. .7. and MUST be mounted by default. 7. Android File Transfer [Resources. including the time it takes to start the Linux process. device implementations MUST provide some mechanism to access the contents of shared storage from a host computer. and MUST declare support for the hardware feature android. then the device MUST include a Linux symbolic link from /sdcard to the actual mount point. If the device implementation lacks USB ports. Shared storage MUST otherwise be writable by any application that obtains that permission.storage is not mounted on the Linux path /sdcard. 52] Device implementations MUST implement the Android Debug Bridge. that storage MUST be 1GB in size or larger and mounted on /sdcard (or /sdcard MUST be a symbolic link to the physical location if it is mounted elsewhere.WRITE_EXTERNAL_STORAGE permission on this shared storage. It is illustrative to consider two common examples. device implementations MAY allocate internal (non-removable) storage as shared storage for apps. and call onCreate. load the Android package into the Dalvik VM. re-launching an alreadyrunning application after it has been launched must take less than the original launch time.0 compatible device defined in the table below: Metric Performance Threshold The following applications should launch within the specified time. if a device implementation uses internal fixed storage to satisfy this requirement. 57].hardware. a FAT-formatted SD card 1GB in size or larger MUST be included with the device as sold to users. If the device implementation supports Media Transfer Protocol: The device implementation SHOULD be compatible with the reference Android MTP host. The device implementation SHOULD report a USB device class of 0x00. Device implementations MUST enforce as documented the android. it MUST implement the Android Debug Bridge via local-area network (such as Ethernet or 802.) Device implementations that include multiple shared storage paths (such as both an SD card slot and shared internal storage) SHOULD modify the core applications such as the media scanner and ContentProvider to transparently support files placed in both locations. Comments The launch time is measured as the total time to complete loading the default activity for the application. such as a Secure Digital card. but if so MUST ship with a cable or cables adapting the port to standard USB-A it MUST implement the Android USB host API as documented in the Android SDK.usb.hardware.

Alternate runtimes MUST NOT be launched with.apk files of alternate runtimes MAY be included in the system image of a device implementation. The . Alternate runtimes MUST NOT be granted access to resources protected by permissions not requested in the runtime's AndroidManifest.3.9.1. or grant to other applications any privileges of the superuser (root). note that no software test package is fully comprehensive.xml file via the <uses-permission> mechanism. no permissions may be omitted. Implementations MAY add additional permissions. Specifically: Alternate runtimes SHOULD install apps via the PackageManager into separate Android sandboxes (that is. This will minimize the risk of . provided the new permission ID strings are not in the android. altered. Alternate runtimes MUST abide by the Android sandbox model. in which each application runs as a unique Unix-style UID and in a separate process. If the runtime environment does not record application capabilities in this manner. as described in this section. etc. 10. Alternate runtimes and installed applications using an alternate runtime MUST NOT reuse the sandbox of any other app installed on the device. Device implementations MUST support running multiple applications as the same Linux user ID. or of any other user ID. Device implementations MUST support installation of self-signed applications without requiring any additional permissions/certificates from any third parties/authorities.4. Filesystem Permissions Device implementations MUST support the Android file access permissions model as defined in as defined in the Security and Permissions reference [Resources. the alternate runtime MUST inform the user that the application will be able to access that resource.) Alternate runtimes MAY provide a single Android sandbox shared by all applications using the alternate runtime. Alternate runtimes MUST NOT permit applications to make use of features protected by Android permissions restricted to system applications.2. GPS. Alternate Execution Environments Device implementations MAY include runtime environments that execute applications using some other software or technology than the Dalvik virtual machine or native code. except through the standard Android mechanisms of shared user ID and signing certificate Alternate runtimes MUST NOT launch with. 9. UID and Process Isolation Device implementations MUST support the Android application sandbox model. 54]. as defined in the Security and Permissions reference [Resources. provided that the applications are properly signed and constructed. Alternate runtimes MUST themselves be Android applications.* namespace. compatible devices MUST support the security mechanisms described in the follow sub-sections. and abide by the standard Android security model. be granted. 9. or be granted access to the sandboxes corresponding to other Android applications. Specifically. implementations MUST enforce each permission defined as described in the SDK documentation. Permissions Device implementations MUST support the Android permissions model as defined in the Android developer documentation [Resources. grant. 54] in the Android developer documentation. etc. That is. Security Model Compatibility Device implementations MUST implement a security model consistent with the Android platform security model as defined in Security and Permissions reference document in the APIs [Resources. but MUST be signed with a key distinct from the key used to sign other applications included with the device implementation. alternate runtimes MUST obtain user consent for the Android permissions used by the application. or ignored. such alternate execution environments MUST NOT compromise the Android security model or the security of installed Android applications. 54]. Specifically. 54]. Software Compatibility Testing Device implementations MUST pass all tests described in this section. Linux user IDs. as described elsewhere in Section 9. 9. device implementers are very strongly encouraged to make the minimum number of changes as possible to the reference and preferred implementation of Android 4. 9.0 available from the Android Open Source Project.). if an application needs to make use of a device resource for which there is a corresponding Android permission (such as Camera. For this reason. However. However. When installing applications. the runtime environment MUST list all permissions held by the runtime itself when installing any application using that runtime.

etc. a device restart MAY be required. the device implementer MUST correct the error via a software update available that can be applied per the mechanism just described. including some hardware that is optional. If an error is found in a device implementation after it has been released but within its reasonable product lifetime that is determined in consultation with the Android Compatibility Team to affect the compatibility of third-party applications. and is intended to be run by a human operator to test functionality that cannot be tested by an automated system. The CTS is designed to be run on an actual device. the CTS may itself contain bugs. and multiple revisions of the CTS may be released for Android 4. Any method can be used. Compatibility Test Suite Device implementations MUST pass the Android Compatibility Test Suite (CTS) [ Resources. . for the implementation to be considered compatible. device implementers are not expected to explicitly run the CTS Verifier on builds that differ only in trivial ways. Every device and every build MUST correctly run the CTS Verifier. CTS Verifier Device implementations MUST correctly execute all applicable cases in the CTS Verifier. provided that it can replace the entirety of the software preinstalled on the device. However. device implementations that differ from an implementation that has passed the CTS Verfier only by the set of included locales. 10. the update mechanism MUST preserve application private data and application shared data.com for clarifications and to bring up any issues that you think the document does not cover. MAY omit the CTS Verifier test.introducing bugs that create incompatibilities requiring rework and potential device updates.3. such as correct functioning of a camera and sensors. Device implementations MUST pass the latest CTS version available at the time the device software is completed. if a device possesses an accelerometer. For instance. Replica Island (available in Android Market) Each app above MUST launch and behave correctly on the implementation. Like any software. 55]. using the final shipping software on the device. Additionally. 2] available from the Android Open Source Project. Updatable Software Device implementations MUST include a mechanism to replace the entirety of the system software. 10. Device implementations MUST pass all tests for hardware which they possess.0. Specifically. Note that the upstream Android software includes an update mechanism that satisfies this requirement. Reference Applications Device implementers MUST test implementation compatibility using the following open source applications: The "Apps for Android" applications [ Resources. That is. Contact Us You can contact the document authors at compatibility@android. Test cases for features noted as optional by this Compatibility Definition Document MAY be skipped or omitted. for instance. The CTS will be versioned independently of this Compatibility Definition. The mechanism need not perform "live" upgrades . 10. as noted above.that is. 12.2. The CTS Verifier has tests for many kinds of hardware. 11. since many builds are very similar. any of the following approaches will satisfy this requirement: Over-the-air (OTA) downloads with offline update via reboot "Tethered" updates over USB from a host PC "Offline" updates via a reboot and update from a file on removable storage The update mechanism used MUST support updates without wiping user data. it MUST correctly execute the Accelerometer test case in the CTS Verifier. The CTS Verifier is included with the Compatibility Test Suite. device implementers SHOULD use the reference implementation in the Android Open Source tree as much as possible. and MUST ensure compatibility in cases of ambiguity in CTS and for any reimplementations of parts of the reference source code. branding.1.

Bluetooth Test Procedure The Compatibility Test Suite includes cases that cover basic operation of the Android RFCOMM Bluetooth API. 2. . Send 10 or messages from each device. or prompts the user with a dialog to turn on Bluetooth. 4. Close the Bluetooth Chat app on both devices by pressing Back repeatedly to get to the Launcher. Install BluetoothChat. Verify that the candidate device either turns on Bluetooth. The procedure requires two devices: a candidate device implementation running the software build to be tested a separate device implementation already known to be compatible. Setup and Installation 1. Launch BluetoothChat on the candidate device. and verify that the other device receives them correctly. and verify that the other device receives them correctly. Install BluetoothChat. it cannot be fully tested by unit tests running on a single device. Consequently. a "known good" device implementation The test procedure below refers to these devices as the "candidate" and "known good" devices. Close the BluetoothChat app on both devices by pressing Home. 5. and of a model from the device implementation being tested . Note: the above tests have some cases which end a test section by using Home.apk via 'make samples' from an Android source code tree. Test Pairing and Communication 1. Send 10 or more messages from each device.apk on the candidate device. and implicitly sent to background (via the user pressing Home. Test Bluetooth Control by Apps 1.) Each test sequence MUST be performed as described. Launch the Bluetooth Chat app on both devices. using the device Settings app. 2. scan for Bluetooth devices from within BluetoothChat (using the Menu) and pair with the known-good device. which calls finish()). scan for Bluetooth devices from within BluetoothChat (using the Menu) and pair with the candidate device. Make the known-good device discoverable from within BluetoothChat (using the Menu). However. On the known-good device. 2.that is. Test Pairing and Communication in the Reverse Direction 1. and verify that the other device receives them correctly. 6. 2. Re-launch the Bluetooth Chat app on both devices.Appendix A . 5. and some using Back. 3. since Bluetooth is a communications protocol between devices. Make the candidate device discoverable from within BluetoothChat (using the Menu). 4. The test procedure is based on the BluetoothChat sample app included in the Android open source project tree. device implementations MUST also pass the human-operated Bluetooth test procedure described below. Test Re-Launches 1. On the candidate device. 2. while Bluetooth is disabled.apk on the known-good device. 3. Launch the Bluetooth Chat app on both devices. These tests are not redundant and are not optional: the objective is to verify that the Bluetooth API and stack works correctly both when Activities are explicitly terminated (via the user pressing Back. 3. Send 10 or messages from each device. respectively. Build BluetoothChat. Unpair each device from the other.