103BCommunication
10.2 PROFINET
S7-1200 Programmable controller
400
System Manual, 11/2011, A5E02486680-05
Table 10- 1 Protocols and communication instructions for each
Protocol
Usage examples
Entering data in the
receive area
Communication
instructions
Addressing type
Ad hoc mode
Only TRCV_C, and
TRCV
TCP
CPU-to-CPU
communication
Transport of frames
Data reception with
specified length
TSEND_C, TRCV_C,
TCON, TDISCON,
TSEND, and TRCV
Assigns port numbers to
the Local (active) and
Partner (passive)
devices
Ad hoc mode
Only TRCV_C and
TRCV
ISO on TCP
CPU-to-CPU
communication
Message
fragmentation and re-
assembly
Protocol-controlled
TSEND_C, TRCV_C,
TCON, TDISCON,
TSEND, and TRCV
Assigns TSAPs to the
Local (active) and
Partner (passive)
devices
UDP
CPU-to-CPU
communication
User program
communications
User Datagram Protocol TUSEND and TURCV
Assigns port numbers to
the Local (active) and
Partner (passive)
devices, but is not a
dedicated connection
S7 communication CPU-to-CPU
communication
Read/write data
from/to a CPU
Data transmission and
reception with specified
length
GET and PUT
Assigns TSAPs to the
Local (active) and
Partner (passive)
devices
PROFINET RT
CPU-to-PROFINET
IO device
communication
Data transmission and
reception with specified
length
Built-in
Built-in
10.2.2.3
Ad hoc mode
Typically, TCP and ISO-on-TCP receive data packets of a specified length, ranging from 1 to
8192 bytes. However, the TRCV_C and TRCV communication instructions also provide an
"ad hoc" communications mode that can receive data packets of a variable length from 1 to
1472 bytes.
Note
If you store the data in an "optimized" DB (symbolic only), you can receive data only in
arrays of Byte, Char, USInt, and SInt data types.
To configure the TRCV_C or TRCV instruction for ad hoc mode, set the LEN parameter to
65535.
If you do not call the TRCV_C or TRCV instruction in ad hoc mode frequently, you could
receive more than one packet in one call. For example: If you were to receive five 100-byte
packets with one call, TCP would deliver these five packets as one 500-byte packet, while
ISO-on-TCP would restructure the packets into five 100-byte packets.