Automatically created GUIs
Figure 11.1:
Automatic GUIs for system interfaces
|
When applied to real systems, the tools and techniques described in this user manual
distill down to...
- an overall system-level description (in AADL) that includes the system-level interfaces
- an overall message-level description (in ASN.1) that includes all the messages exchanged
between subsystems
This kind of information offers an unexpected bonus: by having access to
both the subsystem interfaces and the ASN.1 types they are expecting, a code
generator would be able to automatically create graphical user interfaces
offering interactive access to subsystem interfaces (see Figure 11.1).
This code generator was built and proved to be a very welcome addition to the
toolchain.
Through access to the ASN.1 grammar, the code generator can create code
with the appropriate GUI widgets and code constructs to...
- Create tree-like dialog controls that offer access to interface parameters
- Allow the operator to populate them, while checking for correctness (appropriate
data used for INTEGER/REAL edit controls, validations of ASN.1 constraints, etc)
- Allow the operator to re-use message data, by Saving and Loading them (easily
implemented via the ASN.1 encoders and decoders)
- Allow the operator to invoke the interface at runtime, thus interacting with
a real running system
WxWidgets/C++ was chosen as the code generator's target. WxWidgets is a cross-platform
GUI and tools library for MS Windows, GTK (Linux/FreeBSD/etc) and MacOS. This, in
effect, allows for compilation and execution of the generated GUI code under any
modern operating system.
Invocation of the interfaces depends on some method of communication between the GUI
and the running system. A number of Inter Process Communication mechanisms (IPC) exist for this purpose;
currently, the implementation uses named message queues to transfer data between
the GUI and the running system. For this to work, both of these applications
must be running in the same machine (POSIX message queues can not generally be used for
communication between different machines). Eventually, the more powerful ASSERT VM
technology may be used to allow for these invocations over any of the ASSERT
sanctioned buses (Spacewire, Ethernet, etc).