Config File Entries
The following configuration parameters can be set under the mod section of the config file located at [installation drive:]\[installation folder]\[project]\config.
NOTE: You must add the mod section to the config file.
In case the config parameter must be specific for the driver instance, it can be placed under [mod_n] where n is the instance number. For example:
[mod]
littleEndianRegister=1
Forces all driver instances to use little endian byte ordering, whereas
[mod_1]
littleEndianRegister=1
applies the config to only driver instance number 1.
NOTE:
In order to apply the configuration, you must restart the Modbus driver.
The following table lists all possible configuration parameters.
| | | | |
| | | | Specifies an alive timeout for the driver in seconds. Value 0 means that no messages are sent. A value > 0 means that the driver sends a request to all connected PLCs every aliveTimeout seconds. A dummy request is sent to test if the connection is OK. |
| | | | Specifies the function code and the reference number for the alive request. |
| | | | Defines the reference number that is used by the driver to decide whether it is a Modbus or a UNICOS frame. The entry is deactivated by default. |
| | | | The driver closes the connection to the PLC if the connection is idle for the specified time (in seconds). This is done only for connections in master mode. |
| | | | Defines whether 16 Bit register is organized according to little endian or big endian. By default the little endian register is transmitted first. Note: - ●
- Little endian = The least significant bit is saved on the first position.
- ●
- Big endian = The most significant bit is saved on the first position.
|
| | | | Specifies how many times the driver retries to establish a connection when sending a telegram, if the connection request fails. |
| | | | If the difference of two consecutive address reference numbers is lower or equal to the value in maxGap, then these addresses are grouped together in one poll block. If not, then a second poll block is created. This entry provides the poll query optimization. |
| | | | The maximum number of outstanding requests without response. The entry can be used for sending more requests in advance in order to speed up the communication. If you set the value of the entry higher than 1, you must verify that the PLCs controlled by the driver can handle several requests. |
| | | | Defines the size of the request queue for master mode. For example maxQueueSize = 1000 |
| | | | Specifies the number of retries for a connection establishment before the connection is marked as dead. Default: 0, that is, after the first failure the driver is continuously endlessly retrying to establish the connection. |
| | | | OnlyActivePolls = 1specifies that only the active driver polls in a redundant system. The default value is 0 (both drivers poll the PLC). |
| | | | Defines whether a poll query optimization is used for blobs |
| | | | Time (in ms) which must be between two requests. The value should not be set too high, because it reduces data throughput. This entry is only relevant if gateways are involved. |
| | | | Connection timeout. (in ms) When the connection is established, the driver waits until the connection is initialized and until an acknowledgement is received from the PLC. If the driver does not receive the acknowledgement within a timeout, the driver re-establishes the connection. The timeout is specified using the following config entry tcpConnectTimeout in the Modbus section. |
NOTE:
If you get the following message from the Modbus driver, then you must explicitly mention the value of the maxQueueSize entry to a value that is greater than the default value and thereafter restart the driver.
WCCOAmod (4), 2018.08.08 10:40:55.148, PARAM,WARNING, 54, Unexpected state, ModOutputQueue, queueFrame, Maximum requests in queue, request discarded; server 192.168.1.171 port 17002