Why is Android the way it is ... Navin Kabra [email_address]
<ul><li>Navin Kabra
Background:  </li><ul><li>Computer Science
B.Tech, IIT-Bombay
Ph.D, Univ of Wisconsin-Madison, USA </li></ul><li>Currently </li><ul><li>CTO, BharatHealth.com
Also founder of PuneTech </li></ul><li>Links: </li><ul><li>http://punetech.com
http://punetech.com/navin
http://smriti.com </li></ul><li>Twitter:  @_navin ,  @punetech
Email:  [email_address] </li></ul>
<ul><li>Operating system </li><ul><li>Initially targeting mobile phones
Now on more and more devices </li></ul><li>By: Open Handset Alliance </li><ul><li>Primarily Google
Also: HTC, Motorola, Intel, T-mobile, TI, Samsung
And: 47 others… </li></ul><li>Stack </li><ul><li>Linux Kernel
Java programming language
OpenGL graphics
Android’s own app development framework </li></ul></ul>Photo Credit:Android Home by Unnamed 102 (via wikipedia)
<ul><li>Kernel </li><ul><li>Drivers: display, camera, bluetooth, flash memory, binder(IPC), usb, keypad, wifi, audio, powe...
Upcoming SlideShare
Loading in …5
×

Why Android? Exploring the design desisions in Android

2,024 views

Published on

Android is a brand new platform for mobile phones, and has been created from scratch specifically for this purpose. This means that it is a ‘modern’ system that does not suffer from any legacy issues, and has taken the best ideas from various other projects to build a system that is arguably better than any of the other, competing, systems. Thus, for example, it uses the Java language as the development language, but has rejected the rest of the Java ecosystem. Specifically it uses a completely new virtual machine (Dalvik) which is redesigned with mobiles in mind – and has a number of very interesting design decisions that we will discuss. Similarly, the Android application framework represents a departure from the traditional way of doing things, and has a learning curve, but once you get used to it, it is great, especially for allowing different apps to share data, code, and in general co-operate. We will explore and discuss this and various other design decisions in Android. This talk can serve as your introduction to “”What is Android”", and more importantly, “”Why is Android”"

Published in: Technology, Education
0 Comments
1 Like
Statistics
Notes
  • Be the first to comment

No Downloads
Views
Total views
2,024
On SlideShare
0
From Embeds
0
Number of Embeds
29
Actions
Shares
0
Downloads
107
Comments
0
Likes
1
Embeds 0
No embeds

No notes for slide

