Hello Android! <ul><ul><li>PuneGTUG on 6 th  June, 2009 </li></ul></ul><ul><ul><li>by Sushrut Bidwai </li></ul></ul><ul><u...
Agenda <ul><li>Brief history of Android </li></ul><ul><li>Android phones </li></ul><ul><li>Android experiments </li></ul><...
Brief history of Android <ul><li>Developed by a small unknown company, Android Inc </li></ul><ul><li>Google acquired this ...
Android phones <ul><li>T-Mobile G1 or HTC Dream, first mobile with Android. </li></ul><ul><li>HTC Magic </li></ul><ul><li>...
What is Android? <ul><li>Software stack, not an operating system </li></ul><ul><li>Linux is the operating system under And...
What's new SDK? <ul><li>Latest version available is 1.5, known as cupcake.  </li></ul><ul><li>Rumours already loud about d...
Android architecture <ul><li>Copyright © 2008 Wissen Systems. All rights reserved </li></ul>
Android architecture details <ul><li>Linux kernel </li></ul><ul><ul><li>Version 2.6, currently used </li></ul></ul><ul><ul...
Android architecture details... <ul><li>Android runtime </li></ul><ul><ul><li>DVM and core libraries </li></ul></ul><ul><u...
Application fundamentals <ul><li>AndroidManifest.xml </li></ul><ul><li>Written as Java applications </li></ul><ul><li>Appl...
Activity <ul><li>Presents visual interface </li></ul><ul><li>Each user interface is separate activity. </li></ul><ul><li>I...
Service <ul><li>Background processes </li></ul><ul><li>Works when user is using some other app. </li></ul><ul><li>Long liv...
Broadcast Receiver <ul><li>Event handling, also known as intent receiver </li></ul><ul><li>All communication is managed th...
Content providers <ul><li>Way of sharing data between processes/apps </li></ul><ul><li>Remember – each app data is stored ...
Broadcast Receiver <ul><li>Event handling, also known as intent receiver </li></ul><ul><li>All communication is managed th...
User Interface <ul><li>Built using View and ViewGroup </li></ul><ul><li>Activities UI is constricted using nodes of View a...
Resources and Assets <ul><li>Resources and assets are external elements that you want use and reference in your applicatio...
Thank you! P lease send your feedback to  [email_address] <ul><li>Copyright © 2008 Wissen Systems. All rights reserved </l...
Upcoming SlideShare
Loading in...5
×

Hello Android - Pune GTUG

19,111

Published on

Presentation for Pune GTUG session on 6th June, 2009

Published in: Technology
0 Comments
0 Likes
Statistics
Notes
  • Be the first to comment

  • Be the first to like this

No Downloads
Views
Total Views
19,111
On Slideshare
0
From Embeds
0
Number of Embeds
8
Actions
Shares
0
Downloads
109
Comments
0
Likes
0
Embeds 0
No embeds

No notes for slide

