Communication via Function Blocks
6.7 Parameter assignment of the Function Blocks
CP 341 Point-to-Point Communication, Installation and Parameter Assignment
176
Manual, 09/2008, A5E02191071-01
Example of an "Actual operand with symbolic addressing"
Call of FB 8 with actual operands with symbolic addressing:
STL
Network 1:
CALL
FB 8, DB8
SF
:= S
//Send request
REQ
:= M 0.6
//Activates SEND
R
:= M 5.0
//Activates RESET
LADDR
:= BGADR
//Start address
DB_NO
:= CP_DB.SEND_DBNR
//Send DB no.
DBB_NO
:= CP_DB.SEND_DWNR
//Message frame starting
//from data byte
LEN
:= CP_DB.SEND_LAE
//Message frame length
R_CPU_NO
:=
//
R_TYP
:=
//
R_NO
:=
//
R_OFFSET
:=
//
R_CF_BYT
:=
//
R_CF_BIT
:=
//
DONE
:= SEND_DONE
//Completed without error
ERROR
:= SEND_ERROR
//Terminated with error
STATUS
:= SEND_STATUS
//Status word
EN/ENO Mechanism
The EN and ENO parameters are only present in the graphical representation (LAD or FBD).
To process these parameters, the compiler uses the binary result (BR).
The binary result BR is set to signal state "1" if the block was has been completed without
errors. If there was an error, the BR is set to "0".
长沙工控帮教育科技有限公司
www.gkbpx.com