Parameter specfication
The generation of a reachability graph or
a simulator requires the specification
of values for input parameters of commands and signals, if any.
Values for these parameters have to be provided through a .params file.
-
Next to a
INTERFACE_NAME.interfacefile, create a file calledINTERFACE_NAME.params. -
Insert, as the first line of the file, an import of the interface (i.e.,
import INTERFACE_NAME.interface). -
Open the content assist (ctrl + space) and select "Autocomplete missing triggers".
-
Fill in the desired parameters and the
.paramsfile is complete.
An example of a .params file:
// Imports
import "Camera.interface"
// The interface we want to provide parameters for
interface: Camera
// The trigger (command or signal)
trigger: SetZoom
// The state we are providing parameters for
state: PoweredOn
// The provided parameters, note that multiple parameters sets can be provided
params: ( 3, 9 )
params: ( 11, 5 )
// Next to SetZoom in the PoweredOn state, we also provided parameters for SetZoom in the PoweredOff state.
state: PoweredOff
params: ( 21, 5 )
trigger: GetCapacity
state: PoweredOn
params: ( CapacityType::Total )
params: ( CapacityType::Remaining )