Siemens S7-1200 System Manual page 536

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

Advertisement

Communication
10.2 PROFINET
Table 10- 13 TUSEND and TURCV instructions
LAD / FBD
STEP 7 automatically creates the DB when you insert the instruction.
1
TCON, TDISCON, TUSEND, and TURCV operate asynchronously, which means that the job
processing extends over multiple instruction executions.
Table 10- 14 TUSEND and TURCV data types for the parameters
Parameter and type
REQ
IN
(TUSEND)
EN_R
IN
(TURCV)
ID
IN
LEN
IN
DONE
IN
(TUSEND)
536
SCL
"TUSEND_DB"(
req:=_bool_in_,
ID:=_word_in_,
len:=_udint_in_,
done=>_bool_out_,
busy=>_bool_out_,
error=>_bool_out_,
status=>_word_out_,
data:=_variant_inout_);
"TURCV_DB"(
en_r:=_bool_in_,
ID:=_word_in_,
len:=_udint_in_,
ndr=>_bool_out_,
busy=>_bool_out_,
error=>_bool_out_,
status=>_word_out_,
rcvd_len=>_udint_out_,
data:=_variant_inout_);
Data type
Bool
Bool
Word
UDInt
Bool
Description
The TUSEND instruction sends data via UDP to
the remote partner specified by the parameter
ADDR.
To start the job for sending data, call the TUSEND
instruction with REQ = 1.
The TURCV instruction receives data via UDP.
The parameter ADDR shows the address of the
sender. After successful completion of TURCV, the
parameter ADDR contains the address of the
remote partner (the sender).
TURCV does not support ad hoc mode.
To start the job for receiving data, call the TURCV
instruction with EN_R = 1.
Description
Starts the send job on a rising edge. The data is transferred from
the area specified by DATA and LEN.
0: CPU cannot receive.
1: Enables the CPU to receive. The TURCV instruction is
ready to receive, and the receive job is processed.
Reference to the associated connection between the user
program and the communication level of the operating system.
ID must be identical to the associated parameter ID in the local
connection description.
Range of values: W#16#0001 to W#16#0FFF.
Number of bytes to be sent (TUSEND) or received (TURCV).
Default = 0. The DATA parameter determines the length of
the data to be sent or received.
Otherwise, range of values: 1 to 1472
Status parameter DONE (TUSEND):
0: Job is not yet started or still running.
1: Job completed without error.
S7-1200 Programmable controller
System Manual, 03/2014, A5E02486680-AG

Advertisement

Table of Contents
loading

Table of Contents