User manual

Transferring Data Using Communication Blocks
33002479 06 07/2008 141
WRITE_REG
Function
Description
Upon request, the WRITE_REG block writes a register area once (rising edge of the
REQ input). It transfers data from the PLC via TCP/IP Ethernet to an addressed
slave.
EN and ENO can be configured as additional parameters.
Symbol Block representation:
Parameter
Description
Description of parameters:
Note: About this function block:
z When programming this function, you must be familiar with the routing
procedures used by your network.
z For technical reasons, this function block does not allow the use of ST and IL
programming languages.
WRITE_REG
REQBOOL
SLAVEREG
DINT
NO_REG
INT
REG_WRIT
WORD
AddrFld
WordArr5
BOOLDONE
BOOL
ERROR
WORD
STATUS
Parameter Data Type Meaning
REQ BOOL start write operation once
SLAVEREG DINT offset address of the first %MW word (4x register) in the
slave to be written to
NO_REG INT number of registers to be written from slave
AddrFld WordArr5 data structure transferring the TCP/IP address
REG_WRIT WORD first %MW word (4x register) of the source data area
DONE BOOL set to "1" for one scan after writing data
ERROR BOOL set to "1" for one scan in case of error
STATUS WORD error code