EasyManua.ls Logo

Siemens SIMATIC S7 - Page 221

Siemens SIMATIC S7
866 pages
To Next Page IconTo Next Page
To Next Page IconTo Next Page
To Previous Page IconTo Previous Page
To Previous Page IconTo Previous Page
Loading...
Program instructions
7.3 Communication
S7-200 SMART
System Manual, V2.3, 07/2017, A5E03822230-AF
221
Table 7- 9 Definition of TCON instruction TABLE parameter structure for UDP and TCP
Byte
offset
Bit 7
Bit 6
Bit 5
Bit 4
Bit 3
Bit 2
Bit 1
Bit 0
0
D
A
E
Error code (5 bits)
1 A/P
1
REQ
2
Connection ID
(2 bytes)
3
4
Connection Type
2
5
Remote
IP
Address
3
6
7
8
9
Remote port
4
10
11
Local port
5
12
1
A/P: Active/Passive selection (1 = Active, 0 = Passive)
2
Connection Type: The Connection Type informs the TCON instruction of the desired type of con-
nection: UDP = 19 and TCP = 11
3
Remote IP address: This is the IP address of the remote device in the case of an active connec-
tion. You should set the Remote IP Address to 0.0.0.0 for UDP connections. The IP address must
be different than that of the local CPU and cannot be a multicast or broadcast address. Since the
S7-200 SMART supports routing, the IP address may be on a different subnet than the local CPU.
If you set the IP address for a passive (server) connection, then the CPU only accepts a connec-
tion from the specified IP address. If you set the IP add
ress to 0.0.0.0 for a passive connection, the
CPU accepts a connection from any IP address.
4
Remote Port: This is the port number in the remote device. You do not use the remote port num-
ber for UDP or passive connections, and you should set the Remote Port to zero.
5
Local Port: This is the port number for the connection in the local CPU.

Table of Contents

Other manuals for Siemens SIMATIC S7

Related product manuals