Skip to main content

Notice: this Wiki will be going read only early in 2024 and edits will no longer be possible. Please see: https://gitlab.eclipse.org/eclipsefdn/helpdesk/-/wikis/Wiki-shutdown-plan for the plan.

Jump to: navigation, search

Difference between revisions of "DSDP/TML/TmLWhitepaper"

< DSDP‎ | TML
m (Framework Architecture)
(Framework Definitions)
Line 54: Line 54:
  
 
== Framework Definitions ==
 
== Framework Definitions ==
 +
 +
This section describes the components of the device emulator framework in high level definitions with the purpose of explain better what is mean of each part of this framework and how them are connected with the other TmL components.
 +
 +
=== Device Emulator ===
 +
A device emulator is a binary distribution that contains all files required to run a specific emulator. It provides network connectivity that allows for message exchange using the protocols supported by the emulator framework as well as a framebuffer display protocol.
 +
 +
The first release of TmL supports the RFB (or VNC) protocol versions 3.3, 3.7 and 3.8 to be compatible with a wide array of emulators which export the framebuffer using a VNC server.
 +
 +
Emulator types that can be supported by the framework include:
 +
 +
* QEmu running ARM Linux
 +
* QEmu running ReactOS
 +
* CoLinux running available Linux distributions
 +
* VMware virtual machine running Linux
 +
* VMware virtual machine running Windows
 +
 +
 +
=== Device Emulator Plug-in ===
 +
The Emulator binaries should be encapsulated into a plug-in project to be distributed over TmL framework. This plug-in contains some configuration files describing the emulator.
 +
 +
[[Image:wp002.gif]]
 +
Figure 1 – Device Emulator Plug-in
 +
 +
 +
Each emulator type might have one description plug-in extending TmL framework and using the extensions points available.
 +
The user will be able to create instances for these emulator if they were installed in Eclipse Platform.
 +
 +
[[Image:wp003.gif]] 
 +
Figure 2 – Eclipse Platform and TmL plug-ins
 +
 +
=== Emulator Plug-ins and Instances ===
 +
An emulator plug-in contains static information required to create and run instances of the corresponding device emulator, but it cannot contain dynamic information associated to each individual instance. Dynamic information must be stored in the Eclipse Workspace and linked to the corresponding emulator instance.
 +
Emulator instances are therefore represented as “projects” in the Eclipse Workspace. These projects are displayed in the Navigator View of the Resource Perspective, just like any other project, but they are identified by an “emulator nature” defined in the framework.
 +
The diagram below clarifies the difference between emulator plug-ins and emulator instances in the Workspace, where the latter contain internal properties that identify them.
 +
Each emulator plug-in provides common features such as a New Emulator Instance Wizard to create a new emulator instance, a start/stop mechanism and property edition.
 +
 +
[[Image:wp004.gif]]
  
 
== Framework Components ==
 
== Framework Components ==
  
 
== Framework External Interfaces ==
 
== Framework External Interfaces ==

Revision as of 16:34, 31 July 2007

A Device Emulator Framework for the Eclipse Platform


Introduction

Purpose

The purpose of the device emulator framework is to provide a layer on top of the Eclipse platform that makes it easier to integrate vendor specific emulators into the platform. It is expected to be used by device vendors to provide application development environments with integrated emulators.

Flexibility

The device emulator framework has been designed to be as flexible as possible. This means that any of the provided components can be entirely replaced by custom implementations without affecting the use of the remaining components. This is achieved by using certain design patterns and techniques that reduce component coupling, including heavy use of interfaces. Moreover, the emulator framework has been conceived to accommodate different types of device emulators or, at least, not to preclude any type of emulator from being used in conjunction with the framework.

Consistency

The device emulator framework provides a consistent set of components that follow the principles and the look-and-feel of the Eclipse platform, allowing emulator end-users to leverage their Eclipse experience.

User Interaction

The device emulator framework assumes that, in order to be useful to an application developer, it must be possible at least to start and stop the emulator, as well as to deploy executable code into it. The device emulator should also have some kind of output, either using an output device such as an emulated display or by performing actions on its environment. In the latter case, adapters must be able to translate those actions into something that can be displayed to the user on the Eclipse UI. Additionally, the emulator may be able to accept user input, and can have properties that the user can configure.

Components

The device emulator framework described in this whitepaper simplifies the implementation of a device emulator as an Eclipse plug-in. The emulator plug-in supports the creation of emulator instances that can be started and stopped according to user needs. The framework provides classes that support the implementation of the following plug-in components:

  • A New Emulator Instance Wizard;
  • An Emulator Project Nature;
  • An Emulator Instance View;
  • An emulator instance property management mechanism to handle the properties of each emulator instance, including a Property Editor;
  • An Emulator Perspective;
  • VNC Viewer Views to handle emulator input and output;
  • An Emulator Control Panel to start and stop the emulator instance.

