Pulse diagram
(1)
Activation of function
(2)
Positive acknowledgment: Receive new data
(3)
Reset function activation after receipt of acknowledgment
(4)
Signal change by means of FB
(5)
Not permissible
(6)
Negative acknowledgment: Error has occurred, error code in the output parameter State
Call example
Reading of three channelspecific machine data from channel 1, whose address specifications are stored in
DB120.
Select data with NC VAR selector and store in file DB120.VAR; then create file DB120.AWL:
Area
Block
Name
C[1]
M
MD20070 $MC_AXCONF_MACHAX_USED[1]
C[1]
M
MD20070 $MC_AXCONF_MACHAX_USED[2]
C[1]
M
MD20090 $MC_SPIND_DEF_MASTER_SPIND
S7 (ALIAS) names have been selected in order to:
•
Incorporate the channel designation into the name
and
•
Remove the characters [ ], which are not legal in a STEP 7 symbol.
Entry of the name in the S7 SYMBOL table (e.g. NCVAR for DB120):
Symbol
NCVAR
File DB120.AWL must be compiled and transferred to the PLC.
Parameterization of FB 2 with instance DB 110:
DATA_BLOCK DB 110
FB 2
BEGIN
END_DATA_BLOCK
Function FC "VariablenCall" : VOID
Basic Functions
Function Manual, 09/2011, 6FC5397-0BP40-2BA0
Operand
DB 120
//Unassigned user DB, as instance for FB 2
P3: Basic PLC Program for SINUMERIK 840D sl
Typ
No.
Byte S7 Name
e
char 20070
1
char 20070
1
int
20090
1
Data type
DB 120
13.13 Block descriptions
C1AxConfMachAx Used1
C1AxConfMachAx Used2
C1SpindDefMaster Spind
937