Communication
8.4 Ethernet
S7-200 SMART
System Manual, V2.3, 07/2017, A5E03822230-AF
419
8.4.7.3
Ports and TSAPs
Ports and Transport Service Access Points (TSAPs) provide for the routing of messages to
the proper receiver within the CPU or other device.
Ports
The UDP and TCP protocols allow you to select the local and remote port numbers. The port
number is fixed at port 102 when you select the ISO-on-TCP protocol.
Port numbers must be in the range of 1 to 49151. It is recommended that port numbers be in
the range of 2000 to 5000. The S7-200 SMART CPU range and restriction rules for port
numbers are shown in the tables below:
Port number
Description
1 to 1999
•
You can use these numbers; however, they are outside the rec-
ommended range.
•
Some ports are excluded (see below).
2000 to 5000
Recommended range
5001 to 49151
•
You can use these numbers; however, they are outside the rec-
ommended range.
•
Some ports are excluded (see below).
49152 to 65535
•
These are dynamic or private ports.
•
The use of these port numbers is restricted.
You cannot use the port numbers shown in the following table for local port numbers in the
S7-200 SMART CPU. You have no restrictions for the remote port number:
Port number
Description
20
FTP data transmission
21
FTP control
25
SMTP
80
Web server
102
ISO-on-TCP
135
DCE for PROFINET
161
SNMP
162
SNMP Trap
443
HTTPS
34962 to 34964
PROFINET
You can have multiple active connections use the same port number for the local and remote
port numbers. For example, a TCP client can connect to multiple servers on port 2500. Both
the local and remote ports would normally be port 2500 for the active connection.
You cannot have multiple passive connections use the same port number as the local port
number. For example, the CPU does not allow multiple TCP servers (multiple passive
connections) to be on local port 2500. The CPU does not know to which of the multiple 2500
ports to route the messages.