Starting with AIR on Android - how to set everything up?
This article is a step by step instruction illustrated with screenshots on how to set up Flash CS5 to create AIR applications on Android device. In my case I'm going to be using HTC Desire but procedure is similar for other Android 2.1 and 2.2 phones. Instructions are based on Lee Brimelow's video tutorial from gotoAndLearn http://www.gotoandlearn.com/play.php?id=123.
IMPORTANT UPDATE: This article is now outdated, in the meantine Adobe has released the new version of AIR, new plugins to CS5 and finally the new version of Flash Professional. I encourage you to read my new tutorial on how to create and publish one AIR project that works on Android and iOS devices.
http://sierakowski.eu/list-of-tips/82-starting-with-air-for-android-and-ios-building-one-app-for-both-platforms.html
1. First things first - if you don't have Flash CS5 yet, download the trial version from Adobe (very obvious step :)).
2. Go to http://developer.android.com/sdk and download the Android SDK package for your platform. I'm going to be using package for Windows.
3. After unzipping it (I'm keeping it in my Flash projects root folder), run the "SDK Manager.exe" file to install SDK on your system. By the way, you need Java installed to use this application.
4. Close "Chose Packages to Install" window that pops up first, as we don't need anything from here to be installed. In "Android SDK and AVD Manager" window you should see "Android SDK Tools" in Installed Packages. In my case this is revision 7.

5. Windows users need to install also "USB Driver package" from Available Packages. You just need to select it and click "Install Selected" button:

6. If you are using Nexus One, Motorola or Samsung you can connect your phone to USB port and follow to step 7. I have HTC Desire and like all HTC phones it has HTC Sense installed. In order to synchronize it with your computer, you need to install HTC Sync application that will also install HTC Driver. It should be available as an exe file on memory card of your phone, so you can select "Mount a disk drive" when plugging it in to a computer and install it from there. Alternatively you can download it from here: http://www.htc.com/www/support.aspx.

Now every time when you plug your HTC to computer, you need to select "HTC Sync" option from available option on your phone. If everything is OK you should also see a notification "USB debugging connected".

7. Go to the tools folder of your unzipped Android SDK folder and find adb.exe file. This application will tell you if your device is seen by a system. Run in from Command Prompt (console) by typing adb devices. Once service is running you should see your device listed:

8. Once you are happy that our device is listed in "adb devices", you can go ahead and install the AIR for Android from the Android Market:

Alternatively you can download AIR runtimes as an apk file from Adobe website and install it using adb install.
9. Next download Flash CS5 extension (.zxp file) for AIR 2.5 that also targets AIR for Android from here: http://labs.adobe.com/technologies/flashpro_extensionforair/. Once downloaded you can just double-click it to install it in Adobe Extension Manager CS5.

If this is done you should see new template on Flash CS5 welcome screen:

10. Now you may want to set up Flash to automatically install and launch your applications on your phone which is a real time saver. To do that select AIR for Android template from the Welcome screen, and then select one of the options available. There are cool templates like Accelerometer or Swipe Gallery - they are great simple projects to get up to speed with basics of developing for Android. Once template is loaded, click on "AIR Android Settings" in "Document Properties Panel":

Open Deployment Tab and in After publish section select browse to the adb.exe file which is placed in your AndroidSDK tools folder and select "Install application on the connected Android device" and "Launch application on the connected Android device".

11. When you also configure your certificate in Deployment tab, you are ready to test template application. If you click publish, you should see application automatically launch on your device and also it will be available in your apps listing on your device.
![]()
Well done, you just installed your first Android app.
Obviously, this is not the way to sell your application, but only test when developing. You will want to place it in Android market and Lee Brimelow has done quick video tutorial on how to do that on his website: http://www.gotoandlearn.com/play.php?id=131
To take screenshots of your phone use another tool from AndroidSDK tools folder called Dalvik Debug Monitor. Launch it from ddms.bat. Then click your phone and select on"Screen Capture..." from Device menu.


Comments
Google for flashpro_extens ionforair_p2_112210.zxp
great post! Can you please send me the " CS5 Extension for AIR 2.5"?
Can't find it at Adobe's website anymore. :(
Thanks in advanced!:)
Carmen
but .. as i try to publish with air to android i get same error as fguru .. error exporting swf file
can anyone help me with this?
maybe a link to the old extension (beta 1)?
alan
I'm having one more issue here, I have Nexus S and when I test my device on adb devices Command Prompt it's not showing my device.
So just plug your device and try to publish your application from AIR Android Settings panel.
Vista 64bit OS
Nexus One device
Flash CS5
Air 2.5
I do not have the option to browse to my adb.exe in the Deployment tab > 'After Publish' section. ADB and the SDK are setup correctly. Does anyone know why that option would be missing? Thank you.