Siemens SIMATIC NET CP 243-1 IT Technical Manual page 125

Communications processor for industrial ethernet and information technology
Table of Contents

Advertisement

03/03
NETWORK 4
The local S7-200 station sends data from the VB500 (data length of 5 Byte) on the
Ethernet connection to another S7-200 station. There the data are stored in
VB500.
The read/write command only takes place after a positive edge at the "START" pa-
rameter, if the "Done" bit of any preceding read command is set. The "Done" bit is
carried over in the "ch0_done_read" variable. The outputs of the read and write
command are linked in such a manner, that only one command per channel can be
processed at any one time. Thus, a new command is only initiated after the pre-
ceding command is finished.
The "Chan_ID" parameter specifies the number of the channel through which the
data access is to take place. In the present case, this would be the channel with
the number 0. The "Data" parameter specifies the number of the channel-specific
data block. A command that has been initiated can be aborted using the "Abort"
parameter. To do so, the M7.0 flag must be set. In this example, this flag also acts
on the read command from Network 5.
After flag M7.0 is cleared, read/write commands are again issued since the "Done"
bit is always set along with the "Error" bit after a command is aborted.
Applying special flag SM0.0 ensures that the ETH0_XFR subroutine is always en-
abled.
As soon as the write command is finished, a 1 is returned in the "Done" return pa-
rameter. Any errors that occurred are returned by the "Error" parameter. Otherwise,
a 0 is returned in this parameter.
LD
=
LD
EU
U
LD
EU
OLD
=
LD
CALL
Symbol
Always_On
ch0_done_read
ch0_done_write
ch0_error_write
ch0_ready
Connection0_0
Connection_abort
CP 243-1 IT
J31069-D0429-U001-A0-7618
Always_On
L60.0
ch0_done_read
ch0_ready
start
L63.7
L60.0
ETH0_XFR, L63.7, Connection0_0, Write_1,
Connection_abort, ch0_done_write, ch0_error_write
Address
SM0.0
Always ON
M5.0
Done bit of the read command
M5.1
Done bit of the write command
MB14
Error flag of channel 0, "write" command
M8.0
Bit for channel 0 in the CH_READY return value of the
ETH0_CTRL subroutine
VB233
M7.0
Transmission aborted
Comment
Example
125

Advertisement

Table of Contents
loading

This manual is also suitable for:

Cp 243-1 it

Table of Contents