Numeric Node ID Read from server|OPC UA Standard|Forum|OPC Foundation

Avatar
Search
Forum Scope


Match



Forum Options



Minimum search word length is 3 characters - maximum search word length is 84 characters
Lost password?
sp_Feed sp_PrintTopic sp_TopicIcon
Numeric Node ID Read from server
Avatar
Yashvanth B
Member
Members
Forum Posts: 6
Member Since:
04/19/2020
sp_UserOfflineSmall Offline
1
05/07/2020 - 10:46
sp_Permalink sp_Print

How do I call a method which does have a numerical node identifier type (and not a string type)? 

A very lot of documentation is based on a String-Type like "ns=0;s=Demo.Dynamic.Scalar.Int32", but I do need something like

"ns=0;i=2258".

 

More Information:

Used Language: C++ based OPC UA Client/Server SDK + Pub/Sub Bundle v1.7.2

Node Address: "Root/Objects/Clear capture 1" or "Root/Objects/909"

NamespaceIndex: 0

Identifier Type: Numeric

Identifier: 2258

if it is string 

//nodesToRead[0].NodeId will have the value = "ns=0;s=Demo.Dynamic.Scalar.Int32"

//nodesToRead[0].NodeId will have the value ="ns=0;i=2258"

but when i add this/ replace with the numeric reading is failed 

 

nodesToRead[0].AttributeId = OpcUa_Attributes_Value;
OpcUa_NodeId_CopyTo(&nodes[0], &nodesToRead[0].NodeId);

result = m_pSession->read(serviceSettings, 0, OpcUa_TimestampsToReturn_Both, nodesToRead, values, diagnosticInfos);

 

I would be very happy about any help. 

Forum Timezone: America/Phoenix
Most Users Ever Online: 510
Currently Online:
Guest(s) 13
Currently Browsing this Page:
1 Guest(s)
Top Posters:
Forum Stats:
Groups: 2
Forums: 10
Topics: 1357
Posts: 4606