Rcv_Ptp (Enable Receive Messages) Instruction - Siemens S7-1200 System Manual

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

Advertisement

12.3.3.6

RCV_PTP (Enable receive messages) instruction

Table 12- 23 RCV_PTP (Receive Point-to-Point) instruction
LAD / FBD
STEP 7 automatically creates the DB when you insert the instruction.
1
Table 12- 24 Data types for the parameters
Parameter and type
EN_R
IN
PORT
IN
BUFFER
IN
NDR
OUT
ERROR
OUT
STATUS
OUT
LENGTH
OUT
The STATUS value is valid when either NDR or ERROR is TRUE. The STATUS value
provides the reason for termination of the receive operation in the CM or CB. This is typically
a positive value, indicating that the receive operation was successful and that the receive
process terminated normally. If the STATUS value is negative (the Most Significant Bit of the
hexadecimal value is set), the receive operation was terminated for an error condition such
as parity, framing, or overrun errors.
Each PtP communication interface can buffer up to a maximum of 1024 bytes. This could be
one large message or several smaller messages. If more than one message is available in
the CM or CB, the RCV_PTP instruction returns the oldest message available. A subsequent
RCV_PTP instruction execution returns the next oldest message available.
S7-1200 Programmable controller
System Manual, 03/2014, A5E02486680-AG
SCL
"RCV_PTP_DB"(
EN_R:=_bool_in_,
PORT:=_uint_in_,
BUFFER:=_variant_in_,
NDR=>_bool_out_,
ERROR=>_bool_out_,
STATUS=>_word_out_,
LENGTH=>_uint_out_);
Data type
Description
Bool
When this input is TRUE and a message is available, the message is
transferred from the CM or CB to the BUFFER. When EN_R is FALSE, the CM
or CB is checked for messages and NDR, ERROR and STATUS output are
updated, but the message is not transferred to the BUFFER. (Default value: 0)
PORT
After you install and configure a CM or CB communication device, the port
identifier appears in the parameter helper drop-list available at the PORT box
connection. The assigned CM or CB port value is the device configuration
property "hardware identifier". The port symbolic name is assigned in the
"System constants" tab of the PLC tag table. (Default value: 0)
Variant
This parameter points to the starting location of the receive buffer. This buffer
should be large enough to receive the maximum length message.
Boolean data or Boolean arrays are not supported. (Default value: 0)
Bool
TRUE for one execution when new data is ready and operation is complete
with no errors.
Bool
TRUE for one execution after the operation was completed with an error.
Word
Execution condition code (Default value: 0)
UInt
Length of the returned message in bytes (Default value: 0)
Communication processor and Modbus TCP
12.3 Point-to-point (PtP) communication
Description
RCV_PTP checks for messages that have been
received in the CM or CB. If a message is available, it
will be transferred from the CM or CB to the CPU. An
error returns the appropriate STATUS value.
697

Advertisement

Table of Contents
loading

Table of Contents