Using the Simulator
Simulator Overview
The Simulator consists of two major parts: the user interface (also referred to as the "front end"), and the interface to the Simulator engine (the "back end"). Normally you would launch the whole (using "alp-sim
" but you have the option to launch only the Simulator engine (with "alp-simulator
"). The Simulator engine drives only the device's display and touchscreen; without the front end you won't see the device "skin" and you won't be able to click on simulated hard keys (but note that there are keyboard equivalents for most, if not all of these).
The Simulator front end is based upon xoo
and Xephyr. xoo
is a GTK2 based graphical wrapper around a "windowed" X server. It is intended for embedded developers who want to simulate a target device (with an accurate display size, working hardware buttons, etc.) on a desktop machine. xoo
is free software, available under the GPL. For more on xoo
, refer to http://projects.o-hand.com/xoo/.
The Simulator currently only runs on a Linux computer running a recent version of Ubuntu.
Controlling the Simulator
The Simulator is a hosted GTK application, and as such, provides you with full control over the target. You can control target configuration, creating any number of configurations to be saved and later reloaded. Any configuration can be used to start up a simulation session. Sessions can be launched, rebooted, or halted. Actions that are are specific to a target, such as pressing buttons or inserting accessories, can be performed by selecting them from a menu.
Simulated Target Device
The Simulator displays an image, or "skin," of the actual target device around a virtual touchscreen. Each skin can contain designated areas that can be used to simulate target device buttons or areas that can be used to simulate LED output. During a simulation session, you can run applications on the selected target configuration, interacting with the target either through the virtual touchscreen, device buttons, or keys, by using the host's mouse or keyboard.
User Interface

When you place your cursor over one of the buttons on the device (such as "HOME", or "5", or "volume up" [on the left side of the device image]) and click your mouse, the simulated device responds as if you had pressed the corresponding button on a real device. As well, to simulate touchscreen presses simply place your cursor on the desired spot on the touchscreen and click your mouse.
The menus with which you configure and control the Simulator are displayed at the top of the image (File, Session, Actions, Help). ACCESS Linux Platform devices have their own menus, accessed either by clicking the MENU button on the device's keypad, or by tapping the application's name in the title bar (on the touchscreen; in the above image the application's name is "Applications").
The Simulator also maps keys on your host computer keyboard to device actions. See "Operating the Simulator" for the specific keyboard mappings.
Menus
The Simulator's menu contain the items listed in Table 1.1. The File menu allows you to manipulate sesson configurations. Session control consists of (re)booting, running, and terminating the target. Target actions consist of those things that can be done to the target, such as connecting a external battery charger or informing the target of the current battery level.
Table 1.1 Simulator menu items
Menu |
Item |
Selection |
Description |
---|---|---|---|
File |
|
|
|
|
New |
|
Create a new configuration, halting any current session |
|
Open |
|
Open an existing configuration file |
|
Save |
|
Save the current configuration to the current file |
|
Save As... |
|
Save the current configuration to a file other than the current file |
|
Close |
|
Close the current configuration file and halt the session |
|
Quit |
|
Halt and exit the Simulator |
Session |
|
|
|
|
Reboot |
|
Reboot the target |
|
Launch |
|
Launch the target |
|
Halt |
|
Halt the current session |
|
View Configuration |
|
Show the current session's configuration |
Actions |
|
|
|
|
Telnet to Target |
|
Create a telnet session in a console window, connected to the simulated target |
|
Charger Connected |
|
Simulate connection or disconnection of an external power supply |
|
Battery Level... |
|
|
|
|
Full |
Set battery level to full |
|
|
Low |
Set battery level to low |
|
|
Empty |
Set battery level to empty |
Help |
|
|
|
|
About |
|
Display general information, including version and copyrights |
Target Configuration
A simulator session is an instance of a target's execution. Each target configuration specifies the attributes of the target device for a Simulator session. A configuration consists of a description of the platform image, the engine to use when simulating the target, the amount of RAM assigned to the device, the skin, and host TCP/IP settings.
The selected platform image can either be a Scratchbox target or a ROM image file (ROM image files can be any localized image, and can either be release or debug images). The selection of a simulation engine allows you to choose the type of platform virtualization.
The Simulator uses the notion of a "current configuration" which is stored using the GConf configuration system so that when you launch the Simulator the last specified configuration is recalled and used. You can specify or change this "current configuration" at any time by selecting New from the Simulator's File menu.
The Target Configuration dialog, which is displayed when you create a new session, is shown in Figure 1.1.
Figure 1.1 Target configuration dialog

The contents of this dialog are as follows:
- Scratchbox Target
- The name of the Scratchbox target. This defaults to the currently selected target in Scratchbox, but you can use the pull-down list to select a different target if you like.
- ROM Image
- If, instead of a Scratchbox target, you want to run the Simulator based upon a ROM image, you would select the radio button next to the ROM Image label and then browse to the file containing the ROM image (an
ext2
format file) by clicking the button to the right. Normally you use a Scratchbox target when simulating ACCESS Linux Platform targets, and would not use this option. - Simulation Engine
- Allows you to select between the supported Simulation engines.
- RAM Amount
- Use this to alter the amount of RAM in the simulated target device. While ACCESS Linux Platform is designed to work comfortably in 64Mb of RAM, if the device you are simulating has more, you'll want to alter this setting. As well, you may find that additional RAM improves performance.
- Skin
- Specifies the skin to be used for this target configuration. Skins are typically found in
/opt/alp-dev/share/xoo/
. - Create host network bridge
- Enables access to your local network or the Internet from inside the Simulator through the Connection Manager (or applications that use it). Selecting this option allows device applications such as the web browser to work using your host computer's network connection. See the discussion of the
--net
option under "Command-Line Options for Starting the Simulator Engine" for more specifics. - Enable NAT
- This option, which is only relevant if Create host network bridge is enabled, enables or disables Network Address Translation (NAT).
- Keep host network bridge
- If selected, causes the host network bridge to persist between simulation sessions.