TcEvent
TwinCAT EventLogger vs. TwinCAT 3 EventLogger The TwinCAT EventLogger was replaced by the successor TwinCAT 3 EventLogger. The older TwinCAT EventLogger is supported by TwinCAT 3 up to version 3.1.4024. Newer TwinCAT versions (>= 3.1.4026.0) only support the newer TwinCAT 3 EventLogger. PLC function blocks for this can be found in the PLC library Tc3_EventLogger. |
TYPE TcEvent
STRUCT
Class : UDINT;
Prio : UDINT;
Id : UDINT;
bQuitRequired : BOOL;
DataFormatStrAddress : PVOID;
UserFlags : DWORD;
Flags : DWORD;
StreamType : UDINT;
SourceString : STRING[15]; (* TCEVENT_SRCNAMESIZE *)
SourceId : UDINT;
ProgId : STRING[31]; (* TCEVENT_FMTPRGSIZE *)
END_STRUCT
END_TYPE
Name | Type | Description |
---|---|---|
Class | UDINT | Event class, get value from enum E_TcEventClass. |
Prio | UDINT | Priority of the event within a class, freely selectable number (1..MaxUDINT) |
Id | UDINT | Id of the event, used for unique identification in the EventLogger. |
bQuitRequired | BOOL | Flag for switching the acknowledgement requirement on and off (TRUE → acknowledgement required) |
DataFormatStrAddress | PVOID | Address of a string, string contains formatting instructions (e.g. %d%f formats an integer and a real (float) value). |
UserFlags | DWORD | 32-bit number for free disposal |
Flags | DWORD | 32-bit number identifying the event, the meaning of the individual bits are declared in the global variables of the library. |
StreamType | UDINT | Type of the event, get value from the enum E_TcEventStreamType. |
SourceString | STRING | String with the source name (max. 15 characters) |
SourceId | UDINT | Source-ID |
ProgId | STRING | String (Prog-Id) with the name of the formatter (max. 31 characters). Default: 'TcEventLogger.TcLogFormatter' or 'TcEventFormatter.TcXmlFormatter' |
Requirements
Development environment | Target platform | PLC libraries to be integrated (category group) |
---|---|---|
TwinCAT v3.1.0 | PC or CX (x86, x64, ARM) | Tc2_System (system) |