Technical data

Table Of Contents
Open Communication via Industrial Ethernet
System Software for S7-300/400 System and Standard Functions - Volume 2/2
A5E00739858-01
23-33
23.11 Sending Data via UDP with FB 67 "TUSEND"
Description
FB 67 "TUSEND" sends data via UDP to the remote partner specified by the
parameter ADDR.
Note
When sending separate data in sequence to different partners, you only need to
adjust the parameter ADDR when calling FB 67 "TUSEND". It is not necessary to
call FBs 65 "TCON" and 66 "TDISCON" again.
Function
FB 67 "TUSEND" is an asynchronously functioning FB, which means that its
processing extends over several FB calls. To start sending data, call FB 67 with
REQ = 1.
The job status is indicated at the output parameters BUSY and STATUS. STATUS
corresponds to the RET_VAL output parameter of asynchronously functioning
SFCs (see also Meaning of the Parameters REQ, RET_VAL and BUSY with
Asynchronous SFCs).
The following table shows the relationships between BUSY, DONE and ERROR.
Using this table, you can determine the current status of FB 67 or when the
sending process (transmission) is complete.
BUSY DONE ERROR Description
TRUE irrelevant irrelevant The job is being processed.
FALSE TRUE FALSE The job was completed successfully.
FALSE FALSE TRUE The job was ended with an error. The cause of the error can be
found in the STATUS parameter.
FALSE FALSE FALSE The FB was not assigned a (new) job.
Note
Due to the asynchronous function of FB 67 "TUSEND", you must keep the data in
the sender area consistent until the DONE parameter or the ERROR parameter
assumes the value TRUE.