Skip to main content

initializers

Use initializers: to give a Variable a value when the gateway starts. Each entry names a Variable by its browse path and gives the value. The gateway stops with an error when the path does not lead to a Variable.

Example​

instances:
- browseName: Plant
typeDefinition: ua:BaseObjectType
organizedBy: /ua:Objects
- browseName: Setpoint
dataType: ua:Double
componentOf: /ua:Objects/own:Plant
initializers:
- variable: /ua:Objects/own:Plant/own:Setpoint
value: 21.5

The value​

initializers: is a list. Each entry is an initializer.

An initializer​

Gives a Variable its first value. It appears in the initializers list of the configuration file or of an instance.

KeyWhat it doesValueRequired
variableThe Variable to set. In the configuration file, write its browse path or an $anchor path. In an instance, write a path from that instance, such as Temperature.textyes
valueThe first value. Write a text, a number, true or false for a simple value, a list for an array, or a map for a structure. When the Variable has sub-properties, put its own value under $value.any valueyes
engineeringUnitsThe unit of measure of the Variable, for example °C. The gateway does not apply it yet and writes a warning.text (a fixed list)
rangeThe minimum and the maximum of the range of the Variable, as two numbers, for example [0, 100]. The gateway does not apply it yet.list of number
descriptionA description of the Variable, in place of the description of its type. The gateway does not apply it yet.text