This section describes the precautions for exchanging data with socket communications.
Port numbers 1 to 1023 are typically reserved port numbers (WELL KNOWN PORT NUMBERS) and 61440 to 65534 are
used by other communication functions, so 1024 to 4999 or 5010 to 61439 should be used for the own station port numbers.
5000 to 5009 are used by the system and must not be specified. ( Page 394 Port Numbers Used by Ethernet-equipped
When using the file transfer function (FTP server), do not specify 20 or 21 for socket communications. When using the time
setting function (SNTP client), do not specify 123 for socket communications.
Reading received data
If 'Socket/fixed buffer reception status signal' (Un\G1900016 to Un\G1900023) is on, read the received data. The
communication could be affected if large amounts of data are not read out for a while.
Accessing a file during communication
The CPU module prioritizes the file access processing over the Ethernet communication processing. Thus, if the file is
accessed with FTP, the engineering tool, and so on, during socket communications, the socket communications processing
could be delayed.
To access a file while monitoring the response time with the external device with socket communications, add the time
required for accessing the file to the monitoring time.
Module FB and dedicated instruction
• When performing the open processing using the module FB or dedicated instruction, start sending and receiving data after
the module FB or dedicated instruction is completed.
• Multiple module FBs or dedicated instructions to one connection cannot be simultaneously executed. When multiple
module FBs or dedicated instructions are simultaneously executed, no operation is performed for the module FB or
dedicated instruction executed later. Execute again after the module FB or dedicated instruction in execution is completed.
1.4 Socket Communications