|
|
||||||
|
Operands and results of libFAUDES operations are fetched from or stored in DESTool Variables. You can access DESTool variables via the variables tab from the project browser. To introduce a new variable, use New Variable from the File menu, or press Shift+Return within the variable list.
Each individual variable is identified by a unique name and has the following configuration properties attached.
Each variable is of a specific faudes-type, e.g. "System" or "Alphabet"; available types are documented in the libFAUDES user-reference; when you change the type of a variable, DESTool will try to convert it's value to the new type.
Optionally, a variable can be held within the project file ("Persistent"); this is most convenient, however, may not be applicable if the project consists of a large number of large automata.
Optionally, a variable can be linked to an external file; when you choose this option, the value can be loaded from and saved to the external file via the File menu; since DESTool keeps all files related to one project in the same folder, this option is only available once the project has been saved and, thus, it's folder is known.
Optionally, a variable can have a visual representation; this option is only applicable to reasonably small automata.
Optionally, a variable can belong to the Supervisor- or Plant-Model; this attribute is used to configure which generators are to be simulated; see also the simulator's page
The default configuration is Persistent + Visual Representation. To display the value of a variable, use the context-menu in the variable list.
Windows that represent variables of type System are vertically split in three regions, one for a graphical representation, one for list representation, and one to display attributes of events, states and transitions. You may toggle between the different representations via the Windows menu.
Various editing facilities are provided via context-menus and should be fairly intuitive. We give some hints on less obvious aspects of the user interface.
Insertion. The context-menu can be used to insert items, i.e., events, states, or transitions. As a shortcut, the list representation uses Shift+Return to insert a new line, and the graph representation uses Shift-Mouse-Click to insert a state or a transition.
Attributes. Attributes of the currently selected item are editable in the properties region. They can also be accessed via the item's context-menu. When multiple items are selected, their attributes will be set uniformly.
Graph Representation. The Shift key toggles insert- and select-mode. When in insert-mode, you may insert states or transitions by mouse-click. For a transition, first click into the starting state and then in the final state. You may click inbetween to direct the transitions shape. To edit the shape of an existing item, select it and drag the control points. When in insert-mode, you may also insert or delete control points of the selected transitions. Rendering of a transition is again controlled by it's context-menu, options include splines or polygons. The context-menu also allows you to copy the shape of a state or a transition.
Alphabets have a list representation only. Attributes of events can be accessed via the context-menu or via the properties section.
DESTool provides an error console to report all sorts warnings and errors. You can open the console via the Windows menu. The console runs a luafaudes-interpreter and provides access to DESTool variables in the Lua-field workspace. Example:
luafaudes console > mach=workspace.Machine() -- have a copy of the variable "Machine" in mach > print(mach:IsTrim()) -- test "Machine" to be trim FAUDES_LUAPRINT: false > mach:Trim() -- make the copy of "Machine" trim > workspace.Machine(mach) -- write result back to DESTool
Note: in the current implementation, you can only access variables with names that are valid Lua identifiers.
For more information on luafaudes, see the online documentation.
libFAUDES 2.32b --- 2024.03.08 --- with "synthesis-observer-diagnosis-iosystem-hiosys-multitasking-coordinationcontrol-timed-iodevice-simulator-luabindings"