The driver allows communication with Regin's DUCs via the Exoline protocol from WebPort by both reading and writing. Web Port connects to DUC and DUC connects to Web Port are supported.
At the moment only communication over TCP/IP is implemented, but the code that handles communication over EXOLine is "protocol agnostic" and will also work towards RS485 should such a need arise in the future.
Installation
The installation of DrvExoline is done by selecting DrvExoline when installing the Web Port. See "Installation" for more information on the installation process.
Configuration
To use, a DrvExoline is created for an IO device according to "Create IO-device" in the "IO-Devices"-manual. In addition to general settings (see "General settings in the "IO-Devices"-manual), there are the following settings for an IO device of the DrvExoline type.
| Setting: | Description: |
| Server or client | *See information "Using the driver" below |
| IP Address or Hostname | IP or hostname of the DUC to connect to |
| IP port | Network port used for the connection (default: 26486). |
| Request timeout [ms] |
Max time to wait for a response before failing. |
| Symbol file |
File mapping variable names to device addresses. |
| Link to |
Use another IO device’s connection instead of creating a new one. |
| PLA number |
Logical ID for identifying the device in linked setups. |
| ELA number |
Extended ID for verifying and tracking the device. |
| server specific settings (Dropdown) |
|
| Validation expression |
Rule to verify correct DUC has connected. *See information "Additional validation" below |
| IP to Exodesigner server |
IP address of ExoDesigner server if used. |
| Close connection on failure |
Force reconnect by closing on communication errors. |
Using the driver
Start by setting up a new IO device and select the DrvEXOLineTCP driver, then choose whether Web Port will act as client (connect to DUC) or server (DUC connects to server).
Connect to DUC
Enter the IP number and Port number of your DUC.
The port number is normally 26486
When you press Save, a simple communication test will be performed against the above IP/Port number and if successful, the IO device will be set to green.
When selecting a linked device, all communication goes through the linked device instead of the IO device maintaining its own connection. This is preferable when using loops.
ELA/PLA allows extended communication testing and is needed to provide communication status on individual devices when using linked devices.
DUC connects to server
IP number: If no IP address is specified, Web Port will initially accept connections from all IP addresses. When the DUC connects and the ELA/PLA is validated, the IP address is updated and only that IP address will be allowed in the future. If you do not want to lock the IP, you can type a * on the IP address. When connecting the first time, no validation of the IP address will be done, but the current IP address will be updated.
It is also possible to use host names, e.g. for dynamic DNS. This is done by entering the hostname. For example: duc1.exoduc.se. When the DUC connects, Web Port will resolve the hostname and validate the resulting IP address.
ELA/PLA is mandatory when DUC connects to server.
On the driver, there is an option to turn on Debug, which catches connection errors before the handshake is completed. There you can also choose which port the server will listen on.
Additional Validation
In addition to validating PLA/ELA, it is also possible to validate a read value from the controller.
This is done by writing the address and expected value in the Validation expression field. Both symbol names and technical addresses can be used.
Example – Validate serial number:
0:5:1:1:0:241:60={SERIALNO}
Example – Addressing a large INT:
"TestExoDrv1_bigIntTest": {
"Name": "TestExoDrv1_bigIntTest",
"DataType": "INT",
"Address": "5:5:1:1:0:62:9"
}
Example – Addressing a long string:
"TestExoDrv1_stringTest": {
"Name": "TestExoDrv1_stringTest",
"DataType": "STRING",
"Address": "0:5:1:1:0:62:12"
}
If you are using an EXOLine router with multiple controllers behind it, set PLA/ELA to 0/0 on the master device, and use a Validation expression to ensure that the correct controller is allowed to connect.
Tags
It is recommended to use the Exo2Webport tools for importing tags into the Web Port.
Exo2WebPort
Exo2WebPort is a tool used to create import files to IO devices in Web Port from EXODesigner projects. The tool is installed in the same directory as the driver for DrvExoline. (Web Port installation directory/Drivers/DrvExoline)
Short description
The tool reads the modules and variables of an EXODesigner project and can then create import files (in JSON file format) that can be added to the Web Port of the respective IO device. Import files are used to convert addresses from the x:x:x:x:x:x format to symbol names which do not change when recompiling the DUC. The import files can also be used to convert the symbols into tags in Web Port, with or without import filters.
Prerequisites
In order for the addresses to be generated correctly, you must first create so-called list files for the modules in the EXODesign project. Unfortunately, this is a manual process that must be done step by step for each controller/module you want to import with the tool.
Do this:
- Start EXODesigner and open your project
- Select the controller you want to use
- Select menu Config EXOL Files
- Select module (.dpe file, e.g. inputsoutputs.dpe)
- Select menu Tools View List Files
Now a corresponding .dpl file is created and an editor is opened. This editor can be closed immediately and you can start again from point 4 for the next module if desired.
Then repeat for all controllers you want to export.
After creating the list files for all relevant modules, you need to export the entire EXODesigner project. This export will include a file called Modules.Exo, and that is the file you should use in Exo2WebPort.
Using the tool
To translate the EXODesigner project into a symbol list that the Exoline driver in Web Port can read, go through the following steps:
- Open the program Exo2WebPort.exe and open your exported EXODesigner project that contains the file Modules.Exo
- You can now select the controller/module in the tree on the left, and in the list on the right all the variables belonging to the respective device will be listed
- Select the file(Output) to export the data to. Web Port will search for the files under the respective project \assets\import\DrvExoline\devices\
- Select the whole duc or the modules you want to export to and choose Add/Update
- In Web Port, in the IO device settings, select the .conf file you just created.
Tag lists can then be created in a couple of different ways:
1. By importing tags from the .conf file, to a tag list in Web Port.
- This is done by selecting a tag list, importing and then selecting the IO device from the list
- It is then possible to choose which tags to import antigenically by using the filter box or by using the import filter function. (see heading Import filter)
2. By selecting tags in the tool and then:
- right-click and select add to tag list.
- Or select copy and copy tags in webport's .csv format to clipboard and then paste into a tag list opened in a text editor.
Information:
Under File, there is a choice to select whether the DUC name should be included in the exported name and address.
NOTE!
Devices with names containing special characters (such as Å, Ä, Ö, or other non-ASCII letters) will not be detected by Exo2WebPort.
Import filter
Tag lists are created in Web Port by selecting Import tags in a tag list. There is also the possibility to filter these in the filter field or by selecting an import filter. Import filters can either be entered manually at import time, or by using a file. The filter file for Exoline import should be located under \assets\import\DrvExoline\, is in .csv format, and columns as below:
| Filter: | Description: |
| startwidth | Filters symbol names starting with this expression |
| contains | Filters symbol names containing this expression |
| endswith | Filters symbol names ending with this expression |
| find | Searches for this expression in the symbol name and replaces it |
| replace | Replaces the match from find with this value |
| rawmin | Possible scaling value (rawmin) for tag |
| rawmax | Possible scaling value (rawmax) for tag |
| engmin | Possible scaling value or restriction (engmin) for tag |
| engmax | Possible scaling value or restriction (engmax) for tag |
| unit | Possible device for the tag |
| format | Possible formatting for the tag |
| description | Description of the tag |
| alarm option | Any alarm settings for the tag |
| trendoption | Any trend settings for the tag |
Information
DrvExolineImportFIlter.csv contains a number of lines to show how it can be used. However, in order to be useful, it should be extended and adapted to the library and the designation standard used in the programming of the PLC.
To perform an import, go to SYSTEM SETTINGS/TAGS and open the tag list where the tags are to be imported. Click IMPORT TAGS in the toolbar. In the dialog box that opens, select the IO device from which tags are to be imported. Click the import button in the dialog box to start the import. When the import is complete, an information box will appear showing how many tags have been imported.
NOTE!
The import skips tags that already exist in the Web Port. This is true even if the tags are in other tag lists, as Web Port checks the tag name generated on import.
NOTE!
If the Load Number (LN) is not exported from EXODesigner, you can set it manually on your module. If a list has no LN, a Set LN button and a text field will appear when the module is selected.
Direct addressing of Tags
The following ways of working can cause problems when recompiling DUC and cause regeneration of Vpac/Dpac addresses.
In order to address the correct variable in the DUC, you need to specify the address of the variable as follows: 4:1:1:1:58:578
The first digit (4 above) indicates the type of data expected and may contain the following values:
- 0 = String
- 1 = Bit (Logical)
- 2 = Byte (Index)
- 3 = Integer
- 4 = Real
The second digit indicates the data area of the module to be addressed.
- 0 = Local
- 1 = Segment
- 2 = Bitpac
- 3 = Var
- 4 = String
The third and fourth digits indicate the module's PLA/ELA number (these are Regin-specific module addresses, see the EXOLine specification for more information).
These numbers are normally in the order of 1-5 and can be found in your EXODesign project in the file Modules.exo
The last two digits finally address the variable itself by specifying its module's LoadNumber (Vpac/Dpac), 58 in the example above, and finally the variable's offset number (578).