Ptp, Uss, And Modbus Communication Protocols - Siemens SIMATIC S7-1200 Manual

Hide thumbs Also See for SIMATIC S7-1200:
Table of Contents

Advertisement

● To establish a connection, execute TRCV_C with parameter CONT = 1.
● To receive data, execute TRCV_C with parameter EN_R = 1. Receive data continuously
● To terminate the connection, execute TRCV_C with parameter CONT = 0. The
Note
The processing of the TSEND_C and TRCV_C instructions can take an undetermined
amount of time. To ensure that these instructions are processed in every scan cycle, always
call them from within the main program cycle scan, such as from a program cycle OB or from
a code block that is called from the program cycle scan. Do not call these instructions from a
hardware interrupt OB, a time-delay interrupt OB, a cyclic interrupt OB, an error interrupt OB,
or a startup OB.
6.2

PtP, USS, and Modbus communication protocols

PtP is serial communication that supports a variety of baud rates and parity options. STEP 7
Basic provides libraries of instructions that you can use in programming your application.
These libraries provide PtP communication functions for the USS drive protocol (RS485
only) and Modbus RTU Master and RTU Slave protocols.
Easy Book
Manual, 11/2009, A5E02486774-01
when parameters EN_R = 1 and CONT = 1.
connection will be aborted immediately and data could be lost.
6.2 PtP, USS, and Modbus communication protocols
TRCV_C establishes a TCP or ISO-on-TCP communication
connection to a partner CPU, receives data, and can
terminate the connection. After the connection is set up and
established, it is automatically maintained and monitored by
the CPU. The TRCV_C instruction combines the functions of
the TCON, TDISCON, and TRCV instructions.
The CPU supports the PtP protocol for
character-based serial communication, in which
the user application completely defines and
implements the protocol of choice. PtP enables
a wide variety of possibilities:
• Sending information directly to an external
device such as a printer
• Receiving information from devices such as
barcode readers, RFID readers, third-party
camera or vision systems, and many other
types of devices
• Sending and receiving data with devices
such as GPS devices, third-party camera or
vision systems, or radio modems
Easy to communicate between devices
73

Advertisement

Table of Contents
loading

Table of Contents