Siemens SIMATIC S7-400 CP 440 Installation And Parameter Assignment page 105

Point-to-point connection
Table of Contents

Advertisement

Example 2
The symbol name of the data block used, DB 20, is "CP_DB"; the symbol name for the send
DB number is "SEND_DBNO" and is located in data block DB 20 in the data word DBW 0.
The start address of the send frame is "SEND_DWNO" and is located in the data block
DB 20 in DBW 2. The frame length is "SEND_LEN" and is located in the data block DB 20 in
DBW 4.
The variable used for the module address is the memory word "BGADR" (MW21), for the
DONE parameter the flag "SEND_DONE" (M26.0), for the ERROR parameter the memory
bit "SEND_ERROR" (M26.1), and for the STATUS parameter the memory word
"SEND_STATUS" (MW27).
The STL listings for the example are shown on the following page.
Example of an Absolutely Addressed Actual Operand
Calling FB 10 with absolutely addressed actual operands:
STL
Network 1:
Point-to-point connection CP 440 Installation and Parameter Assignment
Manual, 09/2007, A5E00057742-03
www.gkbpx.com
CALL
FB 10, DB10
REQ
R
LADDR
DB_NO
DBB_NO
LEN
DONE
ERROR
STATUS
6.4 Programming the Function Blocks
:= M 0.6
//Activates SEND
:= M 5.0
//Activates RESET
:= MW21
//Basic address in MW21
:= DB20.DBW0
//DB no. in DBW0 of DB20
:= DB20.DBW2
//From DBB no., located in DBW2 of DB20
:= DB20.DBW4
//Length located in DBW4 of DB20
:= M 26.0
//Terminated without error
:= M 26.1
//Terminated with error
:= MW 27
//Status word
该文档是极速PDF编辑器生成,
如果想去掉该提示,请访问并下载:
http://www.jisupdfeditor.com/
Communication via Function Blocks
105

Advertisement

Table of Contents
loading

Table of Contents