Hi,
after updating from 1.6.5 to 1.7.7 my software is unable to get the ConditionID in UaSubscriptionCallback::newEvents() from the eventFieldList.
Up to 1.6.5 I was able to get it from the first entry in EventFields: eventFieldList[i].EventFields[0], but now this entry is always empty.
UaExpert is still able to show the Condition ID, so it must still be there.
Can you tell me how I can access the Condition ID in UaSubscriptionCallback::newEvents()?
The condition I'm sending, is a OpcUa::AcknowledgeableConditionType.
Thanks,
Thomas
Edit: I just tried version 1.7.0 and already in this version I'm not able to get the Condition ID from the eventFieldList.
Condition ID in UaSubscriptionCallback::newEvents()
Moderator: uasdkcpp
-
- Sr. Member
- Posts: 12
- Joined: 02 Mar 2023, 13:41
- Support Team
- Hero Member
- Posts: 3070
- Joined: 18 Mar 2011, 15:09
Re: Condition ID in UaSubscriptionCallback::newEvents()
Hello Thomas,
I assume there's some issue when you create the EventMonitoredItem in the part filling the SelectClause:
Please check the example coming with the SDK (client_cpp_sdk.cpp function -> subscribeAlarms)
I assume there's some issue when you create the EventMonitoredItem in the part filling the SelectClause:
Please check the example coming with the SDK (client_cpp_sdk.cpp function -> subscribeAlarms)
Code: Select all
// Select Condition NodeId
// This is special - the path is empty and the requested Attribute is NodeId
selectElement.setTypeId(UaNodeId(OpcUaId_ConditionType));
selectElement.setAttributeId(OpcUa_Attributes_NodeId);
selectElement.clearBrowsePath();
eventFilter.setSelectClauseElement(14, selectElement, 15);
Best regards
Unified Automation Support Team
Unified Automation Support Team