Presentation on theme: "Introduction to Android Mohammad A. Gowayyed CS334-Spring 2014."— Presentation transcript:
Introduction to Android Mohammad A. Gowayyed CS334-Spring 2014
Android OS Mobile OS for: ◦ Smart phones ◦ Tablets ◦ TVs Textbook: ◦ “Professional Android 4 Application Development”, 2012 by Reto Meier
Third-Party applications C/C++ ◦ using proprietary APIs J2ME ◦ restricted access to device hardware Generally, third party always used different APIs than native Android treats third party the same as native.
Native Android Applications client SMS management application Full PIM (personal information management) suite, including a calendar and contacts list WebKit-based web browser Music player and picture gallery Camera and video recording application Calculator Home screen Alarm clock
Android Features Access to Hardware, Including Camera, GPS, and Sensors Data Transfers Using Wi-Fi, Bluetooth, and NFC Maps, Geocoding, and Location-Based Services Background Services ◦ Notifications SQLite Database for Data Storage and Retrieval Shared Data and Inter-Application Communication ◦ Intents ◦ Content Providers
Android Features Using Widgets and Live Wallpaper to Enhance the Home Screen Extensive Media Support and 2D/3D Graphics Cloud to Device Messaging (C2DM) ◦ Event-driven applications based on server-side pushes Optimized Memory and Process Management ◦ Stop and kill processes as necessary
Android Unique Features Google Maps applications Background services and applications Shared data and inter-process communication All applications are created equal ◦ Native vs. Third-Party ◦ Same API and Same Runtime Home-screen Widgets, Live Wallpaper, and the quick search box
Open Handset Alliance(OHA) more than 80 technology companies ◦ hardware manufacturers ◦ mobile carriers ◦ software developers ◦ semiconductor companies ◦ commercialization companies made a commitment to deliver better mobile software experience
What Android Isn’t A Java ME implementation Part of the Linux Phone Standards Forum (LiPS) Simply an application layer, but a complete software stack A mobile phone handset Google’s answer to the iPhone
Comparisons Android vs. Microsoft Windows Phone Android vs. Apple iOS Both may prioritize native over third- party
Why to develop for Android? 850,000 new Android devices are activated daily No certification is required to become an Android developer Google Play provides free, up-front purchase, and in-app billing options for distribution and monetization of your applications There is no approval process for application distribution Developers have total control over their brands.
How to develop for Android? Java for Android Dalvik Virtual Machine ◦ Each Android application runs in a separate process within its own Dalvik instance Start Here: ex.html
Android Software Stack Linux Kernel Libraries Android Runtime ◦ Core libraries ◦ Dalvik VM not a JVM register-based not stack-based Android Framework Application Layer
Dalvik Virtual Machine VM designed to ensure that multiple instances run efficiently on a single device The Dalvik VM executes Dalvik executable files, a format optimized to ensure minimal memory footprint. uses the Linux kernel to handle low-level functionality, including security, threading, and process and memory management You can write C/C++ code (NDK), but why would you?NDK You create.dex executables by transforming Java language compiled classes using the tools supplied within the SDK.
Types of Android Applications Foreground ◦ Games Background ◦ Alarm ◦ SMS auto-responders Intermittent ◦ Most common ◦ expect limited interactivity but do most of their work in the background – media player. ◦ typically used as foreground but do important work in the background – and news applications. Widgets and Live Wallpapers ◦ Some applications are represented only as a home-screen Widget or as a Live Wallpaper.
Get More … Google I/O An Introduction to Android by Jason Chen ◦ YouTube: v=x1ZZ-R3p_w8 Google IO – Android Sessions ◦ YouTube: list=PL734A052F802C96B9 Readings ◦ chapters 1 to 4 Next week: Quiz on the first chapter Just read it!