-
Notifications
You must be signed in to change notification settings - Fork 45
Template Generator
With this plugin, you can create new logical node type based on NSD files. With the template generator, a user selection at the beginning is just all mandatory data and a user has to actively select data. The template updater in contrast is parsing an existing logical node type and is creating a user selection from the SCL file. As a result, a user can see what data is already selected for a given logical node type. This is not possible to the template generator. On saving the selection, a new logical node type and its sub data structure is created.
This plugin is centered around a UI component called tree-grid
which is able to render a tree structures. This is necessary, because a logical node is a structured variable with different depth, like a tree is.

Actually, the tree grid holds two tree structures.
The first tree structure is a super set displaying you all the choices that the IEC 61850 namespace for a given logical node class has to over. This complete tree is initially being parsed from the NSD files. Which means that initially, the user can only select what is offered in the IEC 61850 namespace. You can extend the super set using the Add Data Object
button (see ...).
The user can select data objects, data attributes or enumeration values, by clicking on it. Selected data is highlighted through the primary color set in your distribution. In the above picture is green. You can deselect by clicking on a selected value. Data that is of the presence condition M
(mandatory) cannot be selected or deselected. The selection tree is at the end transformed into LNodeType
, DOType
, DAType
and EnumType
elements.
Initially, the super tree is parsed from the NSD files and represents the namespace as is standardized in the IEC 61850. There are multiple ways on how the namespace can be extended to cover aspects of a PAC function which is not covered by the IEC 61850 namespace. Among those, adding user defined data objects is probably the most important one. A user can add a data object to all logical node classes so long the data object name is within the pattern restriction and so long the data object structures follows one of the standardized CDCs.
In this plugin you can add a data object clicking on the Add Data Object
button. Such an imported data object is being added to the super set and from there on can be selected by the user to add to SCL file.

This plugin is using hashing techniques for the id
attribute. The hash is depending on the content of the data type element, which comes with two main advantages: 1. A simple compare between two data type by simply comparing the id
of the data type. 2. This allows to prevent code duplication and keep the SCL file small.
NOTE: When you use other plugins to change the content of a data type element without updating the hash you break with this strategy.