Labs of Patrick Heinzelmann

The Mobile Device Simulation allows to simulate Mobile Device Feature using ADL on your desktop.

For BlackBerry PlayBook specific features, checkout the PlayBook Device Simulation which build on top of the
Flash Mobile Device Simulation.

Flash Mobile Device Simulation (ActionScript Library)

The ActionScript Library is port of the ActionScript Library for Flex and Flash. The classes have the same features
as the original library

All class paths are prefixed with de.patrickheinzelmann.*. For example: Geolocation can found
below de.patrickheinzelmann.flash.sensors.Geolocation.

Following classes and their function are supported:
  • flash.sensors.Accelerometer
  • flash.sensors.Geolocation

Download:

FlashMobileDeviceSimulation-0.0.2.swc

Flash Mobile Device Simulator (AIR Application)



The Mobile Device Simulator let you simulate device feature on your desktop with using a mobile device.

It is designed for the development with ADL (AIR Debug Launcher) and communicates with the Mobile Application using
the build-in SocketServer.

With the Mobile Device Simulator, the developer can control all classes of the Mobile Device Simulation Library.

One of the cool features of the Simulator is the support of the GPS Exchange Format 1.1 (GPX) waypoints as input format for the
automated simulation of the Geolocation. This format is widely used for description and exchange of GPS Data and is
supported by GPS navigation device like Garmin. Samples for the GPX Format can be found here.

As alternative input format for the automated simulationGeolocation, the simulator can handle custom XML files, which are
based on this XSD. Here is also an example of this format.

The Accelerometer provides also the possiblity to automate the simulation using a custom XML file corresponding this XSD
file. Here is an example of this format.

 


Integration and Usage

I'm using Conditional Compilation for the integration, because it allows me to use both (Adobe ActionScript Libraries for Flex or Flash and the
Mobile Device Simulation) libraries in the same project. Conditional Compilation is replacing ActionScript code based the configuration
variables, which you pass as arguments to the compiler.



If you have no idea how Conditional Compilation works, you can found information in the LiveDocs of Flex or take a look
on the sample applications below.

To use the Mobile Device Simulation simply start the Mobile Device Simulator (AIR application) and when
application is running start your own mobile application. Pretty simple and easy!

Sample Applications and Demos

You can download the samples as Flash Builder Project from this website or grab the source code of the samples from
my GitHub account.

Version

ActionScript Library (0.0.1) and AIR Appliation (0.0.1) are implementing the lastest productiont build of Adobe Flex SDK (4.5.0.20967)
and are based on the ActionScript Docs of Adobe Flex SDK (4.5.0), which is online available as LiveDocs for the Flash Platform.

Legal Note

Adobe Flash and Adobe Flex are trademarks of Adobe Systems.