4. Configuration
118
Communication Times
The communication times of the MODBUS server protocol, found on the “Advanced...” button of the
configuration screen, are divided into: Task Cycle and Connection Inactivity Time-out.
Configuration
Description
Default Value
Options
Task Cycle
(ms)
Time for the instance execution
within the cycle, without considering
its own execution time.
50
5 to 100
Connection
Inactivity
Time-out (s)
Maximum idle time between client
and server before the connection is
closed by the server.
10
10 to 3600
Table 4-70. Advanced Configurations
Notes:
Task Cycle:
The user has to be careful when changing this parameter as it interferes directly in the
answer time, data volume per scanning and mainly in the CPU resources balance between
communications and other tasks.
Connection Inactivity Time-out:
This parameter was created in order to avoid that the maximum
quantity of TCP connections is reached, assuming that inactive connections remain open on account
of the most different problems. It indicates how long a connection (client or server) can remain open
without being used (without exchanging communication messages). If the specified time is not
reached, the connection is closed releasing an input in the connection table.
MODBUS Server Diagnostics
The diagnostics and commands of the configured MODBUS TCP server protocol are stored in
variables of type T_DIAG_MODBUS_ETH_SERVER_1 which are described in Table 4-71:
Diagnostics Variable
T_DIAG_MODBUS_ETH_SERVER_1 *.
Size
Description
Diagnostic bits:
tDiag.*
bRunning
BOOL
The server is running
bNotRunning
BOOL
The server is not running (see bit:
bInterruptedByCommand)
bInterruptedByCommand
BOOL
The bit bNotRunning was enabled,
because the server was interrupted by
the user through the command bit.
bConfigFailure
BOOL
Discontinued diagnostic
bRXFailure
BOOL
Discontinued diagnostic
bTXFailure
BOOL
Discontinued diagnostic
bModuleFailure
BOOL
Discontinued diagnostic
bDiag_7_reserved
BOOL
Reserved
byDiag_1_reserved
BYTE
Reserved
Command bits, restarted automatically:
tCommand.*
bStop
BOOL
Stop the server
bRestart
BOOL
Restart the server
bResetCounter
BOOL
Reset diagnostics statistics (counters)
bDiag_19_reserved
BOOL
Reserved
bDiag_20_reserved
BOOL
Reserved
bDiag_21_reserved
BOOL
Reserved
bDiag_22_reserved
BOOL
Reserved
bDiag_23_reserved
BOOL
Reserved
byDiag_03_reserved
BYTE
Reserved.