Disclaimer
Let me start off by saying that I work for Adobe so I’m probably bias (and have been for the past 15 years prior to working for Adobe). I just haven’t found better tools available that allow me to be creative. Know that my goal is to be as objective as possible. So if you feel any part seems incorrect then I’d love to hear it. Thanks!Why Android?
There are different mobile platforms available and even more mobile and tablet devices to choose from these days. The question is, which one do you target? This post focuses on creating apps for the Android operating system. Why? Because Android is now the most popular operating system among people who bought a smartphone in the past six months. Blackberry RIM and Apple iOS are in a statistical dead heat for second place, according to The Nielson Company.
Among all smartphone owners, Blackberry still holds the dominant share with 31 percent of the market, though its lead over Apple is declining. Twenty-eight percent of smartphone owners have iPhones, compared to 19 percent who have Android devices.
Exploring Android
Android is a software stack for mobile devices that includes an operating system, middleware and key applications. The Android SDK also provides the tools and APIs necessary to begin developing applications on the Android platform. Android features include:
- Integrated browser based on WebKit
- Flash Player 10.1
- Multi-touch
- Camera, GPS, compass, accelerometer, gyroscopes, magnetometers, proximity, thermometers and pressure sensors
- Multitasking
- GSM Telephony
- Bluetooth, EDGE, 3G, and WiFi
- Voice is available for Google Search Input as well as Voice actions
- SMS and MMS messaging
- Media support for audio, video, and still image formats
- Streaming media support with RTP/RTSP streaming, HTML5 video tag, Adobe Flash Streaming (RTMP) and HTTP Dynamic Streaming
- Tethering allows a phone to be used as a wireless/wired hotspot
- SQLite for structured data storage
- Optimized graphics powered by a custom 2D graphics library, 3D graphics are based on OpenGL ES
- Videocalling. The mainstream Android version doesn’t support video calling, however some handsets could have a customized version
- Java support. Note that there is no Java Virtual Machine in the platform. Java classes get recompiled into Dalvik executable and run on Dalvik virtual machine
- Application framework enabling reuse and replacement of components
- Rich development environment including a device emulator, tools for debugging, memory and performance profiling, and a plugin for the Eclipse IDE.
Android Devices
The Android OS can be used as an operating system for cellphones, netbooks and tablets. The first commercially available phone to run the Android operating system was the HTC Dream, released in October of 2008. The Android phones marketed by Google include:
- HTC G1 manufactured by HTC (internationally known as the HTC Dream)
- Nexus One manufactured by HTC
- Nexus S manufactured by Samsung
Here is a complete list of Android devices.
Since the Android OS is open source any manufacturer can take advantage of the operating system for their products. This means that there is an evergrowing number of devices appearing in the market almost daily. Some of the first Android tablets released were the 5 inch Dell Streak and the 7 inch Samsung Galaxy Tab. (I personally have the Samsung Galaxy Tab and love it.)
The world’s first TV running Android, called Scandinavia, has also been launched by the company People of Lava.
Native vs. The Flash Platform
One of the first steps in creating an Android app is to figure out what technology will be used to build it. There are basically two choices, native (Java and Android SDK) or the Flash Platform.
Going Native
In my personal experience, and in talking with mobile users, performance is better in native mobile applications. This isn’t a surprise since HTML, JavaScript and Flash were not originally made for mobile devices and yet we’re using them to create mobile apps. But this is an issue considering the average smartphone has the processing power of a computer 8 years old. Native app performance is not only consistently better, but the performance is consistent across devices.
Native Features
Advances in mobile features will always become available in the devices native language over any other technology like Flash/AIR or HTML/JavaScript. The Flash Player team does a good job of creating the mobile features in Flash (such as geolocation, accelerometer, and camera access) it will always be a slight step behind the advances in mobile development. This may or may not be a big deal depending on your app.
Native User Interface
Another benefit is that the native user interface controls are used by default when writing a native app. This makes the app familiar to users of that platform. No need to “reskin†existing components or wait for an ActionScrpt/Flash library to be made (such as as3iphonecomponents or android-components). It is important to note that most games actually reskin the native user interface controls to work with the game design. So the native user interface design is not always used in its pure form anyway.
Issues with Going Native
Since the device landscape is changing dramatically, I encourage you to look up Mobile Application Development on Wikipedia. Last I counted there were 14 different choices for application development on a mobile platform. It’s up to the developer to choose the mobile platforms to support as well as the application environment to use. Often it boils down to three:
- Apple iOS – Apple’s iOS Dev Center offers the Xcode package.
- Android – Developers can use the Android Development Tools plug-in for Eclipse.
- Windows Phone 7 – Developers use a specialized version of Microsoft Visual Studio.
Similarly, there are native application development tools for BlackBerry, Symbian, and other platforms.
An HTML/CSS/JavaScript App
I’d like to also point out that there are some nice cross-platform HTML/CSS/JavaScript based development tools available:
Even though the majority of your application is HTML/CSS/JavaScript, you will still have to use platform specific APIs to take advantage of device specific features such as multitouch and the accelerometer. One of these might be a fine solution if you’re looking at converting basic website content into an app. If you’re interested in creating a game then this probably isn’t the way to go.
The Flash Platform
The Adobe Flash Platform is a complete system of integrated tools, frameworks, servers, services, and clients that run across operating systems, browsers, and devices. Companies across industries use the Flash Platform to eliminate device and platform fragmentation, develop consistent and expressive interactive user experiences regardless of device. Lets take a look at the Flash Platform runtimes and tools.
Adobe Flash Player
The Flash player is installed on 98% of Internet-connected PCs and more than 450 million devices, offering the widest possible reach for games that run in the browser.
Adobe AIR
Adobe AIR extends Flash content beyond the browser to more mobile devices and platforms than any other runtime. It is Adobe AIR that is used to create apps for mobile devices. In Flash Professional for instance, it’s as simple as publishing a game to “AIR for Androidâ€.
Adobe Flash Professional
Flash Professional actually has its origins as an animation tool. This means that at its core it’s great for working with animation and graphics. From theses humble beginnings Flash has grown into a full fledged, powerful program able to create rich, immersive experiences complete with advanced interactivity written in ActionScript. The FWA has some great examples of this type of content. But this content can go beyond the browser and can be published to multiple platforms. Some of those platforms include:
- The Flash Player for browsers
- Adobe AIR for desktop applications
- AIR for Android for Android devices
- iOS packager for iPhone, iPod and iPad (using the Packager for iPhone)
Also note that Adobe Air and Flash Player are in the pipeline for Windows Phone 7, BlackBerry phones, and BlackBerry Tablets. In fact, Flash is an integral part of the BlackBerry PlayBook. This means users can spend more time creating and less time learning device specific frameworks and battling compatibility issues.
Adobe Flash Builder
Adobe Flash Builder provides programmers with a code-based way to create Flash applications. Users can create an app by writing ActionScript code or using the Flex Framework. The Flex Framework is a free, open source framework for developing and deploying rich Internet applications. Both can be used to create apps, but if you want to use the Flex Framework I encourage you to check out Flash Builder “Burrito”. This preview release introduces new features and enhancements to Flash Builder and provides support for the preview release of the Adobe Flex SDK codenamed “Hero.”
Flash Platform Benefits
The main issue when it comes to the “Native vs. Flash†debate is performance. Native will usually run great, but that’s not to say Flash performance is bad to say the least. In fact, it can be tough to tell the difference. Try it for yourself by downloading a Flash-based app from AppBrain.
The Flash Player team is also constantly increasing performance of the Flash Player and Flash-based apps. Recently they have been focusing on GPU processing for graphics and will even be releasing a full, low level 3D API called “Molehill†mid 2011. As long as they keep focusing on performance enhancements there’s no reason to believe that there will be much of a performance difference between native and Flash-based apps.
Workflow
Aside from the tooling already listed, we (Adobe) have a powerful workflow, allowing for designers to use programs like Adobe InDesign, Adobe Photoshop, Adobe Illustrator, and Adobe Fireworks to move graphics fairly seamlessly into Flash Professional or Flash Builder for further development. This means there are rarely conversion issues when dealing with graphics, nor is there a lengthy process to move graphics from design to development.
Create Once, Customize for Many
What developer doesn’t want to spend more time creating and less time porting code from one mobile platform to the next? Well, that’s what Flash-based apps enable you to do. With one single workflow, language, and framework you can create the base code that can be published to any device that supports Adobe AIR or the Flash Player. There might need to be some font adjustments, screen scaling and some optimization that needs to be done. Plus, you might want to take advantage of mobile specific capabilities like gestures and the acceleromenter. But overall I know many Flash developers (myself included) that have been able to do it in a day. Think about all the time you could save if you don’t have to learn every mobile device’s framework. This leaves more time to create more apps (read: money). Check out the post One Code base, 5 Hours, 5 Devices by Serge Jespers for more information. The title says it all.
Resources
The current mobile APIs available are well documented and have been growing in recent years. The Adobe communities on the other hand, have been around for easily over 15 years. This means there is already an army of expert developers and designers posting on forums, writing books, creating APIs, presenting at conferences and teaching around the world. There is a sizeable work force of experienced Flash game developers and designers ready to help. We are also committed to helping the community through online tutorials on www.AdobeTV.com as well as the Adobe Developer Connection.
Flash for Android
The Flash platform enables users to create content for “in the browser†(using the Flash Player) as well as “outside the browser†in the form of Adobe AIR for Android. This means users could potentially create a game for desktop browsers, mobile browsers and also publish it as an app. Most features are supported in both cases but it’s important to outline the differences as noted:
Flash Player 10.1 | Adobe AIR for Android | |
Multitouch | Available | Available |
Accelerometer | Available | Available |
Screen Orientation | Available | Available |
Microphone | Available | Available |
Keyboard | Available | Available |
Geolocation | Available | |
Camera Roll | Available | |
GPU | Available |
Consider using this functionality to make the app more usable on a mobile device or to add mobile specific features.
Summary
The mobile business is booming and so are Android devices. Using the tools available in the Flash Platform enables users to create apps easily to take advantage of this growing market. Future posts will deal with the specifics on how to make apps for Android devices.