1 / 59

Introduction of Android

Introduction of Android. Blackmore Hsiao & Steve Hu WGT1 2008/12/26. Outline. What is Android Android Architecture Development Environment of Android. What is Android. What is Android. Android is a ROBOT that looks completely human An Open Handset Alliance Project

Télécharger la présentation

Introduction of Android

An Image/Link below is provided (as is) to download presentation Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author. Content is provided to you AS IS for your information and personal use only. Download presentation by click this link. While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server. During download, if you can't get a presentation, the file might be deleted by the publisher.


Presentation Transcript

  1. Introduction of Android Blackmore Hsiao & Steve Hu WGT1 2008/12/26

  2. Outline • What is Android • Android Architecture • Development Environment of Android

  3. What is Android

  4. What is Android • Android is a ROBOT that looks completely human • An Open Handset Alliance Project • OHA members: 47 members currently • Mobile Operators: NTT, T-Mobile, Vodafone,… • Handset Manufacturers: HTC, Moto, SE, LG, … • Semiconductor Companies: Intel, Qualcomm, … • Software Companies: Google, eBay, …

  5. What is Android • Software stack for mobile devices that includes an operating system, middleware and key applications • Using Java programming language to develop applications

  6. Features • Application framework • Enabling reuse and replacement of components • Dalvik virtual machine • Optimized for mobile devices • Integrated browser • Base on the open source WebKit engine • Optimized graphics • Powered by a custom 2D graphics library; 3D graphics based on the OpenGL ES 1.0 specification (hardware acceleration optional) • SQLite • For structured data storage

  7. Features • Media support • For common audio, video, and still image formats (MPEG4, H.264, MP3, AAC, AMR, JPG, PNG, GIF) • GSM Telephony • Hardware dependent • Bluetooth, EDGE, 3G, and WiFi • Hardware dependent • Camera, GPS, compass, and accelerometer • Hardware dependent • Rich development environment • Including a device emulator, tools for debugging, memory and performance profiling, and a plugin for the Eclipse IDE

  8. Android Architecture

  9. Android Architecture Middleware

  10. Android Architecture

  11. Activity Manager • An Activity is a chunk of code that does some work; it usually includes display UI to user, but not necessary • Typically, you'll designate one of your application's Activities as the entry point to your application • Manage the life cycle of applications and provides a common navigation backstack

  12. Window Manager • Manage all the opened Window • public void removeViewImmediate(View view) • This is not for normal applications; using it correctly requires great care

  13. Content Providers • A content provider is a data storehouse • Only required if you need to share data between multiple applications • For example, the contacts data is used by multiple applications and must be stored in a content provider

  14. View System • View represents the basic UI building block • A rich and extensible set of views: Lists, Grids, text boxes, buttons, and even an embeddeable web browser • View-Gallery • All of the views in a window are arranged in a single tree • Implementing a Custom View: override methods when FocusChanged, key event, touch screen motion event, …etc happened

  15. Package Manager • Manage the application packages that are currently installed on the device

  16. Telephony Manager • Provide access to information about the telephony services on the device • Application can register a listener to receive notification of telephony state changes

  17. Resource Manager • Providing access to non-code resources such as localized strings, graphics, and layout files

  18. Location Manager • Location information from GPS or Network • public LocationgetLastKnownLocation(String provider) • Then use the location to get latitude, longitude, altitude, speed, …etc

  19. Notification Manager • Enables all applications to display custom alerts in the status bar • To tell the user that something has happened in the background • Notification type • Persistent icon that goes in the status bar • Turning on or flashing LEDs • Alerting the user by flashing the backlight, playing a sound, or vibrating

  20. Android Architecture

  21. Libraries • Surface manager: Manage display and seamlessly composites 2D and 3D graphic • OpenGL ES: 3D graphics • SGL: 2D graphics • Media Framework: support different media type • FreeType: bitmap and vector font rendering • SSL: Secure Socket Layer • SQLite: lightweight database engine • WebKit: browser engine • Libc: standard C system library

  22. Dalvik Virtual Machine • Develop by Dan Bornstein • Named it after the fishing village of Dalvík in Eyjafjörður, Iceland • NOT a Standard Java Virtual Machine (JVM) • Compile Java source code to compact .dex file, and then run on Dalvik VM • Java class file need to use “dx” tool compile to .dex file

  23. Dalvik Virtual Machine • Register-Based Architecture (cf. Stack-Based in JVM) which is designed for resource limited mobile device • On Android, every Application runs in its own process, with its own instance of Dalvik VM

  24. Android Architecture

  25. Linux Kernal • Linux 2.6 for core system services such as security, memory management, process management, network stack, and driver model • Act as abstraction layer between hardware and the rest of software stack • Why linux? BecauseIt’s already open source!

  26. Development Environment of Android

  27. Agenda 為何使用Eclipse做為Android編輯環境 下載路徑 安裝Java Runtime Environment 安裝Android Eclipse Plugin 指定AndroidSDK位置 建立新專案與使用模擬器執行程式 Summary

  28. 為何使用Eclipse做為Android編輯環境 GO

  29. 用Eclipse開發Android的好處 1:免費 2:免費 3:免費

  30. 下載路徑 GO

  31. 下載路徑 1:下載 Google Android SDKhttp://code.google.com/android/download.html 2:下載 eclipsehttp://www.eclipse.org/downloads/ 3:下載JDKhttp://java.sun.com/javase/downloads/index.jsp

  32. 安裝Java Development Kit(JDK) GO

  33. 安裝JDK(1)

  34. 安裝JDK(2)

  35. 安裝JDK(3)

  36. 安裝JDK(4)

  37. 安裝JDK(5)

  38. 安裝Android Eclipse Plugin GO

  39. 在Help選單選擇Software Updates

  40. 在Available Software選擇Add Site

  41. 輸入URL: http://dl-ssl.google.com/android/eclipse/

  42. 勾選輸入的URL

  43. 選擇Install

  44. 選擇Next

  45. Accept the license agreement

  46. Progressing

  47. Restart

  48. 指定AndroidSDK位置 GO

  49. 選擇Window下的Preferences

  50. Browse to SDK Location

More Related