
AIS & Robotics 01 - 2 Android.pptx
- Количество слайдов: 20
Android v 0. 1 (September 24, 2012)
Outline • • History Android devices and firmware Android architecture Application development Google Play (Android Market) Comparison with other mobile OS Market position Interesting facts Android 2
History • Initially OS Android was being developed by Android Inc. • July 2005 – Google bought Anroid. • September 2007 – Google and other companies announced about creating OHA (Open Handset Alliance), a group to develop open standards for mobile devices. • September 2008 – Google together with T-Mobile and HTC announced the first Android device, a smartphone T-Mobile G 1 (HTC Dream). • December 2010 – the version 2. 3 announced. • February 2011 – the version 3. 0 announced and Android splitted in two branches, one for smartphones and the other for tablets. • October 2011 – the version 4. 0 issued, the two branches were united. • June 2012 – the version 4. 1 (the most recent at the present time) was announced. Android 3
Versions of Android Since September 2008 (Android 1. 0 was announced) 13 versions of OS Android have been issued. The version 1. 0 originally was named Astro, the version 1. 1 – Bender (a robot in «Futurama» ). But because of copyright problems those names were changed with the new ones: Apple Pie for 1. 0 and Banana Bread for 1. 1. After that all the versions got (in addition to a number) a personal name based on a dessert or sweet treat in alphabetical order: 1. 5 Cupcake (кекс), 1. 6 Donut (пончик), 2. 0 / 2. 1 Éclair etc. The most recent version is 4. 1 Jelly Bean (леденец с жевательной начинкой). The most important versions in history are: • 2. 3 Gingerbread, developed especially for smartphones, the oldest version actual at the present time; • 3. 0 Honeycomb, is not a sequel of 2. 3; it was developed specially for tablets, and two branches of Android existed separately; • 4. 0 Ice Cream Sandwich, the smartphone and tablet branches were united, and now we have a single one for all the devices. Android 4
Android devices • Smartphones (the first one was T-Mobile G 1 in September 2008). • Tablets (since February 2011, when the version 3. 0 Honeycomb was issued, more and more vendors have developed Android tablets). • Other: – digital photo frames (2009); – watches (June 2011); – cameras (August 2012); – porting to x 86 (August 2009) and ARM. • Geek enthusiasm: – Windows Mobile smartphones (emulations and on memory cards); – Mee. Go smartphones and Maemo tablets (on memory cards); – i. Phones, i. Pods and i. Pads (uses Openiboot allowing to run different OS). Android 5
Alternative firmware Android is an operating system with an open source code. The source code was published by OHA in October 2008. In autumn 2011 Google opened the 4. 0 version code. It allows to enthusiasts’ communities to develop their own modified versions of Android (custom firmware). Who needs in it? • If you want to delete Google services from your devices (for example, sending your personal data, location, preferences etc. to Google servers). • It’s quite often for Android when a vendor stops to support your device and rejects to produce a new Android version installation for your model. So, if you want to get a new version, you either buy a new device (that is the vendor wants you to do) or get the custom firmware. • Sometimes advanced users, who can program, improve their Android devices with interesting new features. Android 6
Android architecture Android 7
Android architecture Applications The highest level in Android. It contains standard user applications, for example, clients to woks with e-mail and SMS, calendar, maps, browser etc. All these applications are written in Java. Application Framework Contains services to work with resources, with the API implemented at the lower levels. This level also allows to applications to use the functions of other applications if the latter open an access for it. • View System is a set of the views with advanced functions. It’s used to build an application user interface and manages UI controls (lists, tables, text boxes, buttons and so on). • Content Providers are services allowing to applications to send the data to other applications and to get the data from them. • Resource Manager provides access to string, graphic and other resources. • Notification Manager allows to the applications to display user notifications in the status bar. Android 8
Android architecture Application Framework • Activity Manager manages the life cycles of applications, saves the history of activities and provides access to it. • Location Manager provides the functions for getting the data about geolocation etc. Libraries This level contains C/C++-libraries, they are used by different components of the OS for solving standard tasks requiring high performance. The developers access to the library functions through Application Framework. • System C library is an implementation of the standard C library (libc) for the embedded systems based on Linux. • Media Libraries support the work with audio, video and graphics. • Surface Manager provides access to the functions drawing 2 D- and 3 D-layers. • Lib. Web. Core is a web-browser engine. • SGL is an engine to work with 2 D-graphics. Android 9
Android architecture Libraries • 3 D Libraries is an engine to work with 3 D-graphics. • Free. Type is a library to work with fonts. • SQLite is an engine to work with the SQL databases. Android Runtime First of all, contains the Java core libraries implementations for Android. The Android applications work in Java environment. But instead of JVM the platform uses its own environment implementation Dalvik which is optimized for embedded systems. Every applications is run in a separate process with its own copy of the virtual machine. The executable format (Dalvik Executable, *. dex) is optimized for using memory at the lows. Linux Kernel Android is based on Linux v 2. 6. The Linux Kernel level is a layer between hardware and software. The kernel provides system services, for example, memory control, management of processes, safety, the work with drivers etc. Android 10
Dalvik Java Machine Why Dalvik is better for Android than JVM? • The license: it was necessary to get a license from Sun to use JVM in Android. Dalvik is free. • Dalvik is optimized for the processors used in embedded systems (for example, low memory usage). • New versions of Dalvik were designed for Android specially, taking into account the features of the OS. • Since Android 2. 2 Dalvik has used JIT (just-in-time) compilation. As a result, Dalvik is faster and more efficient than JVM. Android 11
Application development SDK • Android SDK (for Linux, Windows XP / Vista / 7, Mac OS X 10. 4. 8 and higher). • Requires JDK 1. 5 and higher. • Contains classes, documents, tools and USB-drivers. • Android Virtual Device (AVD) emulator. • Two sets of packages. • Many options for update. Languages • Java • C++ (Android Native Development Kit, ANDK), fits for fast applications. IDEs • Eclipse (Android Development Tools, ADT). • Intelli. J IDEA. • Net. Beans. Android 12
Application development Framework-based style When you write a framework-based application, you expand some predefined classes and implement interfaces. The application can be run only in the framework environment. Such a style limits developers’ freedom, but allows to avoid a boilerplate code and makes developers follow the patterns. Memory management In Java the objects are in memory until the garbage collector deletes them. In Dalvik, if some UI is hidden, no one guarantees that it’s still in memory. Garbage collector might delete them or might not. The same is for processes. If a process doesn’t display anything on the screen, it might be destroyed or might not. Such an organization requires a user interface stack and standard life cycle methods. User interface pattern MVVM – Model-View. Model. Android 13
Application development An Android application consists of • Java-classes; • manifest; • resources; • files. Android 14
Application development Activity has three statuses: • active – it’s visible, on the top of the screen, the code is being run; • idle – it’s visible, but not on the top and the code is not being run; • stopped – it’s invisible, the code is not being run. File types: • common files; • database; • Opaque Binary Blob (OBB); • cache-files. Android 15
Google Play (Android Market) In October 2008 Google opened an on-line shop for Android applications Android Market. In March 2012 it was renamed with Google Play. The developers, who post their applications in the market, get 70 % of a profit. In the beginning only the USA and Great Britain developers could upload their applications. Then the market was opened for the programmers from Europe and some other countries; then for Russia (difficulties in financial operations and negotiations with the mobile operators). Android 16
Comparison + Merits: • An open OS, allows to developers to implement more functions. • Much easier in communication with other devices and networks. • Files can be copied between Android devices and x 86 computers without special software. • One can install software on his Android device without Internet. One can write a program and download it on the device directly, not using the online market and not buying a special developer account. • There are portings of Android to other hardware platforms (x 86, ARM). • One can develop the applications using common programming languages. • There is no strict moderation in Google Play. – Demerits: • Many viruses, i. OS and Windows Phone 7 have a better safety. Android 17
Market positions Google Play • works in 190 countries; • contains 600 000 applications; • there have been 20 billion downloads for the period the service exists. The total amount of Android devices functioning in the world is about 500 million. Each day 1. 3 million devices are activated. There is the following evolution: Date Million activations a day February 2009 0. 012 December 2009 0. 051 December 2010 0. 3 December 2011 0. 7 July 2012 1. 0 August 2012 1. 3 Android 18
Interesting facts Oracle made a complaint against Google because of using some part of Java API in Android. Oracle tried to prove that Google used a direct Java API source code, because some methods in Android source code had the same signature as the similar methods in Java API source code. But the judge brought a verdict that the methods were not copyright subjects: «Поскольку специфический код, используемый при реализации методики, различается, каждый в соответствии с законом об охране авторских прав может написать свой собственный код для выполнения точно такой же функции или спецификаций, или же других методов, используемых в Java API. Не имеет значения, что декларации или заглавные строки методики являются идентичными. Когда существует лишь один путь для воплощения идеи или функции, каждый волен делать это, и никто не вправе монополизировать данный способ воплощения. » Android 19
References http: //ru. wikipedia. org/wiki/Android http: //ru. wikipedia. org/wiki/Open_Handset_Alliance Open Handset Alliance: http: //www. openhandsetalliance. com/ Android-x 86 Project: http: //www. android-x 86. org/ Архитектура Android: http: //habrahabr. ru/post/16770/ Архитектура Android-приложений (части 1, 2, 3 и 4): http: //habrahabr. ru/post/140459/, http: //habrahabr. ru/post/140655/, http: //habrahabr. ru/post/141201/, http: //habrahabr. ru/post/141504/ • http: //ru. wikipedia. org/wiki/Google_Play • Google Play: https: //play. google. com/store • Операционная система Google Android OS: http: //wiki. androidfan. ru/Заглавная_страница • • • Android 20
AIS & Robotics 01 - 2 Android.pptx