Architecture of Android

In the earlier post on Android Development, you’ve learned how to setup android development environment. Now, before you start development, you should know the Android architecture in detail. Android architecture covers some key concepts of Android platform.

When we talk about architecture of Android we need to start with a diagram:

Android architecture
Image Credits : Android Developer Official

The above architecture diagram shows the various layers that make up the Android OS. The Android OS is roughly divided into five sections in four main layers. Each layer in the architecture provides different services to the layer just above it.

Let's examine the features of each layer in detail-

Linux Kernal

Android architecture is based on Linux 2.6 kernel. Android uses Linux kernel as a hardware abstraction layer. So if you are an OEM (Original Equipment Manufacturer), trying to bring up Android on a new device, the first thing you do is bring up Linux and get all your drivers in place. The reason of using Linux is because it provides proven driver model & in lots of cases existing drivers. It also provides memory management, process management, a security model, networking and a lot of core operating system infrastructure that are robust and have been proven over time.


Libraries run on the top of the kernel, these contains all the code that provides the main features of an Android OS. Some of the useful libraries are:

Surface Manager: The Surface Manager is used for display management. Surface Manager is responsible for composing different drawing surfaces on the screen. It manages the access for different processes to compose 2D and 3D graphic layers.

Graphics Libraries (Open GL|ES, SGL): The Open GL|ES, SGL are two core graphics libraries. The Open GL|ES is a 3D graphics library while SGL is 2D graphics library.

Media Framework: The media framework was provided by PacketVideo, one of the members of OHA. The media framework contains all of the codecs that are required for multimedia experience.

FreeType: used to render the fonts.

SSL: used for internet security.

SQLite: provides database support.

WebKit: open source browser engine.

Android Runtime

The Android runtime was designed specificly for Android to meet the need of running in an embedded environment where you have limited battery, limited memory, limited CPU. The Android runtime have two main components: Dalvik Virtual Machine & Core libraries.

The Dalvik Virtual Machine (DVM) runs something called .dex files, these are byte codes that are the results of converting .class and .jar files at built time. So these files once converted to .dex becoming much more efficient byte code, they can run very well on small processors, use memory very efficiently, data structures are designed to be shared across process whenever possible. The DVM is a register based virtual machine, there may be multiple instances of Dalvik Virtual Machine can run at same time on a device.

The Android runtime core libraries are written in java programming language. The core libraries provides the most of the functionality available in the code java libraries as well as the Android-specific libraries.

Application Framework

Application framework is the toolkit that all the applications use. These applications includes the ones that come with the phone like the home application or the phone application, includes applications written by the Google and includes the applications that written by you. So all the applications use the same framework & the same APIs.

Some of the main components of application framework are-

Activity Manager: Manages the lifecycle of all the applications.

Packages Manager: Keep track of which applications are installed on your device.

Window Manager: Manages different windows.

Telephony Manager: Contains the APIs that we use to build the phone application that central to phone experience.

Content Providers: Allows applications to share the data with other applications.

Resources Manager: Used to manage application resources.

View System: Contains building blocks of Android UI.

Location Manager: Location management, using GPS or cell tower.

Notification Manager: Manages different notifications.

XMPP Manager: Used to manage XMPP (Extensible Messaging and Presence Protocol) service.


Applications are the top layer in the Android architecture and this is where all pre-installed & our own apps exists. This layer uses the same application framework provides by the layers below.



very well documented. Helped me in learning basics.

Sandhya said...

nice explanation

Post a Comment

Recent Posts

Site Stats

Our Apps

Get it on Google Play

©2012-2015 AndroidAspect - All rights reserved | Powered by Blogger

Creative Commons License