Online Simulation

Description

To show the possibilities of the tool AutoFocus an online simulation was created. Out of a designed model of a traffic light, java code was generated.
Due to a client-server architecture the generated code can be connected to a server that makes the visual presentation of the model possible.

The Server

The server provides an interface for direct interaction. A socket can be opened for communication. Due to this interface a visualisation of the model is realized. The in and output ports are mapped to certain commands that are sent respectively received from the client.

The Client

In the HTML-page a java-applet is loaded that opens a connection to the server. Commands from the server are sent via the applet to the JavaScript-engine of the browser. This way objects inside the HTML-page can be manipulated. 

The Model

The model is a simple traffic light system that provides the possibility to request green light for pedestrians. You can download the AutoFocus qml- file here for further examination. Out of this model java source code is generated. See part of it or download complete.

Usage

Start simulation