Introduction to Android Developing - WOSTWARELD


Friday, December 2, 2016

Introduction to Android Developing

What is Android?

Android is the world's most popular operating system for mobile devices and tablets. It is an open source operating system, created by Google, and available to all kinds of developers with various expertise levels, ranging from rookie to professional.
(The term 'open source' sounds pretty familiar, doesn't it? Well, open-source means software with source available for modification and bound to an open source license agreement. More about open source terminology can be found here).
From a developer's perspective, Android is a Linux-based operating system for smartphones and tablets. It includes a touch screen user interface, widgets, camera, network data monitoring and all the other features that enable a cell phone to be called a smartphone. Android is a platform that supports various applications, available through the Android Play Store. The Android platform also allows end users to develop, install and use their own applications on top of the Android framework. The Android framework is licensed under the Apache License, with Android application developers holding the right to distribute their applications under their customized license.
Android is the operating system that powers more than one billion smartphones and tablets. Since these devices make our lives so sweet, each Android version is named after a dessert. Whether it's getting directions or even slicing virtual fruit, each Android release makes something new possible. Like most software, Android is released in versions. Google has also assigned names to its versions. Below are all the versions of Android released to date:

Version       Name   Device
1.0  Android Beta    Phone
1.1  Android    Phone
1.5  Cupcake    Phone
1.6  Donut    Phone
2.0/2.1   Eclair    Phone
2.2.x  Froyo    Phone
2.3.x  Gingerbread    Phone
3.0/3.1/3.2  Honeycomb    Tablet
4.0.x  Ice Cream Sandwich    Phone / Tablet
4.1/4.2/4.3  Jelly Bean    Phone / Tablet

4.4                Kit Kat                         Phone / Tablet
5.0                Lollipop                        Phone / Tablet

As we can see in the table above, various versions of Android are supported on phones and tablets. There are umpteen Android devices available in the market from manufacturers like Samsung, HTC, Motorola and others. Google itself also has phones made in conjunction with OEMs, branded as the Nexus series.

Understanding Android:

To begin development on Android even at the application level, I think it is paramount to understand the basic internal architecture. Knowing how things are arranged inside helps us understand the application framework better, so we can can design the application in a better way.
Android is an OS based on Linux. Hence, deep inside, Android is pretty similar to Linux. To begin our dive into the Android internals, let us look at an architectural diagram.
Android Architecture Diagram
 The above diagram illustrates the Android architecture. As you can see, it is a software stack above the hardware that is provided by the OEMs. Let's start with the topmost layer, i.e., the applications.


The diagram shows four basic apps (Home, Contacts, Phone and Browser), just to give the idea that there can be multiple apps sitting on top of Android. These apps are like any user interface you use on Android; for example, when you use a music player, the GUI on which there are buttons to play, pause, seek, etc is an application. Similarly, is an app for making calls, a camera app, and so on. All these apps are not necessarily from Google. Anyone can develop an app and make it available to everyone through Google Play Store. These apps are developed in Java, and are installed directly, without the need to integrate with Android OS.

Application Framework:

Scratching further below the applications, we reach the application framework, which application developers can leverage in developing Android applications. The framework offers a huge set of APIs used by developers for various standard purposes, so that they don't have to code every basic task.The framework consists of certain entities; major ones are:
  • Activity Manager
    This manages the activities that govern the application life cycle and has several states. An application may have multiple activities, which have their own life cycles. However, there is one main activity that starts when the application is launched. Generally, each activity in an application is given a window that has its own layout and user interface. An activity is stopped when another starts, and gets back to the window that initiated it through an activity callback.
  • Notification ManagerThis manager enables the applications to create customized alerts
  • Views
    Views are used to create layouts, including components such as grids, lists, buttons, etc.
  • Resource ManagersApplications do require external resources, such as graphics, external strings, etc. All these resources are managed by the resource manager, which makes them available in a standardized way.
  • Content Provider
    Applications also share data. From time to time, one application may need some data from another application. For example, an international calling application will need to access the user's address book. This access to another application's data is enabled by the content providers.


This layer holds the Android native libraries. These libraries are written in C/C++ and offer capabilities similar to the above layer, while sitting on top of the kernel. A few of the major native libraries include
  • Surface Manager: Manages the display and composting window-ing manager. - Media framework: Supports various audio and video formats and codecs including their playback and recording.
  • System C Libraries: Standard C library like libc targeted for ARM or embedded devices.
  • OpenGL ES Libraries : These are the graphics libraries for rendering 2D and 3D graphics.
  • SQLite : A database engine for Android.

Android Run-time:

The Android run-time consists of the Dalvik Virtual Machine. It is basically a virtual machine for embedded devices, which like any other virtual machine is a byte-code interpreter. When we say it is for embedded devices, it means it is low on memory, comparatively slower and runs on battery power. Besides the Dalvik Virtual Machine, it also consists of the core libraries, which are Java libraries and are available for all devices.


The Android OS is derived from Linux Kernel 2.6 and is actually created from Linux source, compiled for mobile devices. The memory management, process management etc. are mostly similar. The kernel acts as a Hardware Abstraction Layer between hardware and the Android software stack.

Android SDK:

As already mentioned, Android is open source and hence the source code is available for all developers. In totality it is called the Android SDK. You can download, build and work on Android in a number of different ways--it all depends on what you want to do. If your goal is to develop an Android application, you don't necessarily need to download all the source. Google recommends the Eclipse IDE, for which there is an available Android Developer Tools (ADT) plugin, through which you can install the specific SDK, create projects, launch emulators, debug, etc. To see more details of Eclipse and ADT through Android's official website for developers click here.

No comments:

Post a Comment

Note: Only a member of this blog may post a comment.