P3: Basic PLC Program for SINUMERIK 840D sl
13.13 Block descriptions
Basic Functions
Function Manual, 09/2011, 6FC5397-0BP40-2BA0
937
Pulse diagram
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:
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):
File DB120.AWL must be compiled and transferred to the PLC.
Parameterization of FB 2 with instance DB 110:
(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
Area
Block
Name
Typ
e
No.
Byte S7 Name
C[1]
M
MD20070 $MC_AXCONF_MACHAX_USED[1]
char 20070 1
C1AxConfMachAx Used1
C[1]
M
MD20070 $MC_AXCONF_MACHAX_USED[2]
char 20070 1
C1AxConfMachAx Used2
C[1]
M
MD20090 $MC_SPIND_DEF_MASTER_SPIND int
20090 1
C1SpindDefMaster Spind
Symbol
Operand
Data type
NCVAR
DB 120
DB 120
DATA_BLOCK DB 110
//Unassigned user DB, as instance for FB 2
FB 2
BEGIN
END_DATA_BLOCK
Function FC "VariablenCall" : VOID
1'5
5HT
(UURU