The collection of Attributes associated with any given A&E Event is encapsulated within the ONEVENTSTRUCT. Therefore, the A&E COM UA Proxy populates the Attribute fields within the ONEVENTSTRUCT using corresponding values from UA Event Notifications either directly (e.g., Source, Time, Severity) or indirectly (e.g., OPC COM Event category determined by way of the UA Event type). Table D.5 lists the Attributes currently defined in the ONEVENTSTRUCT in the leftmost column. The rightmost column of Table D.5 indicates how the A&E COM UA proxy defines that Attribute.
Table D.5 – Event category attribute mapping table
A&E ONEVENTSTRUCT “attribute” |
A&E COM UA Proxy Mapping |
The following items are present for all A&E event types |
|
szSource |
UA BaseEventType Property: SourceName |
ftTime |
UA BaseEventType Property: Time |
szMessage |
UA BaseEventType Property: Message |
dwEventType |
See Clause D.3.3 |
dwEventCategory |
See Clause D.3.4 |
dwSeverity |
UA BaseEventType Property: Severity |
dwNumEventAttrs |
Calculated within A&E COM UA Proxy |
pEventAttributes |
Constructed within A&E COM UA Proxy |
The following items are present only for A&E Condition-Related Events |
|
szConditionName |
UA ConditionType Property: ConditionName |
szSubConditionName |
UA ActiveState Property: EffectiveDisplayName |
wChangeMask |
Calculated within Alarms and Events COM UA proxy |
wNewState: OPC_CONDITION_ACTIVE |
A & C AlarmConditionType Property: ActiveState Note that events mapped as non-Condition Events and those that do not derive from AlarmConditionType are set to ACTIVE by default. |
wNewState: OPC_CONDITION_ENABLED |
A & C ConditionType Property: EnabledState Note, Events mapped as non-Condition Events are set to ENABLED (state bit mask = 0x1) by default. |
wNewState: OPC_CONDITION_ACKED |
A & C AcknowledgeableConditionType Property: AckedState Note that A & C Events mapped as non-Condition Events or which do not derive from AcknowledgeableConditionType are set to UNACKNOWLEDGED and AckRequired = False by default. |
wQuality |
A & C ConditionType Property: Quality Note that Events mapped as non-Condition Events are set to OPC_QUALITY_GOOD by default.
In general, the Severity field of the StatusCode is used to map COM status codes OPC_QUALITY_BAD, OPC_QUALITY_GOOD and OPC_QUALITY_UNCERTAIN. When possible, specific status' are mapped directly. These include (UA => COM):
Bad status codes Bad_ConfigurationError => OPC_QUALITY_CONFIG_ERROR Bad_NotConnected => OPC_QUALITY_NOT_CONNECTED Bad_DeviceFailure => OPC_QUALITY_DEVICE_FAILURE Bad_SensorFailure => OPC_QUALITY_SENSOR_FAILURE Bad_NoCommunication => OPC_QUALITY_COMM_FAILURE Bad_OutOfService => OPC_QUALITY_OUT_OF_SERVICE
Uncertain status codes Uncertain_NoCommunicationLastUsableValue => OPC_QUALITY_LAST_USABLE Uncertain_LastUsableValue => OPC_QUALITY_LAST_USABLE Uncertain_SensorNotAccurate => OPC_QUALITY_SENSOR_CAL Uncertain_EngineeringUnitsExceeded => OPC_QUALITY_EGU_EXCEEDED Uncertain_SubNormal => OPC_QUALITY_SUB_NORMAL
Good status codes Good_LocalOverride => OPC_QUALITY_LOCAL_OVERRIDE |
bAckRequired |
If the ACKNOWLEDGED bit (OPC_CONDITION_ACKED) is set then the Ack Required Boolean is set to False, otherwise the Ack Required Boolean is set to True. If the Event is not of type AcknowledgeableConditionType or subtype then the AckRequired Boolean is set to False. |
ftActiveTime |
If the Event is of type AlarmConditionType or subtype and a transition from ActiveState of False to ActiveState to True is being processed then the TransitionTime Property of ActiveState is used. If the Event is not of type AlarmConditionType or subtype then this field is set to current time. Note: Additional logic applies to exclusive limit alarms, This value should be mapped to the LimitState.TransitionTime. |
dwCookie |
Generated by the A&E COM UA Proxy. These unique Condition Event cookies are not associated with any related identifier from the address space of the UA A & C Server. |
The following is used only for A&E tracking events and for A&E condition-relate events which are acknowledgement notifications |
|
szActorID |
|
Vendor specific Attributes – ALL |
|
ACK Comment |
|
AREAS |
All A&E Events are assumed to support the "Areas" Attribute. However, no Attribute or Property of an A & C Event is available which provides this value. Therefore, the A&E COM UA Proxy initializes the value of the Areas Attribute based on the MonitoredItem producing the Event. If the A&E COM Client has applied no area filtering to a Subscription, the corresponding A & C Subscription will contain just one MonitoredItem – that of the UA A & C Server Object. Events forwarded to the A&E COM Client on behalf of this Subscription will carry an Areas Attribute value of empty string. If the A&E COM Client has applied an area filter to a Subscription then the related UA A & C Subscription will contain one or more MonitoredItems for each notifier Node identified by the area string(s). Events forwarded to the A&E COM Client on behalf of such a Subscription will carry an areas Attribute whose value is the relative path to the notifier which produced the Event (i.e., the fully qualified area name). |
Vendor specific Attributes – based on category |
|
SubtypeProperty1 |
All the UA A & C subtype Properties that are not part of the standard set exposed by BaseEventType or ConditionType |
SubtypePropertyn |