android architechture

22
ANDROID ARCHITECHTURE Seminar by: Yojana Nanaware M.E.(CSE)

Upload: yojana-n

Post on 07-Jul-2015

74 views

Category:

Technology


0 download

DESCRIPTION

Android is becoming very popular these and mostly everyone is crazy about it. So today with the help of a simple diagram I am going to explain the architecture of Android. I think that there is no need to tell you all about the "Android" as everyone who knows about it should also know this simple definition of Android:

TRANSCRIPT

Page 1: Android architechture

ANDROID ARCHITECHTURE

Seminar by:

Yojana Nanaware

M.E.(CSE)

Page 2: Android architechture

• Android : Concept• Android Architecture : An Overview• Platform Initialization & Explanation• Android GUI Architecture

OUTLINE

Page 3: Android architechture

"Android is a software stack for mobile devices that includes an operating system, middleware and key applications."

OR

"Android is software platform for mobile devices based on the Linux Operating System and developed by Google and the open Handset Alliance."

ANDROID……….What?

•Operating System :Operating System : Linux Kernel 2.6Linux Kernel 2.6

•Emulator :Emulator : On Mac, Windows, LinuxOn Mac, Windows, Linux

•Hardware Support :Hardware Support :–GSM TelephonyGSM Telephony–Bluetooth, Wi-Fi, 3GBluetooth, Wi-Fi, 3G–Camera, GPS, Compass Camera, GPS, Compass & Accelerometer& Accelerometer

Page 4: Android architechture

Architecture of Android

Page 5: Android architechture

Applications……

• Written in java programming.• Run in VM called Dalvik VM.• Used for basic Applications.

Page 6: Android architechture

Application Framework……

• All android have to follow this skeleton.• Manage phone`s basic functions with set of services

& systems.• Simplify the reuse of the components.

Page 7: Android architechture

Libraries……

• Written in c, cpp & used by various system.• Tell the device to handle the all kind of data &

exposed to Android Developer.

Page 8: Android architechture

Libraries………

• Android Libc implementation : Custom implementation, optimized for embedded

use– BSD license– Small size and fast code paths– Very fast custom pthread implementation– Built-in support for android-specific services

(system properties, log capabilities)– Doesn't support some POSIIX features

Page 9: Android architechture

Libraries…..

• Storage, Rendering, Multimedia : – SQLite, a simple relational database management

system (No IIPC, single file)– WebKit, an application framework that provides

foundation for building a web browser– Media Framework, based on PacketVideo

openCORE platform (codec)– Optimized 2D//3D graphic library based on

OpenGL ES

Page 10: Android architechture

Libraries……..• Surface Manager Provides a system-wide surface "composer" to render all the

surfaces in a frame buffer.

– Can combined 2D and 3D surfaces– Can use OpenGL ES and 2D hardware accelerator

for its compositions

Page 11: Android architechture

Libraries……

• Audio Manager Processes multiple audio streams into PCM audio out paths.

– Handle several types of devices (headphone, ear piece, etc.)

– Redirects audio stream to the specified output

Page 12: Android architechture

Libraries………

• Hardware abstraction library Defines the interface that Android requires hardware

"drivers" to implement.

– Set of standardized APIIs the developer will have to implement

– Available for all the components a manufacturer can integrate on its Android platform

Page 13: Android architechture

Android Runtime…….

• Set of core java libraries.• Own instance of DVM for every Android application.• .Dex executable file for optimized minimum memory.

Page 14: Android architechture

Android Runtime……• DVM An interpreter-only virtual

machine (no JIT), register based.– Optimized for low memory

requirements– Designed to allow multiple VM

instances to run at one– Relying on underlying OS for

process isolation, memory management and threading support

– Executes Dalvik Executables (DEX) files which are zipped into an Android Package (APK)

Page 15: Android architechture

Linux Kernel……• Includes memory management programs, security

settings, power management software & several drivers for hardware, file system access, networking & inter-process-communication.

• Abstraction layer between hardware & rest of software stack.

Page 16: Android architechture

Linux Kernel……

• Power Management– Application uses user space library to inform the

framework about its constraints.– Constraints are implemented using lock

mechanism.

Page 17: Android architechture

Linux Kernel……

• Blinder Driver to facilitate inter-process communication between

applications and services.

– A pool of threads is associated to each application to process incoming IIPC

– The driver performs mapping of object between two processes

– Binder uses an object reference as an address in a process's memory space

Page 18: Android architechture

Linux Kernel…….

• Blinder

Page 19: Android architechture

What can I do with Kernel…..?• Apart from changing it whenever you want, you can overclock

or undervolt your kernel. Not all kernels will allow you to do this. So be sure to check if it has OC/UV option.

Undervolting is when you tell the kernel to only provide a tiny amount of power for the phone to run. It does make your phone lag quite a lot, but its ability to save battery is incredible. A phone modified in this way with a custom kernel can seriously go days without charging.

Alternatively, you can overclock a phone. This is when the kernel outputs large amounts of power, amounts higher than the phone usually uses. This will eat through a battery extremely quickly, overheating can cause you serious trouble.

Page 20: Android architechture

Platform Initialization & Explanation The bootloader loads the "kernel" and starts the "Init" process. Then,

"Daemons" for handling low level hardware interfaces are started up (USB, ADB, debugger, radio). After that,"Zygote", the initial Dalvik VM process is created, and"Runtime" process initiates the "Service Manager", a key element for "Binders" and IPC communication.

"Runtime" process requests "Zygote" to start a new instance of Dalvik for running the "System Server"

The two first processes are able to handle graphic and audio outputs

All the others android components are then started.

Page 21: Android architechture

Android GUI ArchitectureAndroid GUI is single-threaded, event-driven and built on a library of nestable components. The Android UI framework is organized around the common Model-View-Controller pattern.

The Model: The model represents data or data container. The View: The View is the portion of the application responsible for rendering the display, sending audio to speakers, generating tactile feedback, and so on.The Controller: The Controller is the portion of an application that responds to external actions: a keystroke, a screen tap, an incoming call, etc. It is implemented as an event queue.

Page 22: Android architechture