Additional components shall be added in the future to support deployment of executable files to the emulator instances, remote execution of emulator instances and so on.

Emulator Framework Architecture

Background

The basic concepts that must underlie the architecture of the device emulator framework are described below.

  • The Eclipse platform is a portable, Java-based platform that can be extended through plug-ins by implementing extensions which plug into existing extension points;
  • The Eclipse Workbench is the Eclipse UI, a large window that contains the Eclipse menu bar, a central site at the top of the working area that usually contains an editor, and surrounding sites to the left, right and at the bottom that contain views;
  • The Eclipse Workspace is an area where Eclipse projects created using the Eclipse platform and its plug-ins are stored. The contents of the Workspace are displayed in the Navigator View in the Resource Perspective;
  • An Eclipse plug-in is a collection of Java classes and other code that contains one or more extensions that plug into one or more extension points. A plug-in can define actions, views; editors etc. and handle resources in the Workspace. A plug-in can also define new extension points.
  • The Device Emulator Framework is part of the Tools for mobile Linux (TmL) subproject of the Eclipse DSDP (Device Software Development Platform) project. The framework comprises a collection of Java classes organized and distributed as a plug-in and that collectively support the development of emulator plug-ins for the Eclipse platform.
  • An Emulator Plug-in is a plug-in that defines the properties and behavior of a device emulator, allowing the user to create instances of the emulator, customize the properties of each instance, start and stop each instance independently.

The bulk of the device emulator plug-in code will be in the classes or files that define the emulator behavior, while the emulator framework is the “glue” that supports integration with the Eclipse environment.

Framework Architecture

The diagram below shows the architecture of the device emulator framework and the relationships among the Eclipse platform, the emulator framework and the device emulator itself, emphasizing the distinction between the emulator itself and the Eclipse GUI. The diagram is based on a sample emulator that might be based on e.g. QEmu and that has an emulated keyboard, an emulated pointer (e.g. a mouse), standard output and standard error streams, two emulated displays and a set of emulated LEDs. The components shown in yellow are those that belong to the device emulator framework.

Wp001.gif

This diagram enables us to identify the main components of the device emulator framework, namely: the property management mechanism (with a properties view that was actually implemented as a property editor to comply with Eclipse standards), the input and output system (with the corresponding views and adapters), and the launching mechanism (with UI elements and the underlying mechanism that actually starts the emulated system).

The next section discusses the design details of the actual components of the emulator framework.

Framework Definitions

This section describes the components of the device emulator framework in high level definitions with the purpose of explain better what is mean of each part of this framework and how them are connected with the other TmL components.

Device Emulator

A device emulator is a binary distribution that contains all files required to run a specific emulator. It provides network connectivity that allows for message exchange using the protocols supported by the emulator framework as well as a framebuffer display protocol.

The first release of TmL supports the RFB (or VNC) protocol versions 3.3, 3.7 and 3.8 to be compatible with a wide array of emulators which export the framebuffer using a VNC server.

Emulator types that can be supported by the framework include:

  • QEmu running ARM Linux
  • QEmu running ReactOS
  • CoLinux running available Linux distributions
  • VMware virtual machine running Linux
  • VMware virtual machine running Windows


Device Emulator Plug-in

The Emulator binaries should be encapsulated into a plug-in project to be distributed over TmL framework. This plug-in contains some configuration files describing the emulator.

Wp002.gif Figure 1 – Device Emulator Plug-in


Each emulator type might have one description plug-in extending TmL framework and using the extensions points available. The user will be able to create instances for these emulator if they were installed in Eclipse Platform.

Wp003.gif Figure 2 – Eclipse Platform and TmL plug-ins

Emulator Plug-ins and Instances

An emulator plug-in contains static information required to create and run instances of the corresponding device emulator, but it cannot contain dynamic information associated to each individual instance. Dynamic information must be stored in the Eclipse Workspace and linked to the corresponding emulator instance. Emulator instances are therefore represented as “projects” in the Eclipse Workspace. These projects are displayed in the Navigator View of the Resource Perspective, just like any other project, but they are identified by an “emulator nature” defined in the framework. The diagram below clarifies the difference between emulator plug-ins and emulator instances in the Workspace, where the latter contain internal properties that identify them. Each emulator plug-in provides common features such as a New Emulator Instance Wizard to create a new emulator instance, a start/stop mechanism and property edition.

Wp004.gif

Framework Components

Framework External Interfaces

Back to the top