Computer Games as Virtual Environments for Safety-critical Software Validation

Resource page for experiments with formal specification validation in computer games.

OR/TS2JC

TS2JavaConn screenshot Open Rails screenshot

A virtual environment, where validation and evaluation of railway controllers, developed by contemporary FM, can be realized in a form of gameplay. It consists of a modified version of the Open Rails train simulator (OR) and an application called TS2JavaConn (TS2JC), which provides communication between Open Rails and the controller.

Download

Formal specification for executable prototype

B specification for executable prototype

Formal model of a cleaning robot safety-critical component, written in the B-language of B-Method. This model can be translated to C# or Java by the BKPI compiler.

Download

  • BKPI compiler in a zip file. Please, follow instructions in the included BKPICompilerInstr.pdf.

Robot controller in game engine: Formal specification for ProB animation

B specification for ProB

Formal model of the cleaning robot safety-critical component, modified for use with the ProB 2.0 Java interface.

Download

Robot controller in game engine: Unity game with the executable prototype

Unity game screenshot

Game created in the Unity engine, which uses C# code, generated from the executable prototype formal specification by the BKPI compiler.

Download

Robot controller in game engine: jMonkeyEngine game with the executable prototype

jMonkeyEngine game screenshot

Game created in the jMonkeyEngine engine, which uses Java code, generated from the executable prototype formal specification by the BKPI compiler. The game logs execution times of the updateAndEvaluate method calls into a text file called logfile.txt.

Download

Robot controller in game engine: jMonkeyEngine game with the specification animated by ProB 2.0

jMonkeyEngine game screenshot

Game created in the jMonkeyEngine engine, which animates the modified formal specification of the safety-critical component via the ProB 2.0 Java interface, integrated into it. The game logs execution times of the updateAndEvaluate method calls into a text file called logfile.txt.

Download

  • Complete project for jMonkeyEngine 3.0 in a zip file.

    This archive contains files with unusually long names, which some unpackers may fail to extract. We recommend to use WinRAR for the extraction.

Robot controller in game engine: JFireEmSim2 with the executable prototype

JFireEmSim2 screenshot

JFireEmSim2 is an emergency simulation game, where the player is a fireman whose primary goal is to rescue a family from a house under fire. The game also includes the executable prototype of the robot controller, this time disguised as a secondary fireman. An interesting feature of the game is that non-playable characters are modelled as emotional BDI agents, simulated by Jadex with a JBdiEmo emotional engine.

To start JFireEmSim2, please unpack the archive and run MyGame.exe.

Download