controllerMethods
Controller."method"
getSpecCounterByControllerId_depricated
Message counter for user defined message types
Usage:
// get counter of a controller
CONTROLLER.getSpecCounter(msgType, uinCounter);
INPUT:
userType : MessageType [1:1]
uinCounter : UINT [1:1]
RETURN TYPE:
VOID
Return:
VOID
Parameters:
userType : MessageType
uinCounter : UINT
this."method"
getCommand
Returns current command of this controller
USAGE:
this.getCommand()
RETURN:
command: COMMAND (UINT)
RETURN TYPE:
UINT
Return:
UINT
getControllerId
Gets controller Id of this controller
USAGE:
this.getControllerId()
RETURN
instance: UINT
RETURN TYPE:
UINT
Return:
UINT
getCycleTimeMs
Returns cycle time of current controller in milli seconds
USAGE:
this.getCycleTimeMs()
RETURN:
cycleTime: UDINT
RETURN TYPE:
UDINT
Return:
UDINT
getCycleTimeS
Returns cycle time of current controller in seconds
USAGE:
this.getCycleTimeS()
RETURN:
cycleTime: REAL
RETURN TYPE:
REAL
Return:
REAL
getCycleTimeUs
Returns cycle time of current controller in micro seconds.
USAGE:
this.getCycleTimeUs()
RETURN:
cycleTime: UDINT
RETURN TYPE:
UDINT
Return:
UDINT
getEnable
Gets exist flag off this controller
USAGE:
this.getEnable()
RETURN
enable: BOOL
RETURN TYPE:
BOOL
Return:
BOOL
getExist
Gets exist flag off this controller
USAGE:
this.getExist()
RETURN
exist: BOOL
RETURN TYPE:
BOOL
Return:
BOOL
getInstanceName
Native name of current controller instance
Usage:
this.getInstanceName(strName);
Parameters
In/Out:
strName : STRING[MAX_CTRL_INSTANCE_NAME_LEN]
INPUT:
name : STRING [1:1]
RETURN TYPE:
BOOL
Return:
BOOL
Parameters:
name : STRING
getInstanceNameAny
Native name of any controller instance by id
Usage:
this.getInstanceName(strName);
Parameters
In/Out:
strName : STRING[MAX_CTRL_INSTANCE_NAME_LEN]
INPUT:
id : UINT [1:1]
name : STRING [1:1]
RETURN TYPE:
BOOL
Return:
BOOL
Parameters:
id : UINT
name : STRING
getInstanceNr
Gets instance nr of this controller instance
USAGE:
this.getInstanceNr()
RETURN
instance: UINT
RETURN TYPE:
UINT
Return:
UINT
getMCommand
Returns current command of this controller
USAGE:
this.getCommand()
RETURN:
command: COMMAND (UINT)
RETURN TYPE:
UINT
Return:
UINT
getMessageCounter
Counter for all possible message types defined in the MessageType model type.
Usage:
// get counter of a controller
this.getMessageCounter(MessageType.error, uinCounter);
INPUT:
messageType : MessageType [1:1]
uinCounter : UINT [1:1]
RETURN TYPE:
VOID
Return:
VOID
Parameters:
messageType : MessageType
uinCounter : UINT
getMode
Gets mode on this controller
USAGE:
this.getMode()
RETURN
mode: MODE (UINT)
RETURN TYPE:
UINT
Return:
UINT
getReset
Gets reset condition of this controller
USAGE:
this.getReset()
RETURN
reset: BOOL
RETURN TYPE:
BOOL
Return:
BOOL
getSimulation
Returns simulation state of current controller
USAGE:
this.getSimulation()
RETURN:
simulation: BOOL
RETURN TYPE:
BOOL
Return:
BOOL
getState
Returns current state of this controller
USAGE:
this.getState()
RETURN:
state: STATE (UINT)
RETURN TYPE:
UINT
Return:
UINT
getStateName
Returns current state name of this controller
USAGE:
this.getStateName()
RETURN:
state: STATE (STRING)
RETURN TYPE:
STRING
Return:
STRING
getTimeInStateMs
Returns the elapsed time in the current state in milliseconds.
USAGE:
this.getTimeInStateMs()
RETURN:
time: [ms] (UDINT)
RETURN TYPE:
UDINT
Return:
UDINT
getTimeInStateS
Returns the elapsed time in the current state in seconds.
USAGE:
this.getTimeInStateS()
RETURN:
time: [s] (REAL)
RETURN TYPE:
REAL
Return:
REAL
getTimeInStateUs
Returns the elapsed time in the current state in microseconds.
USAGE:
this.getTimeInStateUs()
RETURN:
time: [us] (UDINT)
RETURN TYPE:
UDINT
Return:
UDINT
getTopState
Returns current top state of this controller
USAGE:
this.getTopState()
RETURN:
state: STATE (UINT)
RETURN TYPE:
UINT
Return:
UINT
getTopStateName
Returns current top state name of this controller
USAGE:
this.getTopStateName()
RETURN:
state: TOPSTATE (STRING)
RETURN TYPE:
STRING
Return:
STRING
reset
Set reset-flag on current controller. Flag will be reset at the end of the next full cycle.
USAGE:
this.reset()
INPUT
RETURN TYPE:
VOID
Return:
VOID
resetAll
Set reset-flag on current and all underlying controllers. Flag will be reset at the end of the next full cycle.
USAGE:
this.resetAll()
INPUT
RETURN TYPE:
VOID
Return:
VOID
resetCommand
Resets command to this controller
USAGE:
this.resetCommand()
OUTPUT:
Command = 0
RETURN TYPE:
VOID
Return:
VOID
setCommand
Sets automatic command to this controller
USAGE:
this.setCommand(command)
INPUT
command: COMMAND (UINT)
INPUT:
command : UINT [1:1]
RETURN TYPE:
UINT
Return:
UINT
Parameters:
command : UINT
setEnable
Set enable current controller
USAGE:
this.setEnable(enable)
INPUT:
enable: BOOL
INPUT:
boolean : BOOL [1:1]
RETURN TYPE:
VOID
Return:
VOID
Parameters:
boolean : BOOL
setExist
Set enable current controller
USAGE:
this.setEnable(enable)
INPUT:
enable: BOOL
INPUT:
boolean : BOOL [1:1]
RETURN TYPE:
VOID
Return:
VOID
Parameters:
boolean : BOOL
setMCommand
Sets manual command to this controller
USAGE:
this.setMCommand(command)
INPUT
command: COMMAND (UINT)
INPUT:
command [1:1]
RETURN TYPE:
VOID
Return:
VOID
Parameters:
command
setMode
Sets mode on this controller
USAGE:
this.setMode(mode)
INPUT
mode: MODE (USINT)
INPUT:
mode : USINT [1:1]
RETURN TYPE:
VOID
Return:
VOID
Parameters:
mode : USINT
setModeAll
Sets modeAll on this controller
Attention: Method simply operates Interfdace Strkutur and this reacts to the flank change.
USAGE:
this.setModeAll(mode)
INPUT
mode: MODE (USINT)
INPUT:
mode : USINT [1:1]
RETURN TYPE:
VOID
Return:
VOID
Parameters:
mode : USINT
setSimulation
Set simulation state on current controller
USAGE:
this.simulation(simulation)
INPUT:
simulation: BOOL
INPUT:
simulation : BOOL [1:1]
RETURN TYPE:
VOID
Return:
VOID
Parameters:
simulation : BOOL
setSimulationAll
Sets simulation to current and all child controller. The simulation flag is also propagated to all child controllers underneath.
Attention: Method simply operates Interfdace Strkutur and this reacts to the flank change.
USAGE:
this.simulationAll(simulation)
INPUT:
simulation: BOOL
INPUT:
boolean : BOOL [1:1]
RETURN TYPE:
VOID
Return:
VOID
Parameters:
boolean : BOOL