KingIOServer OPC DA Server Functionality
KingIOServer OPC DA Server Functionality
KingIOServer follows the standard OPC DA 3.0 specification, supports custom interfaces, and is backward
compatible. Any OPC Client that supports this standard can access KingIOServer's data. If KingIOServer
and the OPC DA Server are on the same machine, and the OPC DA Client is on another machine, their data
interaction requires DCOM configuration.
Machine1 Machine2
DCOM
KingIOServer
Data OPC DA Client
OPC DA Server
If the OPC DA Server and OPC DA Client are on the same machine while KingIOServer is on another
machine, complex and error-prone DCOM configuration can be avoided. KingIOServer provides an OPC
configuration tool, which allows users to configure the OPC DA service's IOServer data source. This way,
you can access KingIOServer's data on any machine within the network without complex DCOM
configuration.
Machine1
OPC Config Tool Machine2
OPC DA Client
KingIOServer
Data
OPC DA Server
Figure 5-2: Scenario for data interaction through the OPC configuration tool
OPC DA Service Mapping Functionality: Through the OPC service configuration tool, users can customize
the mapping information for OPC Item names. The customized OPC Item names will be displayed on the
OPC DA client.
`KingOpcServer.config.xml` is the configuration file for the OPC DA Server data source and can be edited
using the OPC service configuration tool.
When KingIOServer and the IOServer data source are deployed on the same machine, there are three
scenarios:
1. One OPC DA Server service accessing only one IOServer data source on the same machine:
o If the IP address and port number of IOServer use the default values 127.0.0.1 and 12380,
which match the default data source in the KingOpcServer.config.xml, then no manual
configuration or modification of the KingOpcServer.config.xml is required.
o However, if the IP or port number is changed, the data source must be manually
configured. Using the OPC configuration tool, the user must add or edit the corresponding
IOServer’s IP, port, and display name in the KingOpcServer.config.xml file.
2. One OPCServer service accessing two or more IOServers on the same machine:
o The user must use the OPC configuration tool to configure the KingOpcServer.config.xml
and add the relevant data sources.
o The OPC configuration tool must be used to configure the IP of the primary IOServer,
while the secondary IOServer’s IP is optional. It is recommended to configure both the
primary and secondary IPs for redundancy.
o If the secondary IOServer’s IP is not configured, the primary IOServer must be available
for the OPC DA Client to successfully connect for the first time. If the secondary IP is
configured, only one of the two IOServers (primary or secondary) needs to be successfully
connected at the first attempt. Additionally, the OPC configuration tool and the OPC DA
Client must be deployed on the same computer.
When KingIOServer and the IOServer data source are deployed on different machines within the network,
the OPC configuration tool must be used to configure the data source in the KingOpcServer.config.xml
(the OPC DA Server configuration file), setting the appropriate IP, port number, and alias.
If OPC DA point name mapping is required, the OPC service configuration tool should be used to configure
the mapping information for OPC Items (whether to map, and the mapping file *.CSV). First, export all
variables of the configured IOServer project to the mapping file based on the tool’s prompts. Then,
manually edit the "Mapped Name" in the file to the desired name (mapping names are case-sensitive).
When the client reconnects to the OPC DA service, the client interface will display the user-defined
mapping names.
Note: The mapping file includes fields such as IOServer IP, redundant IP, port number, alias, all OPC DA
point source names, and mapping names (by default, mapping names are identical to source names).
• The KingOpcServer.config.xml file is located in the /BIN folder in the installation root directory
and is mainly used to configure IOServer data sources for the OPC DA service.
In the KingOpcServer.config.xml file, the SelfRegInfo element is used to configure the basic information
for the IOServer data source. The configuration format is as follows:
Users can edit the following information:
• IP address: The IP address of the local or remote IOServer application. (This parameter can be
found in the IOServer collector or project designer under project properties.) For dual IOServer
redundancy, this refers to the IP address of the primary IOServer.
• Port: The port number of the local or remote IOServer application. (This can also be found in the
IOServer collector or project designer under project properties.)
• Redundant IP: The IP address of the secondary IOServer in a dual IOServer redundancy setup.
• Alias: The name of the data source as displayed in the OPC DA client, which is used to
distinguish between different IOServer data sources.
The tagMappingPath element is used to configure the mapping information for OPC Item names. Users
can define whether to map the OPC Item names and specify the mapping file path. The configuration
format is as follows:
• Mapping Status: Specifies whether the OPC Item names should be mapped. Use true to enable
mapping and false to disable it.
The mapping file uses a CSV format. The CSV file contains parameters such as the source OPC Item
names and their corresponding mapped names.
• Source Name: The variable name of the data source (i.e., the original OPC Item name).
• Mapped Name: The variable name after mapping (i.e., the custom OPC Item name that will be
displayed in the OPC DA client).
• Other Parameters: The meaning of other parameters is consistent with their definitions in the
KingOpcServer.config.xml configuration file, such as IP address, redundant IP, port, and alias.