TraceMgrPacketGetConfig (FUN) ¶ FUNCTION TraceMgrPacketGetConfig : RTS_IEC_RESULT Queries the configuration of a trace packet. InOut: Scope Name Type Comment Return TraceMgrPacketGetConfig RTS_IEC_RESULT Returns the runtime system error code (see CmpErrors.library): ERR_PARAMETER if hPacket is not a valid handle Input hPacket RTS_IEC_HANDLE The trace packet handle Inout pConfiguration TracePacketConfiguration The packet configuration (out)
TraceMgrPacketGetFirst (FUN) ¶ FUNCTION TraceMgrPacketGetFirst : RTS_IEC_HANDLE Returns the first trace packet. This function can be used together with TraceMgrPacketGetNext to iterate through all trace packets. InOut: Scope Name Type Comment Return TraceMgrPacketGetFirst RTS_IEC_HANDLE Returns the runtime system error code (see CmpErrors.library): ERR_NO_OBJECT if there is no trace packet Inout pResult RTS_IEC_RESULT The result code (out)
TraceMgrPacketGetNext (FUN) ¶ FUNCTION TraceMgrPacketGetNext : RTS_IEC_HANDLE Returns the next trace packet. This function can be used together with TraceMgrPacketGetFirst to iterate through all trace packets. InOut: Scope Name Type Comment Return TraceMgrPacketGetNext RTS_IEC_HANDLE Returns the runtime system error code (see CmpErrors.library): ERR_PARAMETER if hPrevPacket is not a valid handle ERR_NO_OBJECT if hPrevPacket is the last trace packet Input hPrevPacket RTS_IEC_HANDLE The packet handle of the current trace packet Inout pResult RTS_IEC_RESULT The result code
TraceMgrPacketGetStartTime (FUN) ¶ FUNCTION TraceMgrPacketGetStartTime : RTS_IEC_RESULT Returns the start time of a trace packet or 0 if trace packet has not been started yet. Note the start time is the time when the packet was started for the first time. InOut: Scope Name Type Comment Return TraceMgrPacketGetStartTime RTS_IEC_RESULT Returns the runtime system error code (see CmpErrors.library): ERR_PARAMETER if hPacket is not a valid handle Input hPacket RTS_IEC_HANDLE The trace packet handle Inout pStartTime SYSTIME The start time (out)
EventIDs (GVL) ¶ Attributes: qualified_only InOut: Scope Name Type Initial Comment Constant CMPID_CmpSupervisor DWORD 16#8F ComponentID to specify for EventOpen EVTPARAMID_CmpSupervisor_StateChanged WORD 16#1 IDs for the event parameter structures EVTVERSION_CmpSupervisor_StateChanged WORD 16#1 EVT_Supervisor_StateChanged DWORD (SHL(UINT_TO_DWORD(EventClass.EVTCLASS_INFO), 16) OR 16#1) <category>Events</category> <description>Event is sent if the state of the supervisor has changed: if number of operations has changed or if at least one failed vital operation is detected </description> <param name=”pEventParam” type=”IN”>EVTPARAM_CmpSupervisor_StateChanged</param>
EventParameter ¶ EVTPARAM_CmpSupervisor_StateChanged (Struct)
EVTPARAM_CmpSupervisor_StateChanged (STRUCT) ¶ TYPE EVTPARAM_CmpSupervisor_StateChanged : STRUCT <category>Event parameter</category> <element name=”nNumOfOperations” type=”IN”>Number of operations that are registered and supervised</element> <element name=”nNumOfFailedOperations” type=”IN”>Number of failed operations. 0=All operations alive</element> <element name=”nNumOfRegisteredOperations” type=”IN”>Number of all registered operations</element> Attributes: qualified_only InOut: Name Type nNumOfOperations UDINT nNumOfFailedOperations UDINT nNumOfRegisteredOperations UDINT
SupervisorEntry (STRUCT) ¶ TYPE SupervisorEntry : STRUCT Single operation/function that is supervised. InOut: Name Type Comment cmpId DWORD ComponentID of the component which operation is supervised ui32OperationID DWORD Unique operation ID pszOperationDescription POINTER TO STRING Description of the operation stLastActiveUs ULINT Timestamp of last activity in [us] stTimeoutUs ULINT Optional timeout limit in [us] flags DWORD See SupervisorFlags for details. Don’t modify the other bits!! bEnable BOOL Is supervised, FALSE=Is not supervised bAlive BOOL TRUE=Alive, FALSE=Dead instance SupervisorInstance Instance identification hSync RTS_IEC_HANDLE handle to synchronize 64Bit timestamp access
SupervisorFlags (GVL) ¶ Supervisor flags Attributes: qualified_only InOut: Scope Name Type Initial Comment Constant RTS_SUPERVISOR_FLAG_WATCHDOG UDINT 16#10000 This is a watchdog (consumer), that uses the supervisor to protect the controller!
SupervisorInstance (STRUCT) ¶ TYPE SupervisorInstance : STRUCT InOut: Name Type Comment hInstance RTS_IEC_HANDLE Handle to the instance idInstance UDINT Id of the instance xIsIECInstance BOOL TRUE=hInstance is an IEC instance, FALSE=hInstance is a runtime handle