| Volume pwrb | |
| Attributes: Runtime | Development | System | Template | Detail C Binding: Struct | Class | Code  ClassTree | INDEX NO INDEX |
Class CycleSup
|
||
|---|---|---|
| Modified | 08-MAR-2026 11:05:32.00 | |
| Code | rt_csup.c | |
Object used for supervision of a plc thread. A max delay time is specified and aswell the action that should be taken when a delay occurs. Several objects with different action can be used for one plc thread. Delay is detected by every thread and rt_emon. If thread itself is hanging in execution, delay could anyway be detected by another thread or by rt_emon. This depends of course on at what priorities the processes are running.
| RtBody attributes pwr_sClass_CycleSup | |||
|---|---|---|---|
| Float32 | MaxDelay | Maximum delay time [s]. When a delay longer than this occurs take specified action. | |
| DeltaTime | DelayLimit | Same as 'MaxDelay' but represented as a delta-time. | |
| SupDelayActionEnum | DelayAction | Action to be taken if a delay occurs. 1 = Alarm, 2 = Stall. | |
| UInt32 | DelayCount | Number of delays that has occured. | |
| UInt32 | DetectCount | Number of cycles the CycleSup-object has been monitored by rt_emon | |
| UInt32 | CycleCount | Number of cycles for plc thread. | |
| DeltaTime | NextLimit | Next time limit for a delay to occur. | |
| Time | LastDelay | Time for the last delay that occured. | |
| Time | DelayedTime | Time when the first delay occured. | |
| Boolean | Delayed | Delay detected by plc thread itself. Reseted by rt_emon when it detects it. | |
| Boolean | DelayNoted | rt-emon has detected a delay. Reset when thread running timely again. | |
| Time | TimelyTime | Time when thread started running timely the last time. | |
| Boolean | Timely | Thread is running timely (no delay). | |
| Boolean | Control | Specifies whether to enable or disable the supervision. Note that blocking is done when Control is FALSE. The input signal can be inverted. FALSE disables the supervision and TRUE or open input enables the supervision. |
|
| Boolean | Action | Specifies the status of supervised quantity. FALSE means normal state and TRUE means alarm state. The output signal can for instance be used to activate an action sequence at alarm state. |
|
| Boolean | Acked | Specifies if the alarm state has been acknowledged or not. FALSE means that unacknowledged alarm exists. The output is set TRUE after booting and when the alarm state has been acknowledged. |
|
| Boolean | Blocked | Specifies whether to enable or disable the blocking. No messages from the supervision object will be sent away as long as the object is blocked. The blocking does not influence on the 'act' output of the object. FALSE disables the the blocking and TRUE enables the blocking. When a supervisory object in alarm position is blocked current messages will be cancelled. Blocking /deblocking is done by means of the 'Alarm Blocking Window' in the operator environment. |
|
| String104 | Description | Optional text to describe the object. | |
| Boolean | DetectOn | Specifies whether to enable or disable the action, which at alarm state implies DetectText to be sent or not. FALSE means that no message will be sent at alarm state; TRUE means that DetectText is sent at alarm state. |
|
| String80 | DetectText | Alarm message. Optional text which will be written out at alarm state if DetectOn is TRUE. |
|
| String80 | ReturnText | Return message. Text which will be written in the event list at return to normal state. |
|
| EventTypeEnum | EventType | Specifies the type of the message (=DetectText ) which will be sent at alarm state. ALARM -- 64 The message always requires an acknowledgement and sent to the alarm INFO -- 32 If the message requires acknowledgement is it sent to the info part of the alarm window and the event list, otherwise only |
|
| EventPrioEnum | EventPriority | Priorities concerning alarm messages. -- 67 A-alarm; highest priority. (=43Hex) -- 66 B-alarm (= 42Hex) -- 65 C-alarm (= 41Hex) -- 64 D-alarm ; lowest priority. (=40Hex) |
|
| EventFlagsMask | EventFlags | Bit map. A flag combination may be attached to the message: 1 = If this flag exists the return message ReturnText will be sent to the event lists of 2 = If this flag exists the acknowledgement message will be sent to the event lists of the out 4 = If the out unit has a peep-function this will be activated when the message is received. 8 = The message is sent to every out unit 16 = If the message is of the type INFO it will be placed in the event list. If this flag exists the message is also placed in the INFO square of the alarm window where acknowledgement is to |
|
| AttrRef | Sound | Reference to a sound object, that defines the sound at the operator place when the alarm is active. If no sound object is supplied, an ordinary beep is used. The sound object should be of class Sound or SoundSequence |
|
| Text256 | MoreText | Optional text supplying more information about the event. The more text can for example contain actions to be made when an alarm is detected. |
|
| String40 | Recipient | Recipient for epost and mms alarms. The recipient is a user defined in the user database in the current system group. Recipient can also be a list of users separated by comma, eg 'dennis, jimmy'. Also symbols defined in the Symbol table in the PostConfig object can be used. Symbols should be referenced with a $ sign before the symbol name, eg '$on_duty'. The users should be defined in the current system group or in a subgroup to this, If a subgroup is used, the subgroup should be specified in the recipient name, eg 'sms.dennis'. |
|
| AttrRef | Attribute | Attribute is filled in by the user if the input named IN is left open. If the input is connected the names are filled in by the PROVIEW/R system at compilation. |
|
| UInt32 | AlarmStatus | Status value. Bit map containing 16 bits where the 8 least significant bits denote the state and the 8 most significant bits the priority. The state is a combination of: -- 0 Normal state -- 1 Alarm state -- 2 Unacknowledged alarm The priority is one of the priorities EventPriority. The following status can exist: EventPriority + 1 => Priority + alarm state EventPriority + 3 => Priority + unacknowledged alarm and alarm state |
|
| Boolean | AlarmCheck | Used internal at the event detection. | |
| Boolean | DetectCheck | Specifies if an alarm state will be detected or not. FALSE means that an alarm state will not be detected; TRUE means that an alarm state will be detected. |
|
| Boolean | DetectSend | Specifies if the message has already been sent to the out units (or more precisely the message handler) or not. TRUE means that the message has been sent. |
|
| Time | DetectTime | Date and time when alarm state was detected. | |
| Boolean | ReturnCheck | Specifies if the object has returned to normal state or not. TRUE means that the object has returned to normal state. |
|
| Boolean | ReturnSend | Specifies if the return message, ReturnText, has been sent to the out units or not. TRUE means that the return message has been sent. |
|
| Time | ReturnTime | Date and time when the last return to normal was detected. |
|
| Time | AckTime | Date and time when the last acknowledgement of normal state was detected. |
|
| Objid | AckOutunit | Identity of the out unit (operator) which made an acknowledgement. |
|
| Boolean | TimerFlag | Indicates an active timer. | |
| Pointer to Boolean | TimerNext | Points to the next element in the timer queue. | |
| UInt32 | TimerCount | Number of remaining ticks. | |
| Pointer to Boolean | TimerDO | Points to a Do or Dv object or, if these are not used, to TimerDoDum. After a time of TimerTime the signal specified by TimerDo is cleared. |
|
| Float32 | TimerTime | Delay in seconds. Specifies when, since an alarm state has occurred, the message will be sent. If the alarm state disappears before the time has elapsed no message is generated. TimerTime >= the executing period of the PLC program. |
|
| Boolean | TimerDODum | Dummy. If TimerDoDum does not point to a Do or Dv object it points to this attribute. |
|
| Objid | TimerObjDId | Identity of this object is set at load file creation. Used by the run time system. |
|
| Int32 | TimerAcc | The operator's authorities to change TimerTime. Not implemented. 0 -- Changes not allowed. !=0 -- Changes allowed. |
|
| Float32 | TimerMin | Specifies a valid interval at changes made by the operator on TimerTime. TimerMin <= TimerTime <= TimerMax |
|
| Float32 | TimerMax | ||
| Template Object | |
|---|---|
| Control | 1 |
| DelayAction | 1 |
| EventType | 64 |
| EventPriority | 67 |
| EventFlags | 7 |
| DetectOn | 1 |
| MaxDelay Attribute | ||
|---|---|---|
| Class | Attribute | |
| Type | Float32 | |
| Flags | ||
| Body | RtBody | |
Maximum delay time [s]. When a delay longer than this occurs take specified action.
| DelayLimit Attribute | ||
|---|---|---|
| Class | Attribute | |
| Type | DeltaTime | |
| Flags | STATE | NOEDIT | INVISIBLE | |
| Body | RtBody | |
Same as 'MaxDelay' but represented as a delta-time.
| DelayAction Attribute | ||
|---|---|---|
| Class | Attribute | |
| Type | SupDelayActionEnum | |
| Flags | ||
| Body | RtBody | |
Action to be taken if a delay occurs. 1 = Alarm, 2 = Stall.
| DelayCount Attribute | ||
|---|---|---|
| Class | Attribute | |
| Type | UInt32 | |
| Flags | STATE | NOEDIT | INVISIBLE | |
| Body | RtBody | |
Number of delays that has occured.
| DetectCount Attribute | ||
|---|---|---|
| Class | Attribute | |
| Type | UInt32 | |
| Flags | STATE | NOEDIT | INVISIBLE | |
| Body | RtBody | |
Number of cycles the CycleSup-object has been monitored by rt_emon
| CycleCount Attribute | ||
|---|---|---|
| Class | Attribute | |
| Type | UInt32 | |
| Flags | STATE | NOEDIT | INVISIBLE | |
| Body | RtBody | |
Number of cycles for plc thread.
| NextLimit Attribute | ||
|---|---|---|
| Class | Attribute | |
| Type | DeltaTime | |
| Flags | STATE | NOEDIT | INVISIBLE | |
| Body | RtBody | |
Next time limit for a delay to occur.
| LastDelay Attribute | ||
|---|---|---|
| Class | Attribute | |
| Type | Time | |
| Flags | STATE | NOEDIT | INVISIBLE | |
| Body | RtBody | |
Time for the last delay that occured.
| DelayedTime Attribute | ||
|---|---|---|
| Class | Attribute | |
| Type | Time | |
| Flags | STATE | NOEDIT | INVISIBLE | |
| Body | RtBody | |
Time when the first delay occured.
| Delayed Attribute | ||
|---|---|---|
| Class | Attribute | |
| Type | Boolean | |
| Flags | STATE | NOEDIT | INVISIBLE | |
| Body | RtBody | |
Delay detected by plc thread itself. Reseted by rt_emon when it detects it.
| DelayNoted Attribute | ||
|---|---|---|
| Class | Attribute | |
| Type | Boolean | |
| Flags | STATE | NOEDIT | INVISIBLE | |
| Body | RtBody | |
rt-emon has detected a delay. Reset when thread running timely again.
| TimelyTime Attribute | ||
|---|---|---|
| Class | Attribute | |
| Type | Time | |
| Flags | STATE | NOEDIT | INVISIBLE | |
| Body | RtBody | |
Time when thread started running timely the last time.
| Timely Attribute | ||
|---|---|---|
| Class | Attribute | |
| Type | Boolean | |
| Flags | STATE | NOEDIT | INVISIBLE | |
| Body | RtBody | |
Thread is running timely (no delay).
| Control Input | ||
|---|---|---|
| Class | Input | |
| Type | Boolean | |
| Flags | STATE | NOEDIT | INVISIBLE | |
| Body | RtBody | |
Specifies whether to enable or disable the supervision. Note that blocking is done when Control is FALSE. The input signal can be inverted. FALSE disables the supervision and TRUE or open input enables the supervision.
| Action Attribute | ||
|---|---|---|
| Class | Attribute | |
| Type | Boolean | |
| Flags | STATE | NOEDIT | INVISIBLE | |
| Body | RtBody | |
Specifies the status of supervised quantity. FALSE means normal state and TRUE means alarm state. The output signal can for instance be used to activate an action sequence at alarm state.
| Acked Attribute | ||
|---|---|---|
| Class | Attribute | |
| Type | Boolean | |
| Flags | STATE | NOEDIT | INVISIBLE | |
| Body | RtBody | |
Specifies if the alarm state has been acknowledged or not. FALSE means that unacknowledged alarm exists. The output is set TRUE after booting and when the alarm state has been acknowledged.
| Blocked Attribute | ||
|---|---|---|
| Class | Attribute | |
| Type | Boolean | |
| Flags | STATE | NOEDIT | INVISIBLE | |
| Body | RtBody | |
Specifies whether to enable or disable the blocking. No messages from the supervision object will be sent away as long as the object is blocked. The blocking does not influence on the 'act' output of the object. FALSE disables the the blocking and TRUE enables the blocking. When a supervisory object in alarm position is blocked current messages will be cancelled. Blocking /deblocking is done by means of the 'Alarm Blocking Window' in the operator environment.
| Description Attribute | ||
|---|---|---|
| Class | Attribute | |
| Type | String104 | |
| Flags | ||
| Body | RtBody | |
Optional text to describe the object.
| DetectOn Attribute | ||
|---|---|---|
| Class | Attribute | |
| Type | Boolean | |
| Flags | NOEDIT | INVISIBLE | |
| Body | RtBody | |
Specifies whether to enable or disable the action, which at alarm state implies DetectText to be sent or not. FALSE means that no message will be sent at alarm state; TRUE means that DetectText is sent at alarm state.
| DetectText Attribute | ||
|---|---|---|
| Class | Attribute | |
| Type | String80 | |
| Flags | ||
| Body | RtBody | |
Alarm message. Optional text which will be written out at alarm state if DetectOn is TRUE.
| ReturnText Attribute | ||
|---|---|---|
| Class | Attribute | |
| Type | String80 | |
| Flags | ||
| Body | RtBody | |
Return message. Text which will be written in the event list at return to normal state.
| EventType Attribute | ||
|---|---|---|
| Class | Attribute | |
| Type | EventTypeEnum | |
| Flags | ||
| Body | RtBody | |
Specifies the type of the message (=DetectText ) which
will be sent at alarm state.
ALARM -- 64 The message always requires an
acknowledgement and sent to the alarm
INFO -- 32 If the message requires acknowledgement is
it sent to the info part of the alarm
window and the event list, otherwise only
| EventPriority Attribute | ||
|---|---|---|
| Class | Attribute | |
| Type | EventPrioEnum | |
| Flags | ||
| Body | RtBody | |
Priorities concerning alarm messages. -- 67 A-alarm; highest priority. (=43Hex) -- 66 B-alarm (= 42Hex) -- 65 C-alarm (= 41Hex) -- 64 D-alarm ; lowest priority. (=40Hex)
| EventFlags Attribute | ||
|---|---|---|
| Class | Attribute | |
| Type | EventFlagsMask | |
| Flags | ||
| Body | RtBody | |
Bit map. A flag combination may be attached to the
message:
1 = If this flag exists the return message
ReturnText will be sent to the event lists of
2 = If this flag exists the acknowledgement message
will be sent to the event lists of the out
4 = If the out unit has a peep-function this will
be activated when the message is received.
8 = The message is sent to every out unit
16 = If the message is of the type INFO it will be
placed in the event list. If this flag exists
the message is also placed in the INFO square
of the alarm window where acknowledgement is to
| Sound Attribute | ||
|---|---|---|
| Class | Attribute | |
| Type | AttrRef | |
| Flags | ||
| Body | RtBody | |
Reference to a sound object, that defines the sound at the operator place when the alarm is active. If no sound object is supplied, an ordinary beep is used. The sound object should be of class Sound or SoundSequence
| MoreText Attribute | ||
|---|---|---|
| Class | Attribute | |
| Type | Text256 | |
| Flags | ||
| Body | RtBody | |
Optional text supplying more information about the event. The more text can for example contain actions to be made when an alarm is detected.
| Recipient Attribute | ||
|---|---|---|
| Class | Attribute | |
| Type | String40 | |
| Flags | ||
| Body | RtBody | |
Recipient for epost and mms alarms. The recipient is a user defined in the user database in the current system group. Recipient can also be a list of users separated by comma, eg 'dennis, jimmy'. Also symbols defined in the Symbol table in the PostConfig object can be used. Symbols should be referenced with a $ sign before the symbol name, eg '$on_duty'. The users should be defined in the current system group or in a subgroup to this, If a subgroup is used, the subgroup should be specified in the recipient name, eg 'sms.dennis'.
| Attribute Attribute | ||
|---|---|---|
| Class | Attribute | |
| Type | AttrRef | |
| Flags | ||
| Body | RtBody | |
Attribute is filled in by the user if the input named IN is left open. If the input is connected the names are filled in by the PROVIEW/R system at compilation.
| AlarmStatus Attribute | ||
|---|---|---|
| Class | Attribute | |
| Type | UInt32 | |
| Flags | STATE | INVISIBLE | |
| Body | RtBody | |
Status value. Bit map containing 16 bits where the 8
least significant bits denote the state and the 8 most
significant bits the priority.
The state is a combination of:
-- 0 Normal state
-- 1 Alarm state
-- 2 Unacknowledged alarm
The priority is one of the priorities EventPriority.
The following status can exist:
EventPriority + 1 => Priority + alarm state
EventPriority + 3 => Priority + unacknowledged alarm
and alarm state
| AlarmCheck Attribute | ||
|---|---|---|
| Class | Attribute | |
| Type | Boolean | |
| Flags | STATE | INVISIBLE | |
| Body | RtBody | |
Used internal at the event detection.
| DetectCheck Attribute | ||
|---|---|---|
| Class | Attribute | |
| Type | Boolean | |
| Flags | STATE | INVISIBLE | |
| Body | RtBody | |
Specifies if an alarm state will be detected or not. FALSE means that an alarm state will not be detected; TRUE means that an alarm state will be detected.
| DetectSend Attribute | ||
|---|---|---|
| Class | Attribute | |
| Type | Boolean | |
| Flags | STATE | INVISIBLE | |
| Body | RtBody | |
Specifies if the message has already been sent to the out units (or more precisely the message handler) or not. TRUE means that the message has been sent.
| DetectTime Attribute | ||
|---|---|---|
| Class | Attribute | |
| Type | Time | |
| Flags | STATE | INVISIBLE | |
| Body | RtBody | |
Date and time when alarm state was detected.
| ReturnCheck Attribute | ||
|---|---|---|
| Class | Attribute | |
| Type | Boolean | |
| Flags | STATE | INVISIBLE | |
| Body | RtBody | |
Specifies if the object has returned to normal state or not. TRUE means that the object has returned to normal state.
| ReturnSend Attribute | ||
|---|---|---|
| Class | Attribute | |
| Type | Boolean | |
| Flags | STATE | INVISIBLE | |
| Body | RtBody | |
Specifies if the return message, ReturnText, has been sent to the out units or not. TRUE means that the return message has been sent.
| ReturnTime Attribute | ||
|---|---|---|
| Class | Attribute | |
| Type | Time | |
| Flags | STATE | INVISIBLE | |
| Body | RtBody | |
Date and time when the last return to normal was detected.
| AckTime Attribute | ||
|---|---|---|
| Class | Attribute | |
| Type | Time | |
| Flags | STATE | INVISIBLE | |
| Body | RtBody | |
Date and time when the last acknowledgement of normal state was detected.
| AckOutunit Attribute | ||
|---|---|---|
| Class | Attribute | |
| Type | Objid | |
| Flags | STATE | INVISIBLE | |
| Body | RtBody | |
Identity of the out unit (operator) which made an acknowledgement.
| TimerFlag Attribute | ||
|---|---|---|
| Class | Attribute | |
| Type | Boolean | |
| Flags | STATE | INVISIBLE | |
| Body | RtBody | |
Indicates an active timer.
| TimerNext Attribute | ||
|---|---|---|
| Class | Attribute | |
| Type | Pointer to Boolean | |
| Flags | POINTER | STATE | INVISIBLE | PRIVATE | |
| Body | RtBody | |
Points to the next element in the timer queue.
| TimerCount Attribute | ||
|---|---|---|
| Class | Attribute | |
| Type | UInt32 | |
| Flags | STATE | INVISIBLE | |
| Body | RtBody | |
Number of remaining ticks.
| TimerDO Attribute | ||
|---|---|---|
| Class | Attribute | |
| Type | Pointer to Boolean | |
| Flags | POINTER | STATE | INVISIBLE | PRIVATE | |
| Body | RtBody | |
Points to a Do or Dv object or, if these are not used, to TimerDoDum. After a time of TimerTime the signal specified by TimerDo is cleared.
| TimerTime Attribute | ||
|---|---|---|
| Class | Attribute | |
| Type | Float32 | |
| Flags | ||
| Body | RtBody | |
Delay in seconds. Specifies when, since an alarm state has occurred, the message will be sent. If the alarm state disappears before the time has elapsed no message is generated. TimerTime >= the executing period of the PLC program.
| TimerDODum Attribute | ||
|---|---|---|
| Class | Attribute | |
| Type | Boolean | |
| Flags | STATE | INVISIBLE | |
| Body | RtBody | |
Dummy. If TimerDoDum does not point to a Do or Dv object it points to this attribute.
| TimerObjDId Attribute | ||
|---|---|---|
| Class | Attribute | |
| Type | Objid | |
| Flags | INVISIBLE | |
| Body | RtBody | |
Identity of this object is set at load file creation. Used by the run time system.
| TimerAcc Attribute | ||
|---|---|---|
| Class | Attribute | |
| Type | Int32 | |
| Flags | ||
| Body | RtBody | |
The operator's authorities to change TimerTime. Not implemented. 0 -- Changes not allowed. !=0 -- Changes allowed.
| TimerMin Attribute | ||
|---|---|---|
| Class | Attribute | |
| Type | Float32 | |
| Flags | ||
| Body | RtBody | |
Specifies a valid interval at changes made by the operator on TimerTime. TimerMin <= TimerTime <= TimerMax
| TimerMax Attribute | ||
|---|---|---|
| Class | Attribute | |
| Type | Float32 | |
| Flags | ||
| Body | RtBody | |