SMARTUNIFIER Configuration
Information Model
What Information Models are and how to create them is described in the chapter Information Models.
Information Model - OPCUA
Create an Information Model that represents the structure of the data from the OPCUA server that should be used.
To create the Information Model follow the steps described in the user manual.
Information Model - SQL-Database
Create an Information Model that represents the SQL database.
To create the Information Model follow the steps described in the user manual.
Structure needed for the Information Model:
Communication Channel
What Communication Channels are and how to create them is described in the chapter Communication Channels.
Communication Channel - OPCUA Client
Create a new OPCUA Client Communication Channel and choose the OPCUA Information Model just created.
Configure the OPCUA Client Channel by following the steps described in the user manual.
Communication Channel - SQL Database
Create a new SQL Database Communication Channel and choose the Database Information Model just created.
Configure the Database Channel by following the steps described in the user manual.
Select the root node of the Information Model and configure the database access
Select SQLServer as Type
Enter the JDBC Url according to the selected database -
jdbc:sqlserver://192.168.0.72:1433;databaseName=demo;trustServerCertificate=true
Enter the username and the password of the database
Select the Event node in the Information Model and configure the table settings
Enable the checkbox Insert
Enter the name for the Table and for the Schema
Select a Variable and configure the columns (Repeat this step with the rest of the Variables)
Enable the checkbox Assign Database Column
Enter the name for the Column
Mapping
What Mappings are and how to create them is described in the chapter Mappings.
Create a new Mapping by selecting the Infromation Models just created (OPCUA and SQLDatabase).
Create a Rule that handles the assignment of values from the OPCUA Server to the SQL Database.
Enter a meaningful Rule Name
Drag and Drop the Variable of the OPCUA Model into the Trigger field
Note
Several Trigger Types are available. In this example we use a single OPCUA variable. That means the rule is triggered when the value on the OPCUA server is changing.
Drag and Drop the Event of the SQL Database Model into the Actions panel
Assign source to target (Repeat for all variables)
Device Type
What Device Types are and how to create them is described in the chapter Device Types.
Select the Mapping just created
Assign the Communication Channels (OPCUA and SQL Database) to the associated Information Model
Communication Instances
What Communication Instances are and how to create them is described in the chapter Communication Instances.
Select the Device Type just created
Enter a meaningful name for the Instance
Note
Changes of the Communication Channel configurations can be made on this level if necessary.
Deployment
Create a new Local Deployment
Select the Instance just created
Select the Log File Configuration Info (Defines the log level)
Deploy and Start the Instance.
Data is written to the database whenever the value of the variable, that was defined as a trigger, changes.