User Documentation

Table Of Contents
Program development
System manual
2696790000/02/04.2020
33
State transitions of the Device Service state model are forwarded to all De-
vice Service Items. So they can perform all actions required to execute their
corresponding programs into the requested state.
States
The program must respond to the following status transitions:
Status transition Description
Init DeviceService
The DeviceService is started and imports all
programs created (DeviceService Items)
Init Controller
The program must execute all the necessary
initializations and then change to the Stop
process
Start Applications
The program begins processing and must
change to the Run status
Stop Applications
The program ends processing and must
change to the Stop status
Exit Controller
The program must end all initializations car-
ried out in "Init Controller" and change to the
OS-Ready status.
ExitDeviceService
The DeviceService ends all programs and it-
self
Commands that are forwarded to the programs can be found in chapter "De-
fined State Model".
7.3.2.2 Creating a description file
Each program to be managed by the DeviceService must be created con-
taining the following elements and the functions described above, via a de-
scription file.
Name Description
name
Name of the program (DeviceServiceItem)
variables Global variables of the program
defaultvariables Global variables with default values that can be overwritten
The system provides the following global variables (defaultvariables) with
default values that can be overwritten by the program:
Global variable Default value Description
systemPath
Directory where the control
software is stored.
applPath /opt/kecontrolapplication/
Directory where applications
are created and loaded
workPath /opt/kecontrolapplication/
Directory in which the appli-
cation can store data
autorestart false
Defines whether or not the
system restarts following an
error