Why Android? Exploring the design desisions in Android

  1. 1. Why is Android the way it is ... Navin Kabra [email_address]
  2. 2. <ul><li>Navin Kabra
  3. 3. Background: </li><ul><li>Computer Science
  4. 4. B.Tech, IIT-Bombay
  5. 5. Ph.D, Univ of Wisconsin-Madison, USA </li></ul><li>Currently </li><ul><li>CTO, BharatHealth.com
  6. 6. Also founder of PuneTech </li></ul><li>Links: </li><ul><li>http://punetech.com
  7. 7. http://punetech.com/navin
  8. 8. http://smriti.com </li></ul><li>Twitter: @_navin , @punetech
  9. 9. Email: [email_address] </li></ul>
  10. 10. <ul><li>Operating system </li><ul><li>Initially targeting mobile phones
  11. 11. Now on more and more devices </li></ul><li>By: Open Handset Alliance </li><ul><li>Primarily Google
  12. 12. Also: HTC, Motorola, Intel, T-mobile, TI, Samsung
  13. 13. And: 47 others… </li></ul><li>Stack </li><ul><li>Linux Kernel
  14. 14. Java programming language
  15. 15. OpenGL graphics
  16. 16. Android’s own app development framework </li></ul></ul>Photo Credit:Android Home by Unnamed 102 (via wikipedia)
  17. 17. <ul><li>Kernel </li><ul><li>Drivers: display, camera, bluetooth, flash memory, binder(IPC), usb, keypad, wifi, audio, power mgmt </li></ul><li>Libraries </li><ul><li>Surface, media, sqlite, opengl|es, freetype(fonts), webkit(browser), libc, ssl, sgl </li></ul><li>Java </li><ul><li>Dalvik Virtual Machine, Core java libraries </li></ul><li>Application Framework </li><ul><li>Window manager, Activities, Content Providers, View System, Notification Mgr, Package manager, Telephony manager, Resources, Location, Gtalk </li></ul><li>Applications </li><ul><li>Home, Contacts, Phone, Browser </li></ul></ul>
  18. 18. <ul><li>Re-design for mobile </li><ul><li>i.e. CPU and memory constrained systems </li></ul><li>Re-design for open-ness </li><ul><li>Everything is open source
  19. 19. Open-ness friendly license </li></ul><li>Re-design for reuse </li><ul><li>Framework encourages mashups/interoperability </li></ul></ul>
  20. 20. <ul><li>Brand new Virtual Machine: Dalvik VM
  21. 21. Optimized for low-memory requirements
  22. 22. No JARs – use DEX files </li><ul><li>Regular DEX file smaller than compressed JAR </li></ul><li>No JIT yet </li><ul><li>but (so?) lots of native code </li></ul><li>Allow multiple VMs </li><ul><li>one per app
  23. 23. better security </li></ul><li>Better use of OS kernel features </li><ul><li>Process isolation, memory mgmt, threading </li></ul></ul>
  24. 24. <ul><li>Use Apache license
  25. 25. GPL scares off device manufacturers </li><ul><li>Android kernel = linux kernel = LGPL
  26. 26. Not as scary </li></ul><li>Java wants centralized control (JCP) </li><ul><li>Another reason why no JVM
  27. 27. And Java standard libraries missing </li></ul><li>Everything is replaceable/rewriteable </li><ul><li>Including contacts, sms, telephony… </li></ul></ul>
  28. 28. <ul><li>App development framework encourages mashups
  29. 29. Activities
  30. 30. Intents
  31. 31. Content Providers </li></ul>
  32. 32. <ul><li>Apps broken up into activites
  33. 33. Each activity independently invokable
  34. 34. Example - email activites: </li><ul><li>Show one email
  35. 35. Show email list
  36. 36. Create an email
  37. 37. Pick an email recipient </li></ul><li>Share these across different apps </li></ul>
  38. 38. <ul><li>Inter-app communication via “intents”
  39. 39. Specify what you want </li><ul><li>Don’t specify how or who </li></ul><li>System picks who does it </li><ul><li>Other apps register with system
  40. 40. Indicate which intents they’re interested in handling </li></ul><li>Loose coupling allows ease of replacement </li><ul><li>Intents = XML format </li></ul></ul>
  41. 41. <ul><li>Abstract, high-level API for storing/retreiving data
  42. 42. Level of indirection between app & data storage
  43. 43. Content provider chooses data storage mechanism </li><ul><li>File-system, database, cloud (internet)
  44. 44. (By the way, SQLite is in-built) </li></ul></ul>
  45. 45. <ul><li>Java programming language used
  46. 46. But not the Java Runtime </li><ul><li>No JVM
  47. 47. No standard Java libraries
  48. 48. No JCP (Java community process)
  49. 49. No Java license
  50. 50. No JARs (i.e. no byte-code compatibility) </li></ul></ul>
  51. 51. <ul><li>Linux Kernel
  52. 52. No native windowing support </li><ul><li>i.e. no Xwindows/Xfree86/Xorg/GNOME/KDE </li></ul><li>No standard C library </li><ul><li>i.e. no glibc
  53. 53. “ Bionic” – customized, partial libc implementation
  54. 54. Only 200k (half of glibc)
  55. 55. Designed for low CPU devices
  56. 56. Customized High performance pthread library </li></ul><li>No standard linux utilities </li><ul><li>Some are there, most are missing </li></ul></ul>
  57. 57. <ul><li>In addition to Java: </li><ul><li>C, C++, Python, Lua, Scala </li></ul><li>Supports GSM (not CDMA?)
  58. 58. Touch, but not multi-touch (yet) </li></ul>
  59. 59. <ul><li>Targeted Machine
  60. 60. CPU: 250-500MHz
  61. 61. Bus: 100MHz
  62. 62. Data-cache: 16-32K
  63. 63. Memory: 64MB </li><ul><li>Low-level startup takes up 24MB
  64. 64. High-level startup takes up another 20MB
  65. 65. System library takes up another 10MB
  66. 66. Only 10MB available for apps </li></ul></ul>
  67. 67. <ul><li>Resources Alternatives by: </li><ul><li>MCC=mobile country code
  68. 68. Language and region
  69. 69. screen orientation: port, land, square
  70. 70. screen pixel density: 92dpi, 108dpi,
  71. 71. touchscreen type: notouch, stylus, finger
  72. 72. keyboard: keysexposed, keyshidden, keyssoft
  73. 73. primary input type: nokeys, qwerty, 12keys
  74. 74. primary navigation method: nonav, dpad, trackball, wheel
  75. 75. screen dimensions: 320x240, 640x480
  76. 76. sdk version: v1 (1.0), v2 (1.1), v3(1.5) </li></ul></ul>
  77. 77. Timeline of a good app <ul><li>2 months – design </li><ul><li>requirements
  78. 78. remove features (simplicity)
  79. 79. ease of use (user interaction design)
  80. 80. pretty (graphic design) </li></ul><li>2-3 weeks - core app code
  81. 81. 1 month – animations </li><ul><li>wow factor </li></ul></ul>

×