Survey
* Your assessment is very important for improving the workof artificial intelligence, which forms the content of this project
* Your assessment is very important for improving the workof artificial intelligence, which forms the content of this project
Android Platform
2009.10
NemusTech
이승민
네무스텍(주)
분야 : 모바일/임베디드
전문 : 플랫폼/솔루션
사업 : 컨설팅/디자인
Android, Linux, iPhone
Quick Tiffany 3D Modeling
panels on linear rail modeling (20 source line)
Quick remodeling with single line modification
vertical axis
Cube
Circular rail
Agenda
•
•
Google Android
•
•
•
•
Introduction
History
Current Status
Architecture
Developing Android
•
•
•
•
Building Application
Android Roadmap
Future of Android
Summary
Google Android
Current Mobile
Platform
✦ Software Stack
– Kernel ✦ the core of the SW (HW drivers, memory, filesystem, and process management)
– Middleware ✦ The set of peripheral software libraries (messaging and communication engines, WAP renders, codecs, etc)
– Application Execution Environment ✦ An application manager and set APIs
– UI framework ✦ A set of graphic components and an interaction framework
– Application Suite ✦ The set of core handset application ( IDLE screen, dialer, menu screen, contacts, calendar, etc)
Major Platforms
✦
Microsoft Windows Mobile
-
✦
✦
✦
Nokia S60 Platform
-
Lenovo,LGE,Panasonic,Samsung
-
Symbian OS 9.x (Java MIDP, C++, Python)
RIM’s BlackBerry
-
Push E-Mail Service
-
MS Exchange, Lotus Domino/Notes, Novell GroupWise
Apple’s iPhone
-
✦
Will release WM7 in 2010
Advanced UI , Robust Mac OS
Palm Pre
-
WebOS (WebKit Based)
Linux Platforms
•
•
•
•
•
•
•
•
LiMo Foundation
https://www.limofoundation.org/sf/sfmain/do/home
TrollTech
Qtopia GreenPhone
Acquired by Nokia
OpenMoko : GNU/Linux based software development platform
http://www.openmoko.org , http://www.openmoko.com
Linux Kernel, GUI using X. Org Server, GTK+,Matchbox window manager
First Supported phone, Neo1973 (also support Qtopia)
ALP (Access Linux Platform)
http://alp.access-company.com/
Nokia N810 – Maemo
http://maemo.org/
MontaVista - Mobilinux
Palm Pre - WebOS (WebKit Based)
Google - OHA, Android OS
http://www.openhandsetalliance.com/
Android : A complete set of SW for mobile devices
Operation System, Middleware, and Key mobile applications
•
•
•
•
•
•
•
•
•
•
•
Linux Platforms
• Benefits
– Linux is designed to avoid single-vendor domination
– The Linux kernel has been ported to more than a dozen chipsets
– Linux is cheap and open to innovation
– Technically competent and cost-effective for converged devices
– Several governments (most notably China) support Linux
• Challenges
– The Linux kernel is optimized for desktop and embedded
– Distribution lack the feature set requested by network operators (except Vodafone?)
– No consensus on Linux’s APIs
– Mitigating legal challenges
Smart Phone Market Share
2009 1Q Market
2009 2Q Market
Sales (1K)
Share (%)
Sales (1K)
Share (%)
Symbian
17,937.2
49.3
20,880.8
51
RIM
7,233.6
19.9
7,678.9
18.7
iPhone OS
3,938.7
10.8
5,437.7
13.3
Windows Mobile
3,733.4
10.3
3,814.3
9.3
Linux
2,540.5
7.0
1,907.1
4.6
Android
575.3
1.6
755.9
1.8
SmartPhone WebOS
0
0
205.0
0.5
Palm OS
273.2
0.8
152.8
0.4
Others
172.7
0.8
139.3
0.3
Total
36,404.6
100
40,962.8
100
Source: Gartner Press Releases
What is Android?
Android is……
a software stack
that includes an
for mobile devices
operating system,
middleware
and key applications.
....
developing applications ...
using the Java programming language.
History of Android
•
History
2001 search service for wireless device
•
•
•
•
•
•
•
•
•
2005
•
•
•
•
Acquire Android (Andy Rubin : Danger CEO, Development Sidekick of TMobile)
Acquire Skia (2D Graphics for mobile device)
Acquire RegWireless (Browser and Email for mobile device)
Move Engineers from PalmSource (Dianne Hackborn, etc…)
2007.11 Android SDK Release, OHA
2008. 2 Android Developer Challenge
2008. 11 Android Phone (G1 Phone by HTC/T-mobile)
2008. 11 Full Source Open
2009. 4 HTC Magic
2009. 7 HTC Hero, Samsung i7500, Android Netbook, Set-top......
2009. 8 Android Developer Challenge 2
Open Handset Alliance
Mobile Operators
Semiconductor Companies
Handset Manufacturers
Software Companies
Commercialized Companies
Androids......
각 제조사 사업자 별로
다양한 안드로이드 단말 개발 예정 발표
Android Devices...
First Google Android Phone Anniversary
Source from http://www.googleandblog.com
Acer Liquid – A1 – November 28th
1. Compulab Exeda
2. Dell Ophone mini3i – Benzine
3. Geek Phone One
4. General Mobile DSTL1
5. Haier H7
6. HKC Pearl
7. HighScreen PP5420
8. HTC Click – Fiesta – Tattoo
9. HTC Desire 6200 – November
10. HTC Dragon – Zoom 2
11. HTC Dream – T-Mobile G1
12. HTC Hero – G2 Touch
13. HTC Lancaster
14. HTC Magic – Sapphire – T-Mobile myTouch
3G – Google Ion – Dopod A6188
15. HTC Passion
16. HTC Predator
17. Huawei U8220 – T-Mobile Pulse
18. Huawei U8230
19. Innocomm Skate
20. Kogan Agora
21. Koolu Freerunner – Openmoko GTA02
22. Lenovo O1 Ophone
23. LG Etna
24. LG GW620 Eve – November 2009
26.
27.
28.
29.
30.
31.
32.
33.
34.
35.
36.
37.
38.
39.
40.
41.
42.
43.
44.
45.
46.
47.
48.
49.
50.
LG GW880
Motorola Calgary
Motorola Devour
Motorola Droid – Sholes – Tao – November 7th
Motorola Heron
Motorola MB200
Motorola MB300
Motorola Morrison – Cliq – DEXT
Motorola Motis – 2010
Motorola Sholes Tablet – 2010
Motorola Zeppelin – 2010
Philips V808
Qigi i6
Samsung Behold 2 T939 – November 18th
Samsung Bigfoot
Samsung Galaxy i7500
Samsung Galaxy Lite i5700 – Spica – 2010
Samsung Houdini
Samsung m850 Q
Samsung Moment – InstinctQ m900 – November
1st
Sciphone N12
Sony Ericsson XPERIA X3 / x10 Rachael –
January 2010
Sunno S880
Tiger G3
ZTE Android
T-Mobile G1/HTC
HTC Hero Sense UI
• Upgraded framework
Motorola - Cliq
•
MOTOBLUR UI
•
•
•
•
•
Home Screen
Social Networks
Contacts
Messaging
Calendar
Android Architecture
Linux Kernel
• Linux version 2.6 for core system services
• Security, Memory Management, Process
Management, network stack, driver model
• Kernel : Abstraction Layer between the
HW and the rest of the SW stack
• Android uses only “Kernel” portion in
Linux
Android Runtime
•
•
Core Libraries
•
•
•
Provides the functionality of the Java Programming Language
Android Application runs in its own process, with its own instance of the Dalvik virtual machine
Dalvik VM : Java based license free VM
•
•
•
Register based VM, optimization for low memory requirements
Executes files in the Dalvik Executable (.dex) format
DX tool converts classes to .dex format
Why Dalvik, Why Java?
•
•
•
•
Separate HW layer/ SW layer
•
Kernel is responsible for Security
Allow Multiple VM instance
To insure compatibility
•
Support different HWs (LCD, Keypad, …etc)
Avoid License Issues
Architecture in detail
•
•
•
The Design goal of Android – Openness
Be as flexible as possible
How it handles access to data (Mashups on the internet and everything
else)
Rapid development (XML, Java)
Dev Language?
App : Java
Framework : Java
Libraries : C/C++
OS & Driver : C
Creating Native C Applications
Possible, but......
•
•
•
•
•
•
•
•
Android’s Browser
•
•
•
•
WebKit based (Safari like, same with iPhone and Nokia Series 60)
•
Opera mini passed ACID3 test in Android
Highly optimized for mobile environment by Google
No flash support yet, but Hero supports Flash
Support package and interfaces for SDK
Developing Android
Android SDK
•
•
•
Tools
Emulator : QEMU + libSDL
Provide emulator console, telephony emulation, skins
DDMS (Dalvik Debug Monitor Service)
Thread/Heap/Process/Log Monitor
File Explorer
ADB Shell
Logcat, Android Log, Traceview
Samples/Docs
System and Software Requirements
Supported Operating Systems
Windows XP/Vista
Mac OS X 10.4.8 or later (x86 only)
Linux(tested on Linux Ubuntu Dapper Drake)
Supported Development Environments
Eclipse IDE
Eclipse 3.2,3.3 (Europa)
Eclipse JDT Plugin
JDK 5 or JDK 6
ADT (Android Development Tools plugin), optional
Other IDEs
JDK 5 or JDK 6
Apache Ant
GCJ(Gnu compiler for Java) not compatible
Sources
•
•
•
•
•
•
•
•
•
•
•
•
•
•
•
•
•
•
•
•
•
•
Eclipse
•
•
Using ADT (Android Development Tools) Plugin
Generate Android Template
•
Packages
•
•
•
•
src
res
assets
AndroidManifest.xml
Android Manifest
• Structured XML file, always named
AndroidManifest.xml
• Declare the application’s components
• Identifying permissions
<?xml version="1.0" encoding="utf-8"?>
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
package="com.nemustech.todolist"
android:versionCode="1"
android:versionName="1.0.0">
<application android:icon="@drawable/icon" android:label="@string/app_name">
<activity android:name=".ToDoList"
android:label="@string/app_name">
<intent-filter>
<action android:name="android.intent.action.MAIN" />
<category android:name="android.intent.category.LAUNCHER" />
</intent-filter>
</activity>
</application>
</manifest>
Building Android Application
•
•
•
Hello Android
Adding TextView
Using XML based coding
Res.layout.main.xml
•
•
•
Simple Web View
uses-permission - Internet
Using WebKit class
wv = new WebView(this);
•
•
wv.loadUrl("http://www.naver.com");
Simple Map View - Need API Key
keytool -list -alias androiddebugkey -keystore ~/.android/debug.keystore -storepass
android -keypass android
http://code.google.com/intl/ko-KR/android/maps-api-signup.html
Using MapActivity
mv = new MapView(this);
setContentView(mv);
Using XML
view class="com.google.android.maps.MapView"
•
•
•
•
Sample - API Demos
•
•
ApiDemos comes with the Android SDK - Ultimate Reference!
Each subdirectory have a high-level functional area of the Android API
•
•
•
•
•
•
•
APP
•
Examples of application-level constructs such as Activities, Alarms, Dialogs, and Services.
Content
•
Describes how to read assets from a file, from resources, and from an XML file.
Graphics
•
Many types of graphics examples, such as arcs bitmap manipulation, clipping, layers, and
OpenGL.
Media
•
MediaPlayer,VideoView
OS
•
Examples of how to invoke operating system services
Text
•
Cool text tricks
Views
•
All of the various Android views
ADB (Android Debug
Bridge)
•
Command-line debugging application included with the
SDK. It provides tools to browse the device, copy tools
on the device, and forward ports for debugging.
•
Eclipse Integration
•
•
•
•
•
ADB PUSH
ADB PULL
ADB INSTALL
ADB UNINSTALL
ADB SHELL
DDMS
• Dalvik Debug Monitor Service
• GUI debugging application included with
the SDK.
• Provides screen capture, log dump, and
process examination capabilities.
• If you are developing in Eclipse using the
ADT Plugin, DDMS is integrated into your
development environment
References
• http://developer.android.com/index.html
• Dev Guide, Blog, Groups
• Android Application Development, 1st
Edition, By Rick Rogers, John Lombardo,
O’reilly Media, Inc.
• Professional Android Application
Development, by Reto Meier, Wrox
Three Delicious Flavors
•
•
•
Managed Code
Ajax
Native Code
•
Reference
•
•
•
Google IO 2009
How Do I Code Thee?
by Dan Morrill, Google Developer Relations
Dalvik - Overview
•
Dalvik is a virtual machine, similar to the JVM
or .NET CLR
•
Memory-protected, garbage-collected, and
lifecycle-managed
•
Optimized for embedded machines
•
•
Build to reduce much of the need for a JITC
Custom bytecode format; included translator
from Java bytecode
Writing Dalvik Apps
•
•
•
Apps run on Dalvik , which provides core framework APIs
APIs are backed by system infrastructure in native code
•
e.g. OpenGL, Binder IPC, Media, etc
Popular tools are supported, and an Eclipse plugin is avaliable
Dalvik Apps
•
•
What Can You Do
•
•
•
•
Rich UIs
Background Services
Shared Components
Tight integration with system events and UI
What Can’t You Do
•
•
•
Dalvik is the primary app platform - the crossroads
Some apps need raw speed
Some apps don’t need tight integration
Dalvik - Future
• Improved (faster, better) garbage collection
• Just-In-Time Compilation
• Optimizations in core libraries
• Additional APIs -- Bluetooth, P2P, and more
Ajax(Web) - Overview
• Apps are broken up into convenient
declarative layouts & code
• JavaScript code mutates the DOM to create
UI effects
• Network access is available via
XMLHttpRequest
• Recently, <canvas> allows JavaScript to do
direct painting
Ajax on Android
• Android’s Browser is based on WebKit +
SquirrelFish
• WebKit v528.5, equivalent to Safari 4 beta
• Reports as 3.1.2 in the user-agent string
• Includes Gears 0.5.17.0 (including location)
• Includes support for the <canvas> tag
Ajax Apps
•
•
•
Of course, just build static web page apps
What can you do
•
•
•
Build dynamic UIs, via DOM or <canvas>
You can fetch & store data on your origin server
With HTML5, you can also:
•
•
•
Access location
Run code outside the main thread
Store data & pages locally
What can’t you do
•
•
Background processing
Access system & framework APIs
Ajax - Future
• HTML5 will keep getting better
• Android will continue to include a worldclass browser
• Gears today, HTML5 in the future
• Plans to upgrade to an even faster JSVM
•
Ajax - What else can
you do
Augmented Ajax
•
Inject functionality into JavaScript
Native - Overview
•
•
Launched as a Dalvik Application
•
Makes calls into native code via JNI for heavy
lifting
•
.so files are created using the NDK
complement to the SDK
•
Work-in-progress NDK added to donut branch
Loads a dynamic library (.so, ARM ELF, linked
against Bionic)
Native Apps
•
What can you do
•
•
•
•
•
•
Physics simulations
Efficient/Fast loading of large-ish data files
Speed-intensive lookups, such as for IMEs
Custom VMs
Unsupported things...
•
•
Technically, other libraries are present, but have no guarantees
Use them, and you deserve the Market user ratings you will get when your
app breaks
What can’t you do
•
•
•
Current set of APIs is limited to libm and libc
More will be added over time
h@x0r the system -- sandboxing still applies
Android NDK
•
Allows developers to implement parts of applications using native-code
languages such as C and C++
•
The NDK provides
•
•
A set of tools and build files used to generate native code libraries from C
and C++ sources
•
A way to embed the corresponding native libraries into application package
files (.apks) that can be deployed on Android devices
•
A set of native system headers and libraries that will be supported in all
future versions of the Android platform, starting from Cupcake. : libc, libm,
JNI interface headers, libz, liblog, A minimal set of headers for C++ support
•
Docs, Samples, Tutorials
Good candidates for NDK : Self-contained, CPU-intensive operations such as
signal processing, intensive physics simulations, data processing...
Native - Future
• Add additional libraries,... TBD
• No plans to make native code a fullyindependent app model
• ...but there’s no reason to prevent
developers from doing stuff
Demo
•
•
K-Means clustering
•
•
•
Used to identify clusters in sets of points
Simple 2D Version
Easy to visualize on screen
Source and App Available at :
•
•
http://code.google.com/p/hdict
http://hdict-io09.appspot.com/index.html
Benchmarks
•
•
•
Dalvik is very competitive with other pure-interpreted VMs
Dalvik, as a front-end for native code, usually beats JavaScript
•
...But clearly, there are use cases where that doesn’t matter
And of course, custom native code will always win the speed test
Android Roadmap
•
•
•
Cupcake Version : Android 1.5
•
•
•
•
•
Input method framework / Input method engines
Application Upgraded
•
Email/MMS/Alarm/Music/Browser,......
Linux Kernel Upgraded
Basic x86 Support
SDK Improvements
Donut Version : Android 1.6
•
•
•
Support for additional types of displays
AGPS (Using SUPL support)
Gesture, Universal Search, TTS, CDMA Support
Eclair Version : Android 2.0 (Flan?)
•
•
•
•
•
Google Chrome (fixed)
Google Maps, Google Earth, New Android Market
3D enhancement, Multi-Touch
Flash 10
SNS Integration
Future of Android
•
•
Business model
Organize the world’s information and make it universally
accessible and relevant
No direct-advertising component in the platform
Search and Advertisement (Network+Desktop ⇨ Mobile+Phone)
Will NOT make A gPhone
Google 700Mhz bid - FAILED but...
Open Market Store (like AppStore)
A broad developer community
License Issues?
Open Source 위주로만 구성!
ASL (Apache Software License)
Linux Kernel is licensed under (GPLv2)
•
•
•
•
•
•
•
•
•
•
Developer Challenge
•
•
•
$10 million in awards
•
•
Challenge I : Emulator Version ( Jan 2. 2008~)
Challenge II : Handset Version (Announced Recently, Oct. 2009)
Opened Project
•
•
•
•
•
•
•
Social Network (with 2d&3d animation)
FPS : Wi-Fi Army
Location Search : with google map
Drive By Ad. : Location base Ad.
Car Navigation
Mobile Shopping
Ebook with full text index : google phone search?
Location Base!
•
•
Almost Location Base Service except ebook, Social Network (over 80%)
Small group is discussing game/PDA apps
ADC Winners
!"#$%&'((
Developer: Michael Zitzelsberger
)$'*+%,-(.+/0-$($#$%&(.,%,1$'(
,%2(3'0$%2*405(6%2$'(
"!(!,*7(.$84,%0*.(&+(,'',%1$(
.$$9%1*(:0&4(7+;'(3'0$%2*<(
+'1,%0=$(&4$.(,%2(,88$5&(
0%#0&,9+%*(>(5,'&7<(*5+'&*(+'(
8+%8$'&*(
?,@$(7+;'($#$%&(.,%,1$'(:0&4(7+;(
Mash Up
•
Mash-up
New service with existing information
Not supported directly yet
Source
Google : www.google.com
ride finder
maps : street view
search by location
video & youtube
mash-up editor
google talk
GoogleMobile : www.google.com/m
gmail
calendar
notebook
docs
reader
picasaweb
3rd Party?
•
•
•
•
•
•
•
•
•
•
•
•
•
•
•
•
•
•
Android
H/W Support
GPS Location
Compass Direction Sensor
Accelerometer
Camera(Still/Video)
Network Support
GPRS
700MHz W-MAN
Wi-Fi
Intent
Access Service via URL
XMPP
Google Instant Message
Mash Up Example
•
•
•
Summary
- Android?
Benefits
•
•
•
•
Open Platform / License Free
Robust OS Kernel, Innovative Library Packages
Easy App. Development
Rapid Improvement
Challenges
•
•
•
Performance Consideration
Hard to Integrate for Vendors
Too Much Google Dependent
Key Factor : The Market Response
Thank you
zaharang@nemustech.com