Android software development
Android software development is the process by which new applications are created for the Android operating system. Applications are usually developed in the Java programming language using the Android Software Development Kit, but other development tools are available. As of October 2012[update], more than 700,000 applications have been developed for Android, with over 25 billion downloads. A June 2011 research indicated that over 67% of mobile developers used the platform, at the time of publication. In Q2 2012; around 105 million units of Android smartphones were shipped which acquires a total share of 68% in overall smartphones sale till Q2 2012.
Software development tools 
|Stable release||21.1.0 / February 2013|
Android SDK 
The Android software development kit (SDK) includes a comprehensive set of development tools. These include a debugger, libraries, a handset emulator based on QEMU, documentation, sample code, and tutorials. Currently supported development platforms include computers running Linux (any modern desktop Linux distribution), Mac OS X 10.5.8 or later, Windows XP or later. The officially supported integrated development environment (IDE) is Eclipse using the Android Development Tools (ADT) Plugin, though IntelliJ IDEA IDE (all editions) fully supports Android development out of the box, and NetBeans IDE also supports Android development via a plugin. Additionally, developers may use any text editor to edit Java and XML files, then use command line tools (Java Development Kit and Apache Ant are required) to create, build and debug Android applications as well as control attached Android devices (e.g., triggering a reboot, installing software package(s) remotely).
Enhancements to Android's SDK go hand in hand with the overall Android platform development. The SDK also supports older versions of the Android platform in case developers wish to target their applications at older devices. Development tools are downloadable components, so after one has downloaded the latest version and platform, older platforms and tools can also be downloaded for compatibility testing.
Android applications are packaged in .apk format and stored under
/data/app folder on the Android OS (the folder is accessible only to the root user for security reasons). APK package contains .dex files (compiled byte code files called Dalvik executables), resource files, etc.
Android Debug Bridge 
The Android Debug Bridge (ADB) is a toolkit included in the Android SDK package. It consists of both client and server-side programs that communicate with one another. The ADB is typically accessed through the command-line interface.
The format for issuing commands through the ADB is typically:
- adb [-d|-e|-s <serialNumber>] <command>
In a security issue reported in March 2011, ADB was targeted as a vector to attempt to install a rootkit on connected phones using a "resource exhaustion attack".
Fastboot is a diagnostic protocol included with the SDK package used primarily to modify the flash filesystem via a USB connection from host computer. It requires that the device be started in a boot loader or Second Program Loader mode in which only the most basic hardware initialization is performed. After enabling the protocol on the device itself, it will accept a specific set of commands sent to it via USB using a command line. Some of most commonly used fastboot commands include:
- flash - Rewrites a partition with a binary image stored on the host computer.
- erase - Erases a specific partition.
- reboot - Reboots the device into either the main operating system, the system recovery partition or back into its bootloader.
- devices - Displays a list of all devices (with the serial number) connected to the host computer.
- format - Format a specific partition. The file system of the partition must be recognized by the device.
Native development kit 
Libraries written in C and other languages can be compiled to ARM, MIPS or x86 native code and installed using the Android Native Development Kit. Native classes can be called from Java code running under the Dalvik VM using the
System.loadLibrary call, which is part of the standard Android Java classes.
Complete applications can be compiled and installed using traditional development tools. The ADB debugger gives a root shell under the Android Emulator which allows native ARM, MIPS or x86 code to be uploaded and executed. Native code can be compiled using GCC on a standard PC. Running native code is complicated by Android's use of a non-standard C library (libc, known as Bionic). The underlying graphics device is available as a framebuffer at /dev/graphics/fb0. The graphics library that Android uses to arbitrate and control access to this device is called the Skia Graphics Library (SGL), and it has been released under an open source licence. Skia has backends for both Win32 and Unix, allowing the development of cross-platform applications, and it is the graphics engine underlying the Google Chrome web browser.
Unlike Java application development based on the Eclipse IDE, the NDK is based on command-line tools and requires invoking them manually to build, deploy and debug the apps. Several third-party tools allow integrating the NDK into Eclipse and Visual Studio.
Android Open Accessory Development Kit 
The Android 3.1 platform (also backported to Android 2.3.4) introduces Android Open Accessory support, which allows external USB hardware (an Android USB accessory) to interact with an Android-powered device in a special "accessory" mode. When an Android-powered device is in accessory mode, the connected accessory acts as the USB host (powers the bus and enumerates devices) and the Android-powered device acts as the USB device. Android USB accessories are specifically designed to attach to Android-powered devices and adhere to a simple protocol (Android accessory protocol) that allows them to detect Android-powered devices that support accessory mode.
App Inventor for Android 
On 12 July 2010, Google announced the availability of App Inventor for Android, a Web-based visual development environment for novice programmers, based on MIT's Open Blocks Java library and providing access to Android devices' GPS, accelerometer and orientation data, phone functions, text messaging, speech-to-text conversion, contact data, persistent storage, and Web services, initially including Amazon and Twitter. "We could only have done this because Android’s architecture is so open," said the project director, MIT's Hal Abelson. Under development for over a year, the block-editing tool has been taught to non-majors in computer science at Harvard, MIT, Wellesley, Trinity College (Hartford,) and the University of San Francisco, where Professor David Wolber developed an introductory computer science course and tutorial book for non-computer science students based on App Inventor for Android.
HyperNext Android Creator 
HyperNext Android Creator (HAC) is a software development system aimed at beginner programmers that can help them create their own Android apps without knowing Java and the Android SDK. It is based on HyperCard that treated software as a stack of cards with only one card being visible at any one time and so is well suited to mobile phone applications that have only one window visible at a time. HyperNext Android Creator's main programming language is simply called HyperNext and is loosely based on Hypercard's HyperTalk language. HyperNext is an interpreted English-like language and has many features that allow creation of Android applications. It supports a growing subset of the Android SDK including its own versions of the GUI control types and automatically runs its own background service so apps can continue to run and process information while in the background.
The SDL library offers also a development possibility beside Java, allowing the development with C and the simple porting of existing SDL and native C applications. By injection of a small Java shim and JNI the usage of native SDL code is possible, allowing Android ports like e.g. the Jagged Alliance 2 video game.
The Simple project 
The goal of Simple is to bring an easy-to-learn-and-use language to the Android platform. Simple is a BASIC dialect for developing Android applications. It targets professional and non-professional programmers alike in that it allows programmers to quickly write Android applications that use the Android runtime components.
Similar to Microsoft Visual Basic 6, Simple programs are form definitions (which contain components) and code (which contains the program logic). The interaction between the components and the program logic happens through events triggered by the components. The program logic consists of event handlers which contain code reacting to the events.
The Simple project is not very active, the last source code update being in August 2009.
RFO Basic! 
RFO Basic is an on-device interpreter which provides simple access to hardware, sensors, sound, graphics, multitouch, file system, SQLite, network sockets, FTP, HTTP, Bluetooth, HTML GUI, encryption, SMS, phone, email, text-to-speech, voice recognition, GPS, math, string functions, list functions, and other essentials. It is an open source project which can produce full-fledged Android APK files. Development of RFO Basic is active, and there is a strong online community of RFO Basic! developers.
Basic4android is a commercial product similar to Simple. It is inspired by Microsoft Visual Basic 6 and Microsoft Visual Studio. Basic4android is very active, and there is a strong online community of Basic4android developers.
Android APIMiner 
Android APIMiner is a platform that automatically instruments the Javadoc documentation of the Android API with examples of usage, extracted from real open-source Android applications. To improve the quality of the extracted examples, APIMiner relies on an intra-procedural static slicing algorithm.
Android Developer Challenge 
The Android Developer Challenge was a competition for the most innovative application for Android. Google offered prizes totaling 10 million US dollars, distributed between ADC I and ADC II. ADC I accepted submissions from 2 January to 14 April 2008. The 50 most promising entries, announced on 12 May 2008, each received a $25,000 award to further development. It ended in early September with the announcement of ten teams that received $275,000 each, and ten teams that received $100,000 each. ADC II was announced on 27 May 2009. The first round of the ADC II closed on 6 October 2009. The first-round winners of ADC II comprising the top 200 applications were announced on 5 November 2009. Voting for the second round also opened on the same day and ended on November 25. Google announced the top winners of ADC II on November 30, with SweetDreams, What the Doodle!? and WaveSecure being nominated the overall winners of the challenge.
Community-based firmware 
There is a community of open-source enthusiasts that build and share Android-based firmware with a number of customizations and additional features, such as FLAC lossless audio support and the ability to store downloaded applications on the microSD card. This usually involves rooting the device. Rooting allows users root access to the operating system, enabling full control of the phone. In order to use custom firmwares the device's bootloader must be unlocked. Rooting alone does not allow the flashing of custom firmware. Modified firmwares allow users of older phones to use applications available only on newer releases.
Those firmware packages are updated frequently, incorporate elements of Android functionality that haven't yet been officially released within a carrier-sanctioned firmware, and tend to have fewer limitations. CyanogenMod and OMFGB are examples of such firmware.
On 24 September 2009, Google issued a cease and desist letter to the modder Cyanogen, citing issues with the re-distribution of Google's closed-source applications within the custom firmware. Even though most of Android OS is open source, phones come packaged with closed-source Google applications for functionality such as the Android Market and GPS navigation. Google has asserted that these applications can only be provided through approved distribution channels by licensed distributors. Cyanogen has complied with Google's wishes and is continuing to distribute this mod without the proprietary software. He has provided a method to back up licensed Google applications during the mod's install process and restore them when it is complete.
Java standards 
Obstacles to development include the fact that Android does not use established Java standards, that is, Java SE and ME. This prevents compatibility among Java applications written for those platforms and those for the Android platform. Android only reuses the Java language syntax and semantics, but it does not provide the full class libraries and APIs bundled with Java SE or ME. However, there are multiple tools in the market from companies such as Myriad Group and UpOnTek that provide Java ME to Android conversion services.
Android is created by the Open Handset Alliance which is led by Google. The early feedback on developing applications for the Android platform was mixed. Issues cited include bugs, lack of documentation, inadequate QA infrastructure, and no public issue-tracking system. (Google announced an issue tracker on 18 January 2008.) In December 2007, MergeLab mobile startup founder Adam MacBeth stated, "Functionality is not there, is poorly documented or just doesn't work... It's clearly not ready for prime time." Despite this, Android-targeted applications began to appear the week after the platform was announced. The first publicly available application was the Snake game. The Android Dev Phone is a SIM-unlocked and hardware-unlocked device that is designed for advanced developers. While developers can use regular consumer devices purchased at retail to test and use their applications, some developers may choose not to use a retail device, preferring an unlocked or no-contract device.
A preview release of the Android SDK was released on 12 November 2007. On 15 July 2008, the Android Developer Challenge Team accidentally sent an email to all entrants in the Android Developer Challenge announcing that a new release of the SDK was available in a "private" download area. The email was intended for winners of the first round of the Android Developer Challenge. The revelation that Google was supplying new SDK releases to some developers and not others (and keeping this arrangement private) led to widely reported frustration within the Android developer community at the time.
On 18 August 2008, the Android 0.9 SDK beta was released. This release provided an updated and extended API, improved development tools and an updated design for the home screen. Detailed instructions for upgrading are available to those already working with an earlier release. On 23 September 2008, the Android 1.0 SDK (Release 1) was released. According to the release notes, it included "mainly bug fixes, although some smaller features were added." It also included several API changes from the 0.9 version. Multiple versions have been released since it was developed .
See also 
- Syed H (24 September 2012). "Editorial: Why You Should Go Nexus". Droid Lessons. Retrieved 17 April 2013.
- "Android App Stats". Archived from the original on 2 January 2011. Retrieved 31 December 2010.
- Leena Rao (14 April 2011). "Google: 3 Billion Android Apps Installed; Downloads Up 50 Percent From Last Quarter". Techcrunch. Archived from the original on 25 April 2011. Retrieved 13 May 2011.
- "Developer Economics 2011".
- Android and iOS Surge to New Smartphone OS Record in Second Quarter, According to IDC
- "Tools Overview". Android Developers. 21 July 2009.
- "IntelliJ Android Development". Retrieved 19 September 2012.
- "NBAndroid Plugin". Retrieved 19 September 2012.
- Westfall, Jon (25 August 2009). "Backup & Restore Android Apps Using ADB". JonWestfall.com. Retrieved 2009-12-07.
- "SDK Tools".
- "Android SDK Glossary".
- "Android Debug Bridge | Android Developers" Accessed December 27, 2012
- Lemos, Robert "Open source vulnerabilities paint a target on Android" March 25, 2011, accessed December 27, 2012
- Srinivas, Davanum (2007-12-09). "Android — Invoke JNI based methods (Bridging C/C++ and Java)". Archived from the original on 16 December 2008. Retrieved 2008-12-13.
- "java.lang.System". Android Developers. Retrieved 2009-09-03.
- Leslie, Ben (13 November 2007). "Native C application for Android". Benno's blog. Archived from the original on 13 September 2009. Retrieved 2009-09-04.
- Cooksey, Tom (2007-11-07). "Native C *GRAPHICAL* applications now working on Android emulator". android-developers mailing list. Archived from the original on 16 December 2008. http://groups.google.com/group/android-developers/msg/ace258af92fff692?dmode=source&pli=1. Retrieved 2008-12-13.
- "Skia source".
- Toker, Alp (2008-09-06). "Skia graphics library in Chrome: First impressions". Archived from the original on 16 December 2008. Retrieved 2008-12-13.
- "Using Eclipse for Android C/C++ Development".
- "Tutorial: Android Native Development with Visual Studio".
- "Accessory Development Kit | Android Developers". Developer.android.com. Retrieved October 2, 2012.
- Claburn, Thomas (2010-07-12). "Google App Inventor Simplifies Android Programming". Information Week. Archived from the original on 15 July 2010. Retrieved 2010-07-12.
- Lohr, Steve (2010-07-11). "Google’s Do-It-Yourself App Creation Software". New York Times. Archived from the original on 13 July 2010. Retrieved 2010-07-12.
- Abelson, Hal (2009-07-31). "App Inventor for Android". Google Research Blog. Archived from the original on 7 August 2010. Retrieved 2010-07-12.
- Kim, Ryan (2009-12-11). "Google brings app-making to the masses". San Francisco Chronicle. Archived from the original on 17 July 2010. Retrieved 2010-07-12.
- Wolber, David. "AppInventor.org". Archived from the original on 15 July 2010. Retrieved 2010-07-12.
- "Simple DirectMedia Layer for Android". sdl.org. 2012-08-12. Retrieved 2012-09-09. "How the port works, - Android applications are Java-based, optionally with parts written in C, - As SDL apps are C-based, we use a small Java shim that uses JNI to talk to the SDL library, - This means that your application C code must be placed inside an android Java project, along with some C support code that communicates with Java, - This eventually produces a standard Android .apk package"
- JA2 Stracciatella Feedback » Jagged Alliance 2 Android Stracciatella Port RC2 Release - please test on the Bear's Pit Forum, October 3, 2011
- "Android Simple".
- "Source Code Changes List".
- "Android APIMiner".
- Chen, Jason (12 May 2008). "The Top 50 Applications". Android Developers Blog. Archived from the original on 25 September 2009. Retrieved 2009-09-04.
- Brown, Eric (13 May 2008). "Android Developer Challenge announces first-round winners". Linux for Devices.
- "ADC I Top 50 Gallery". Android Developer Challenge. Retrieved 2009-05-19.
- "Android Developer Challenge". Google Code. Retrieved 2008-01-11.
- Chu, Eric (6 October 2009). "ADC 2 Round 1 Scoring Complete". Android Developers Blog. Archived from the original on 1 November 2009. Retrieved 2009-11-03.
- "ADC 2 Overall Winners". Android Developer Challenge. Google. Archived from the original on 4 January 2011. Retrieved 2010-12-05.
- Kharif, Olga (30 November 2009). "Android Developer Challenge 2 Winners Announced". BusinessWeek. Retrieved 2010-12-05.
- "Dream android development". xda-developers forum. Retrieved 2009-09-11.
- "Android 2.1 from Motorola Droid Ported to G1". Volt Mobile. March 10, 2010.
- Wimberly, Taylor (24 September 2009). "CyanogenMod in trouble?". Android and me. Archived from the original on 3 October 2009. Retrieved 2009-09-26.
- Morrill, Dan (25 September 2009). "A Note on Google Apps for Android". Android Developers Blog. Archived from the original on 25 October 2009. Retrieved 2009-09-26.
- "The current state...". CyanogenMod Android Rom. 27 September 2009. Archived from the original on 3 November 2009. Retrieved 2009-09-27.
- van Gurp, Jilles (13 November 2007). "Google Android: Initial Impressions and Criticism". Javalobby. Retrieved 2009-03-07. "Frankly, I don't understand why Google intends to ignore the vast amount of existing implementation out there. It seems like a bad case of "not invented here" to me. Ultimately, this will slow adoption. There are already too many Java platforms for the mobile world and this is yet another one"
- "Myriad's New J2Android Converter Fuels Android Applications Gold Rush". 19 March 2010.
- "J2Android hopes you don't know that Android is Java-based". 23 March 2010. "On the other hand, you might think this is kind of a scam aimed at developers who don't really understand the nature of the platform they're targeting. My biggest complaint is that you'd think that Mikael Ricknäs, the IDG News Service reporter who wrote the first story linked to above (who toils for the same company that publishes JavaWorld), would have at least mentioned the relationship between Java and Android to make the oddness of this announcement clear."
- "Myriad CTO: J2Android moves MIDlets to "beautiful" Android framework". 31 March 2010. "We will have to wait and see exactly how much pickup J2Android actually sees. The tool isn't actually available on the open market just yet; while Schillings spoke optimistically about "converting 1,000 MIDlets in an afternoon," at the moment they're working with a few providers to transform their back catalogs. So those of you out there hoping to avoid learning how to write Android code may have to wait a while."
- Android Development Tutorial
- Paul, Ryan (2007-12-19). "Developing apps for Google Android: it's a mixed bag". Ars Technica. Archived from the original on 20 December 2007. Retrieved 2007-12-19.
- Morrill, Dan (18 January 2008). "You can't rush perfection, but now you can file bugs against it". Android Developers Blog. Retrieved 2009-09-03.
- Morrison, Scott (2007-12-19). "Glitches Bug Google's Android Software". The Wall Street Journal. Retrieved 2007-12-19.
- "Snake". Android Freeware Directory. Retrieved 2008-01-26.
- "First Android Application — Snake". Mobiles2day. 2007-11-14. Retrieved 2008-01-07.
- Metz, Cade (14 July 2008). "Google plays Hide and Seek with Android SDK". The Register. Archived from the original on 6 October 2008. Retrieved 2008-10-23.
- "Android — An Open Handset Alliance Project: Upgrading the SDK". Archived from the original on 13 September 2008. Retrieved 2008-10-24.[dead link]
- "Other SDK Releases". Android Developers. Retrieved 2009-09-02.
- "SDK Archives".
- Ed, Burnette (13 July 2010). Hello, Android: Introducing Google's Mobile Development Platform (3rd ed.). Pragmatic Bookshelf. ISBN 978-1-934356-56-2.
- Ableson, Frank; Sen, Robi; King, Chris (January 2011). Android in Action, Second Edition (2nd ed.). Manning. ISBN 978-1-935182-72-6.
- Conder, Shane; Darcey, Lauren (July 24, 2012). Android Wireless Application Development Volume II: Advanced Topics (3rd ed.). Addison-Wesley Professional. ISBN 0-321-81384-7.
- Murphy, Mark (June 26, 2009). Beginning Android (1st ed.). Apress. ISBN 1-4302-2419-3.
- Meier, Reto (March 2010). Professional Android 2 Application Development (1st ed.). Wrox Press. ISBN 978-0-470-56552-0.
- Haseman, Chris (July 21, 2008). Android Essentials (1st ed.). Apress. ISBN 1-4302-1064-8.
- Clifton, Ian (August 3, 2012). The Essentials of Android Application Development LiveLessons (Video Training) (1st ed.). Addison-Wesley Professional. ISBN 0-13-299658-8.
- Android Developers
- Building for devices at source.android.com
- Android Debug Bridge - developer.android.com