Technical topic: OpenGEODE, an SDL editor for TASTE

From TASTE
Jump to: navigation, search
Opengeode
Opengeode overview

Contents

Introduction

SDL (Specification and Description Language) is a powerful modelling language for visually yet formally describing state machines. As any programming language, SDL comes with a textual syntax, but in addition has an intuitive graphical notation that can be used to build models using interactive editors. The well-defined semantics of SDL makes it a good candidate for describing the behaviour of embedded, real-time systems.


The standard has been established by ITU-T under reference Z100. Among others, it is widely used in the telecommunication industry. See [1] for more information.


Thanks to its formalism, its well-defined concepts and ease of use, the SDL language is sized for the production of safe, robust software.

TASTE now includes an open-source SDL graphical editor that generates Ada code. It is free software, implemented in Python with the Qt graphical framework. The name "OpenGEODE" was chosen as a tribute to the former ObjectGEODE tool, which has unfortunately been discontinued several years ago. OpenGEODE is freely inspired from the ergonomy of its ancestor, and is trying to show how modern languages and tools can help providing a great user experience to programmers, even those who are not enclined to use a visual approach for development.


Important notice:

We are developing OpenGEODE as a technology demonstrator. Please consider it as such, and use it for your lab experiments, discovery of SDL, and for enriching your understanding of embedded, communicating systems. SDL and ASN.1 are powerful and fun languages. They are also excellent languages that can be studied to concretely understand what state machines and data types are about.

Feel free to browse the source code, that was also meant to show how Python and Qt allow, with little effort, to create amazing applications.

For professional applications, we recommend the use of the Pragmadev RTDS tool in combination with TASTE. It is a complete, large scale tool that comes with commercial support. Among other features, RTDS has a formal verifier module based on the IF technology from Verimag, that checks behavioural properties using an exhaustive simulation technique.


OpenGEODE Features

  • Graphical editor of SDL processes and procedures. The communication diagram is captured with the TASTE interface view editor.
  • SDL2010 features: FOR loops in task symbols, hierarchical states
  • Reads and save .pr files (textual SDL notation), with CIF support for the graphical information
  • Supports ASN.1 data types, including the Value notation - check this page to know more about our ASN.1 compiler and tools
  • Supports a subset of symbols that are sufficient to develop real-time applications (excluding the SAVE symbol)
  • Generates Ada code with ASN.1 types using TASTE ASN.1 "space-certified" (SPARK) compiler
  • Complete syntax and semantic checks
  • Automatic conversion to Statechart diagrams
  • Save the complete or parts of the model to PNG/SVG/PDF files
  • Hyperlinks (link a symbol content to any external document or web page)
  • Zoom in, zoom-out
  • Context-dependent text auto-completion
  • Syntax highlighting
  • Undo/Redo, Copy-Paste
  • (Limited) VIM mode - You can use :wq or :%s,search,replace,g, and /search pattern

Standalone installation

First you need to install PySide (the library providing the graphical environment). On Linux (Debian/Ubuntu) type:

$ sudo apt-get install python-pyside

On Windows you can download Pyside from the official project page here.

Then you can install and execute OpenGEODE on any Linux, FreeBSD, Mac, or Windows machine, using the standard Python packaging system (pip)

$ pip install opengeode

If you are not familiar with pip, you can find more information on the PyPI webpage: http://pypi.python.org/pypi/opengeode/

How to use it in TASTE

OpenGEODE is already installed in the TASTE Virtual Machine, and fully integrated with the toolset.

In the interface view, select the SDL language for the implementation of the blocks you want to model using OpenGEODE. Then generate your function skeletons:

$ taste-generate-skeletons

This command has the effect of creating an empty SDL model that already contains signal and procedure declarations.

The model is made of two files: "system_structure.pr" (fixed name, read-only) and "functionName.pr" (your function name, as specified in the TASTE interface view). The reason for separating the model in two files is that it allows changes of interfaces in the TASTE model without affecting the state machine you are editing. If you need to re-generate the function skeleton, you will not loose your work or the graphical formatting of your diagram.

Run opengeode and open BOTH FILES (otherwise you will not have access to the data types and signals). You can open it from the command line:

$ opengeode system_structure.pr functionName.pr

You can regularly check using F7 (or the top-level menu). When you are done editing your model, go to the top-level menu and select Generate Ada code. Then quit the application, and build your system normally.

$ ./build-script.sh

Example and screenshots

A complete TASTE system including an OpenGEODE subsystem is provided in the following directory of the TASTE VM:

tool-src/misc/opengeode/examples/taste-demo

This example shows most of the features currently supported by the tool

  • Overview of the editor
Opengeode

The editor is meant to be simple and straightforward to use.

Based on the example you can find in the VM here are the main capabilities of the tool:

  • Support of composite states and FOR loops
Nested states
  • Adavanced support for ASN.1 constructs to work with data
Support for ASN.1 constructs
  • State with various constructs, loops, printf, hyperlinks
A State definition

Credits

Designed and implemented by Maxime Perrotin (European Space Agency)

The ASN.1 Compiler was developed by George Mamais (Neuropublic) with F# and ANTLR

The background pattern was downloaded from www.subtlepatterns.com

The tool is developed using Python, PySide (Qt bindings for Python), and ANTLR (parser)

Special thanks and greetings to Thanassis Tsiodras

Licence

Licence for OpenGEODE is LGPL

Personal tools
Namespaces
Variants
Actions
Navigation
Toolbox