Now that I have a development environment for Flash and the Droid 2, I used the initial sample provided by Adobe as a starting point. Here are the steps I followed to get a working Android application deployed on the phone (total time less than 30 minutes – including development of the necessary icons).
- Within the Flash CS5 application – File > New > Template Tab > AIR for Android > Accelerometer example
- Save the file locally (Accelerometer.fla)
- Briefly review the Actionscript to make certain I understand the code snippets provided
- Within the Document properties > AIR Android settings
- Deployment tab – create certificate, specify device release for type of deployment, install application on connected device after publishing
- Icons tab – create 3 icon files (must be .png) 72 x 72, 48 x 48, and 36 x 36 – specify the file location for each size
- Permissions tab – specify the permissions on the device for this application (none)
- Publish (received warning that no permissions specified)
- Open Droid 2 and navigate to installed applications (and there it is).
Screen captures below indicate both the application as well as it running in both portrait and landscape modes. Actually, the most complex part of this exercise was to set up the development environment. Working with Flash and publishing to the device was incredibly easy and intuitive.
Applications on phone (note MD icon and Accelerometer application)
Accelerometer application running in portrait mode (yes, the ball rolls around on the screen based on the movement of the phone).
Accelerometer application running in landscape mode ( I realize the screen dimensions did not adjust – just using this as provided)
Initial thoughts – the ability to generate such an application and deploy/ test it is amazing. Now, I just have to find some time to actually develop small applications which people may find useful (or that I can use as demonstrations in my classes).