Hello @@
The following value " OpcUaId_Server_ServerStatus_CurrentTime" is from souce code.
If I want subscription some node from my UA Server.
How can I set createRequest[0].ItemToMonitor.NodeId.Identifier ?
My node path is something like "2:Objects/2:CTT/2:Methods".
for (i = 0; i < numItemsToCreate; i++)
{
OpcUa_MonitoredItemCreateRequest_Initialize(&createRequest);
createRequest.ItemToMonitor.AttributeId = OpcUa_Attributes_Value;
createRequest.MonitoringMode = OpcUa_MonitoringMode_Reporting;
createRequest.RequestedParameters.SamplingInterval = 1000.0;
createRequest.RequestedParameters.QueueSize = 1;
createRequest.RequestedParameters.DiscardOldest = OpcUa_True;
}
createRequest[0].ItemToMonitor.NodeId.Identifier.Numeric = OpcUaId_Server_ServerStatus_CurrentTime;
MonitoredItem setting question~~
Moderator: uasdkc
- Support Team
- Hero Member
- Posts: 3072
- Joined: 18 Mar 2011, 15:09
Re: MonitoredItem setting question~~
Hello ilike28,
for subscribing, you need to have the NodeId of the node. You can get the NodeId using the TranslateBrowsePathsToNodeIds service or by browsing, or you simply know the NodeId from another source. When you know the NodeId, you need to set the NodeId in the MonitoredItemCreateRequest for subscribing to it.
Best regards
Unified Automation Support Team
for subscribing, you need to have the NodeId of the node. You can get the NodeId using the TranslateBrowsePathsToNodeIds service or by browsing, or you simply know the NodeId from another source. When you know the NodeId, you need to set the NodeId in the MonitoredItemCreateRequest for subscribing to it.
Best regards
Unified Automation Support Team
-
- Full Member
- Posts: 8
- Joined: 17 Jul 2016, 11:23
Re: MonitoredItem setting question~~
Thanks ^____________^!