Avatar

Please consider registering
guest

sp_LogInOut Log In sp_Registration Register

Register | Lost password?
Advanced Search

— Forum Scope —




— Match —





— Forum Options —





Minimum search word length is 3 characters - maximum search word length is 84 characters

sp_Feed Topic RSS sp_TopicIcon
How to override parent type variables/properties/objects using the API
February 13, 2018
15:31, EET
Avatar
pierre
Member
Members
Forum Posts: 4
Member Since:
August 18, 2017
sp_UserOfflineSmall Offline

Hi,

I am trying to make a subtype of a custome type:
Type
– someproperty
-SubType
– sameProperty overriten

In UaExpert, it is possible to tick a case to override parent’s variables. Is this just a convenience or part of OPC UA? Do you have similar mechanism in your stack? If not, should I just create a child node with the same name?

Thanks for your help

February 13, 2018
17:02, EET
Avatar
Bjarne Boström
Moderator
Moderators
Forum Posts: 983
Member Since:
April 3, 2012
sp_UserOfflineSmall Offline

Hi,

I’m not exactly sure what is the question here. If you can clarify the exact end goal you are trying to archive with the SDK, it might be easier to answer.

I assume you are meaning UaModeler instead of UaExpert, since it fits more to the description you gave.

In general the UaModeler is used to create information models, therefore the question that does the SDK have similar function is not valid as the two do different things.

This mechanism is a part of OPC UA, please see the specification (v.1.03, Part 4 section 6.3 and more specifically section 6.3.3.3 Overriding InstanceDeclarations, note that there are some limitations on what exactly you can override and how, e.g. DataTypes can be only subtypes etc. it is quite similar as object oriented programming languages)

The information model is exported as NodeSet2 XML format from the UaModeler and used as input for our code generator, which creates specific overloads for the type nodes. Those types are then registered in the SDK code and the model XML is loaded. Then you can use NodeManagerUaNode’s createInstance methods to create instances of these types.

– Bjarne

P.S. in case you are doing the types by hand, you need to create the node with the same BrowseName (both namespace index and name parts) as in the supertype. Generally the UaModeler->codegen->register types->load model->NodeManagerUaNode.createInstance/NodeBuilder is recommended if possible.

Forum Timezone: Europe/Helsinki

Most Users Ever Online: 518

Currently Online:
10 Guest(s)

Currently Browsing this Page:
1 Guest(s)

Top Posters:

hbrackel: 135

pramanj: 86

Francesco Zambon: 81

rocket science: 77

ibrahim: 75

Sabari: 62

kapsl: 57

gjevremovic: 49

Xavier: 43

fred: 41

Member Stats:

Guest Posters: 0

Members: 680

Moderators: 16

Admins: 1

Forum Stats:

Groups: 3

Forums: 15

Topics: 1467

Posts: 6259

Newest Members:

DonaldPooma, fidelduke938316, Jan-Pfizer, DavidROunc, fen.pang@woodside.com, aytule, rashadbrownrigg, christi10l, ahamad1, Flores Frederick

Moderators: Jouni Aro: 1009, Otso Palonen: 32, Tuomas Hiltunen: 5, Pyry: 1, Petri: 0, Bjarne Boström: 983, Heikki Tahvanainen: 402, Jukka Asikainen: 1, moldzh08: 0, Jimmy Ni: 26, Teppo Uimonen: 21, Markus Johansson: 42, Niklas Nurminen: 0, Matti Siponen: 321, Lusetti: 0, Ari-Pekka Soikkeli: 5

Administrators: admin: 1