Introduction
The Android Platform is a
software stack and it was designed primarily for mobiles and tablets. This stack
as several layers from low-level operating system services that manage the
device to sample applications like dialler, contacts database and the web
browser etc., Android also comes with a software developer kit (SDK) which is
used to create Android Apps. A lot of content is available to get understanding
on Android.
Architecture
Linux Kernel Layer
The most bottom layer of software
in the Android Platform. It contains the core sources that any Android device
will rely on. Like general Linux kernel, this layer provides the most basic
operating system services such as Permissions Architecture which can be used to
restrict data access to only those processes that have authorization, Memory
and Process Management, Low level details of File and Network I/O, Interaction
with Device Drivers which are often coupled to Computing Devices. In addition
to general Linux kernel features, it also has several Android Specific
Components like Power Management Services, Memory Sharing (Android Shared
Memory) and Management (Low Memory Killer) Features, Inter Process
Communication Mechanism (Binder) and many more.
Libraries and Android Runtime
This includes a variety of system
libraries. These libraries are typically written in C and C++ and this is why
they often refer to native libraries which handle a lot of core
performance-sensitive activities on device, such as quickly rendering web pages
and updating them on display. Android has its own System C Library (Bionic LibC) which implements the
standard OS system calls which do things like process and thread creation,
mathematical computations, memory allocation and many more. Surface Manager for
updating the display, Media Framework for playing Audio / Video files, Web Kit
for rendering and displaying web pages, OpenGL for high performance graphics,
SQLite for managing in-memory relational databases.
In addition to all these
libraries it also includes Android Runtime which is for writing and running
Android Applications. This includes Core Java Libraries and Dalvik Virtual Machine.
Android Applications are
typically written in Java Programming Language, to make it easier to write
applications Android provides a lot of reusable Java Building Blocks, for
example Java (java.*) and Java X (javax.*) (Java Extension Packages) include
basic software for things like common data structures like concurrency
mechanisms and file I/O, Android
Packages (android.*) that have software that’s specific to the life cycle of
mobile applications, ORG Packages (org.*) that support various internet or web
operations, JUnit (junit.*) Packages which support the Unit Testing of
applications.
Dalvik Virtual Machine is the
software that executes android applications. Once an App is written in Java,
the files are compiled into multiple Java Byte Code Files, which are converted
by a tool called DX into a single DEX Code File which is usually called classes.dex, then the .dex file is packaged with other
application resources and installed on the device. When the application is
launched the DVM executes the classes.dex
file. Since DVM unlike JVM was designed to run in a resource-constrained
environment which is typical of mobile devices.
Application Framework
Contains the reusable software
that many mobile applications are likely to need, for example the
· Package
Manager is a database that keeps track of all the applications currently
installed on device. It helps one application to interact with another like data
sharing, request services.
· Window
Manager manages the windows that compromise an app.
· View
System contains the common graphical things that many applications include
in their user interfaces such as icons, buttons, text entry boxes and more.
· Resource
Manager manages the non-compiled resources that make up an application like
strings, graphics, and user interface layout files.
·
Activity
Manager manages the lifecycle and navigation stack. At a high level Android
activities often correspond to a single user interface screen. Applications are
created by stringing together multiple activities through which a user can
navigate. The activity manager helps to coordinate and support this navigation.
· Content Provider(s) are essential databases that allow
applications to store and share structured information. Also these are designed
for cross applications.
· Location
Manager allows applications to receive location and movement information such
as that generated by GPS system, and this allows applications to perform
context-specific tasks.
·
Notification
Manager allows applications to place information in the notification bar.
Application Layer
Android comes with a set of default applications such as
Home Screen, Contacts, Browser, Mail, Phone and more. The beauty of android is
none of these apps are hard-coded into the system which means that if we’ve a
better app we can substitute it in place of these standard apps.
We'll see the Android Development Environment in the next post.
Keep Watching