Hello Android - Pune GTUG

  1. 1. Hello Android! <ul><ul><li>PuneGTUG on 6 th June, 2009 </li></ul></ul><ul><ul><li>by Sushrut Bidwai </li></ul></ul><ul><ul><li>Copyright © 2008 Wissen Systems. All rights reserved </li></ul></ul>
  2. 2. Agenda <ul><li>Brief history of Android </li></ul><ul><li>Android phones </li></ul><ul><li>Android experiments </li></ul><ul><li>What is Android? </li></ul><ul><li>What's in new SDK? </li></ul><ul><li>Android architecture in detail </li></ul><ul><li>Application fundamentals </li></ul><ul><li>User interface </li></ul><ul><li>Resources and assets </li></ul><ul><li>Data storage </li></ul><ul><li>Content providers </li></ul><ul><li>Security and permissions </li></ul><ul><li>Developing with Eclipse </li></ul><ul><li>First Android application </li></ul><ul><li>Copyright © 2008 Wissen Systems. All rights reserved </li></ul>
  3. 3. Brief history of Android <ul><li>Developed by a small unknown company, Android Inc </li></ul><ul><li>Google acquired this company in 2005 </li></ul><ul><li>Later Google opened up to form, Open handset alliance (OHA) </li></ul><ul><li>OHA consists of </li></ul><ul><ul><li>Google </li></ul></ul><ul><ul><li>HTC </li></ul></ul><ul><ul><li>T-mobile </li></ul></ul><ul><ul><li>Sprint </li></ul></ul><ul><ul><li>China mobile, Telecom Italia etc </li></ul></ul><ul><ul><li>Vodafone, LG, Samsung, Motorola </li></ul></ul><ul><ul><li>ARM, Intel </li></ul></ul><ul><ul><li>Many others </li></ul></ul><ul><li>Copyright © 2008 Wissen Systems. All rights reserved </li></ul>
  4. 4. Android phones <ul><li>T-Mobile G1 or HTC Dream, first mobile with Android. </li></ul><ul><li>HTC Magic </li></ul><ul><li>HKC Pearl </li></ul><ul><li>HKC Imobile </li></ul><ul><li>Samsung launching a new mobile with Android </li></ul><ul><li>Copyright © 2008 Wissen Systems. All rights reserved </li></ul>
  5. 5. What is Android? <ul><li>Software stack, not an operating system </li></ul><ul><li>Linux is the operating system under Android </li></ul><ul><li>Provides application programming interface through Java/Dalvik virtual machine (DVM) </li></ul><ul><li>Dalvik hides OS complexities from app programmer, who can write apps in (best programming language :-) ) Java </li></ul><ul><li>Jxyz can be ported, or already ported, to run on DVM </li></ul><ul><li>Provides utilities and libraries like modern web browser, media support, GSM telephony and lot of other things like OpenGL, Location support. </li></ul><ul><li>My thoughts – Android is Linux based platform, customized to run on mobile/handheld devices which have limited processing power and memory. These devices will run many apps/utilities, one of them being GSM telephony. </li></ul><ul><li>Ideal target for Netbooks </li></ul><ul><li>Copyright © 2008 Wissen Systems. All rights reserved </li></ul>
  6. 6. What's new SDK? <ul><li>Latest version available is 1.5, known as cupcake. </li></ul><ul><li>Rumours already loud about donut release ie 2.0, with which LOT of new handsets are expected to come </li></ul><ul><li>Features for programmer - </li></ul><ul><ul><li>Locale support </li></ul></ul><ul><ul><li>Media framework api changes </li></ul></ul><ul><ul><li>Application defined hardware requirements </li></ul></ul><ul><ul><li>Speech recognition </li></ul></ul><ul><ul><li>Lot of other smaller changes </li></ul></ul><ul><li>Copyright © 2008 Wissen Systems. All rights reserved </li></ul>
  7. 7. Android architecture <ul><li>Copyright © 2008 Wissen Systems. All rights reserved </li></ul>
  8. 8. Android architecture details <ul><li>Linux kernel </li></ul><ul><ul><li>Version 2.6, currently used </li></ul></ul><ul><ul><li>Provides abstraction layer between hardware and rest of the stack </li></ul></ul><ul><ul><li>Security, memory management, process management, network stack, driver model </li></ul></ul><ul><li>Libraries </li></ul><ul><ul><li>Libc port variants </li></ul></ul><ul><ul><li>Media libraries for audio, video, images </li></ul></ul><ul><ul><li>Surface manager for touch screen </li></ul></ul><ul><ul><li>LibWebCore, modern web browser </li></ul></ul><ul><ul><li>SGL, 2D graphics engine </li></ul></ul><ul><ul><li>FreeType, bitmap and vector fonts </li></ul></ul><ul><ul><li>SQLite </li></ul></ul><ul><li>Copyright © 2008 Wissen Systems. All rights reserved </li></ul>
  9. 9. Android architecture details... <ul><li>Android runtime </li></ul><ul><ul><li>DVM and core libraries </li></ul></ul><ul><ul><li>Every android process runs its own process and VM instance </li></ul></ul><ul><ul><li>DVM optimized to run multiple Vms efficiently </li></ul></ul><ul><ul><li>.dex format for minimal memory footprint </li></ul></ul><ul><ul><li>Depends on kernel for threading, low level memory management etc </li></ul></ul><ul><li>Application framework </li></ul><ul><ul><li>Typical framework, which makes writing apps easier </li></ul></ul><ul><li>Applications </li></ul><ul><ul><li>All applications including, apps packaged with android platform </li></ul></ul><ul><ul><li>All apps are equal </li></ul></ul><ul><li>Copyright © 2008 Wissen Systems. All rights reserved </li></ul>
  10. 10. Application fundamentals <ul><li>AndroidManifest.xml </li></ul><ul><li>Written as Java applications </li></ul><ul><li>Applications live in their own world, separate process, VM, userId </li></ul><ul><li>Ways to share userId </li></ul><ul><li>Folder structure </li></ul><ul><li>Components </li></ul><ul><ul><li>Activities </li></ul></ul><ul><ul><li>Services </li></ul></ul><ul><ul><li>Broadcast receivers </li></ul></ul><ul><ul><li>Content providers </li></ul></ul><ul><li>Again all applications are equal </li></ul><ul><li>Copyright © 2008 Wissen Systems. All rights reserved </li></ul>
  11. 11. Activity <ul><li>Presents visual interface </li></ul><ul><li>Each user interface is separate activity. </li></ul><ul><li>Implemented by subclassing Activity class </li></ul><ul><li>Modal dialogs and floating activities </li></ul><ul><li>Activity state </li></ul><ul><li>Droiddraw and hierarchyviewer </li></ul><ul><li>Copyright © 2008 Wissen Systems. All rights reserved </li></ul>
  12. 12. Service <ul><li>Background processes </li></ul><ul><li>Works when user is using some other app. </li></ul><ul><li>Long living component </li></ul><ul><li>Implemented by subclassing Service class </li></ul><ul><li>Requires intent to activate </li></ul><ul><li>Registered in androidmanifest.xml </li></ul><ul><li>Bound services, not long living, lives through the context only </li></ul><ul><li>Communication with bound services through serviceconnection </li></ul><ul><li>Services run in app process, can be setup to run in their own process </li></ul><ul><li>Communication with remote process through AIDL. (Corba/RMI like) </li></ul><ul><li>Permissions can be setup in manifest file </li></ul><ul><li>Copyright © 2008 Wissen Systems. All rights reserved </li></ul>
  13. 13. Broadcast Receiver <ul><li>Event handling, also known as intent receiver </li></ul><ul><li>All communication is managed through intents </li></ul><ul><li>Extends BroadcastReceiver class to implement </li></ul><ul><li>Entry in manifest or dynamically registered through context class </li></ul><ul><li>Broadcast intent with sendBroadCast or sendOrderedBroadCast </li></ul><ul><li>Permissions very important, specially for platform developers. </li></ul><ul><li>Copyright © 2008 Wissen Systems. All rights reserved </li></ul>
  14. 14. Content providers <ul><li>Way of sharing data between processes/apps </li></ul><ul><li>Remember – each app data is stored separately and lost after app is uninstalled. </li></ul><ul><li>A content provider class implements standard set of methods to expose its app data to be used/consumed/created by other apps </li></ul><ul><li>Supports CRUD operations </li></ul><ul><li>Standard content providers, like contacts, files, media library provided in platform through core applications </li></ul><ul><li>REST like implementation where every data object is a URI </li></ul><ul><li>Copyright © 2008 Wissen Systems. All rights reserved </li></ul>
  15. 15. Broadcast Receiver <ul><li>Event handling, also known as intent receiver </li></ul><ul><li>All communication is managed through intents </li></ul><ul><li>Extends BroadcastReceiver class to implement </li></ul><ul><li>Entry in manifest or dynamically registered through context class </li></ul><ul><li>Broadcast intent with sendBroadCast or sendOrderedBroadCast </li></ul><ul><li>Permissions very important, specially for platform developers. </li></ul><ul><li>Copyright © 2008 Wissen Systems. All rights reserved </li></ul>
  16. 16. User Interface <ul><li>Built using View and ViewGroup </li></ul><ul><li>Activities UI is constricted using nodes of View and ViewGroup object </li></ul><ul><li>Widget – A View object which serves as interaction with user. Buttons etc </li></ul><ul><li>UI Events are handled using EventListners like onTouchListner, onClickListner </li></ul><ul><li>Menu – are also defined using View hierarchy, but programmer doesn't define own structure. </li></ul><ul><li>Menu also have their own event handling callbacks </li></ul><ul><li>Copyright © 2008 Wissen Systems. All rights reserved </li></ul>
  17. 17. Resources and Assets <ul><li>Resources and assets are external elements that you want use and reference in your application </li></ul><ul><li>Examples – Audio, Video, Images etc </li></ul><ul><li>Resources are available through R class, compiled by Android </li></ul><ul><li>Assets are accessible through AssetManager as byte streams </li></ul><ul><li>Standard set of resources are available to reference in your application </li></ul><ul><li>Copyright © 2008 Wissen Systems. All rights reserved </li></ul>
  18. 18. Thank you! P lease send your feedback to [email_address] <ul><li>Copyright © 2008 Wissen Systems. All rights reserved </li></ul>
  1. A particular slide catching your eye?

    Clipping is a handy way to collect important slides you want to go back to later.

×