Resources | developer.brewmp.com Resources | developer.brewmp.com

Developer

resources

High level overview

A device profile is essentially a collection of files containing a device's specifications necessary when creating simulation targets.

At its core is an XML file containing the device properties - Device.profile.xml. This XML file also references relevant files associated with a device profile to accurately simulate a device.

Profile Content Description
Device.swf The Adobe Flash animation that the user interacts with during simulation, which should accurately model the device's behavior (flip, screen size, key press behavior, touch, etc).
Device.profile.xml The XML meta-data describing the device, which contains all of the device properties a developer may have interest in, such as manufacturer, display size, form factor, memory, and other fields used for device comparison. This file also references a list of platform files (Brew MP runtime compiled for Windows) as well as supporting files such as configuration (.ini) files and the device SWF file.
Device specific platform files These include customized platform files that are specifically designed for the device being simulated. These files may be submitted by an OEM along with the profile.

Directory structure

The following is the device profile's directory structure showing the hierarchy of the profile files in relation to the platform files.

Profile/
   Platform Files/
      target.dll
      map.csv
      pd.dll1 
      sys/
         mod/
            oemappmgr/ OEM customized app manager
               oemappmgr.dll1
               oemappmgr.mif
               oemappmgr.ini
            oemgps/ OEM customized GPS simulation dll
               pd.dll1
               pd.mif
               pd.ini
      ...
   Device.swf
   Device.profile.xml

High level steps to create a device profile

To create a .swf file, the animation that the user interacts with, first draw the visual assets or modify existing ones shipped with the BMP SDK Pro kit. The visual assets are the graphics drawn to mimic the device keys or button components. These graphics are static drawings with no animation features. Creating visual assets using Adobe Illustrator generates a .ai file.

Second, convert the vector graphics created in the .ai file above to buttons with states such as static, hover, and pressed with different appearances for the different states, essentially animating the buttons. Then create the different states of a rotating device as pages to represent the device's various orientations such as horizontal and vertical. Both of these steps are done in Adobe Flash Catalyst, which yield a .fxp file. These button components, their layout along with the overall appearance of the device are considered the device skin.

Using Adobe Flash Builder, import the .fxp file, which generates a project within Flash Builder containing a .mxml file. Edit the .mxml file in Flash Builder to incorporate the Qualcomm BMP ActionScript API to handle key events through the Flash Player, Simulator UI and the running target. After modifying the .mxml file, a .swf file is built.

To create a profile, copy this new .swf file to a new directory, the edited device.profile.xml, and all the appropriate configuration files (.ini, .dat files, etc.) for your device from another profile directory whose device features most resemble yours. Rename your new .swf file and device.profile.xml file to match your device's name.

Create a target using the target manager, then run the simulator to test the new target, if not satisfied or encountered error(s), refine / correct at the appropriate step in the process.

The following flow diagram illustrates the high level steps to create a device profile.