Loading presentation...

Present Remotely

Send the link below via email or IM


Present to your audience

Start remote presentation

  • Invited audience members will follow you as you navigate and present
  • People invited to a presentation do not need a Prezi account
  • This link expires 10 minutes after you close the presentation
  • A maximum of 30 users can follow your presentation
  • Learn more about this feature in our knowledge base article

Do you really want to delete this prezi?

Neither you, nor the coeditors you shared it with will be able to recover it again.


Introduction to the Android Platform

No description

Jaeho Shin

on 21 May 2013

Comments (0)

Please log in to add your comment.

Report abuse

Transcript of Introduction to the Android Platform

Introduction to
the Android Platform Java code Market Operators Users C/C++ code App App Developers Device Makers SDK NDK Native Development Kit Allows developers to mix C/C++ code in their apps

Uses JNI (Java Native Interface) Android app is packaged into an .apk
which contains:
Dalvik executable binaries
native binaries
Other resources, e.g. images, data files Android developers write their apps in Java language.

Android developers can benefit from the rich tools support in the Java community, e.g. refactoring features in Eclipse.

However, Android is not Java SE nor Java ME. Android SDK comprises

Android Platform libraries w/ system images
Android Emulator
Dalvik Executable Compiler (dx)
AIDL compiler (aidl)
Android Asset Packaging Tool (aapt)
Android Debug Bridge (adb)
and more...

ADT is a Eclipse plugin that helps using the SDK Application Framework Linux kernel Makers port Android platform to their devices
The platform is open source: source.android.com.
It is mostly written in C/C++ with small Java glue codes. Dalvik VM Native Services, Libraries Android uses a Modified version of Linux 2.6 kernel

IPC Binder
Out Of Memory Killer
Wake Locks for Power Management
RAM Console and Log Device
Android Debug Bridge
Flash Filesystems
... Sun Java SE
= Java language + JVM + Java Class libraries
Android Java
= Java language + Dalvik + Apache Harmony Virtual registers instead of stack
JVM = Stack machine
Dalivk = Register-based arch. Optimized for
Slow CPU
No swap space
Battery powered
Fast Spawning JIT since Android 2.2 Smaller code size
Multiple .class into single .dex to share strings and constants Alternate instruction set to Java Each app runs in a separate dalvik process Bionic
... Service Manager
Media Server
System Server
{Activity,Power,Package,...} Manager
... No AWT, Swing, nor Java ME Class Library (MIDP, CLDC, ...) Binder IPC IPC is crucial since Android apps & services run in separated processes. App Fundamentals Android Apps are built with four components: Activity Service Broadcast Receiver Components are declared in AndroidManifest.xml
as well as their capabilities and app requirements Content Provider Activity corresponds to a single screen in the UI. Intent Filters declare which Intents are handled by an Activity. Different apps can start each others' activities. It starts when some matching Intent was passed to startActivity(). Service runs long operations in the background. e.g. play music in the background,
or download data over the network It starts when some matching Intent was passed to startService(). Different apps can start each others' services. Content Provider abstracts the way of reading/writing app's data. Broadcast Receiver is used for handling system-wide announcements,
e.g. battery is low, screen turned off, incoming message, ... It can be queried by invoking a targeted query() on a ContentResolver. Intents are broadcasted by sendBroadcast(), sendOrderedBroadcast(), or sendStickyBroadcast(). Many broadcasts originate from the system, but apps can also initiate them. Apps can access other apps' data through Content Providers. Native Binder Java Binder /dev/binder Passing Intent objects between apps, calling native system services, ... all rely on Binder IPC. AIDL is used for generating IPC stub and proxy in Java,
but C++ codes are all hand-crafted. Data are sent through "Parcel"s in "transaction"s with Kernel support. Mostly written in C/C++ Mostly Java + JNI glue code asdf
Full transcript