It's possible to run multiple tools in one OPCUA server. We'll configure three tools resulting in a server that might look something like this.

To prepare to run the combined OPC UA Server, you will need the OPCUAToolRunner.zip add-on package, which contains:

This zip will be used later on in these instructions.

Each process tool will need its own TransSECS host project. Start by copying your tool project, or the default GEMTool project from the installation Projects directory to a work directory. This project work directory should be outside of the installer structure and in a simple directory, such as your User home directory. Make a directory there called TransSECSProjects, or something similar. It is recommended for the best results that the directory path has no spaces in it. Give this copied GEMTool project a unique name, such as Tool1, or GEMToolA, or some other simple name. Do the same for the number of tools you will be running this OPC UA server.

An example directory structure for three tool connection might be:

Extract the OPCUAServerToolRunner.jar from the resources folder in the zip and place it in the resources folder of your TransSECS installation.

Alternatively, you may place this in the resources folder of each of the Tool projects or simply copy it to the OPCUA deployment folder in your projects.

Load the first tool project into the TransSECS Builder. Rename the tool name “GEMTool” so that it matches the project name. For example, rename the tool for first project loaded as GEMToolA to “GEMToolA”. These will be your tool projects. Create them as you would normally create full took project with TransSECS completing the VIDs, CEIDs, ALIDs and messages.

Change the connection port parameter so each tool will be listening on a unique port for example 5010,5020, and 5030. These can be changed later (as usual) in the OPC server.

Be sure that OPCUA Server is selected as the deployment type, and press the build button (Hammer/Star button) to build the code. After building the code, the old “GEMTool.tsx” project file will remain in the directory. This can be deleted now, but this is not necessary.

Close this first project and load the next project. Repeat building and connection testing for your other tools.

When the code was built for each GEMTool in the previous stage and each GEMTool was built into its own OPCUA deployment the multi-tool can be configured.

Extract the files from the OPCUAServerRunner zip into the root of the directory where the multiple GEMTool projects reside.

Open the file “OPCServersList.properties” in a text editor such as WordPad or Notepad++.

The left hand column will be the node name in the combined OPC UA Sever for the project listed on the right side. For example, the first line says “Tool1=GEMTool1” which means the node name in the server will be Tool1 for the TransSECS project GEMTool1. The directory “GEMTool1” must exist and have a built OPC UA Server project in it.

At this stage, ensure that the deployment folder, eg GEMTool1/OPCUA contain the OPCUAServerToolRunner.jar file . If not, copy it from the resources folder to the OPCUA folders.

Use the runall.bat file to run the OPC UA Server. This can also be run on Linux systems (convert the contents of the runall.bat file to a shell script or contact ErgoTech for assistance).

When you first run the server, if built with non-trial software, you will see a popup with a pre-license code unique to your system. This pre-license code will also be printed in the SECSMessages.log file. Please copy this code into an email and send this to ErgoTech so that we can send you an IOT runtime license for your system.

Place the IOT license into this directory and restart the OPC UA Server with the runall.bat file.

When you start the OPC UA Server you will see the two new directories created: security and certificates. These will be used later when your OPC UA client attaches.

For testing we use the UAExpert client. Connect your client to the OPC UA Server using the endpont URL

"opc.tcp://localhost:12686/MIXOPCServer"

any security policy that you prefer. When you first connect you will need to trust the server certificate so that the client can send its certificate to the server.

The next step is to “trust” the client's certificate for the OPC UA Server. You will find the client's certificate in the directory “security/security/pki/rejected” under the directory where you are running the server:

Move this certificate to the “security/security/pki/trusted/certs” directory:

Once this certificate is moved to the trusted store for the server, you will be able to connect to the server with your client and see the server tree with the nodes tool1, tool1, and tool3 (the names set up in the OPCServersList.properties file).

  • deploying_multiple_tools_to_one_transsecs_opcua_server.txt
  • Last modified: 2021/09/29 15:36
  • by wikiadmin