P3: Basic PLC Program for SINUMERIK 840D sl
13.13 Block descriptions
Basic Functions
944
Function Manual, 09/2011, 6FC5397-0BP40-2BA0
Pulse diagram
Call example
Writing of three channelspecific machine data of channel 1:
Select the three data with NC VAR selector and store in the file DB120.VAR:
Entry NCVAR for DB 120 with the S7 SYMBOL Editor:
File DB120.AWL must be compiled and transferred to the PLC.
Call and parameterization of FB 3 with instance DB 111:
(1)
Activation of function
(2)
Positive acknowledgment: variables have been written
(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 output parameter state
Area
Block
Name
Type
Byte S7 Name
C[1]
RP
rpa[5]
DOUBLE
4
rpa_5C1RP
C[1]
RP
rpa[11]
DOUBLE
4
rpa_11C1RP
C[1]
RP
rpa[14)
DOUBLE
4
rpa_14C1RP
Symbol
Operand
Data type
NCVAR
DB 120
DB 120
DATA_BLOCK DB 111
//Unassigned user DB, as instance for FB 3
FB 3
BEGIN
Function FC "VariablenCall": VOID
END_DATA_BLOCK
U
I 7.7;
//Unassigned machine control panel key
I
M 100.0;
//Activate req.
U
M 100.1;
//Done completed message
R
M 100.0;
//Terminate job
U
I 7.6;
//Manual error acknowledgment
U
M 102.0;
//Error pending
'RQH
5HT
(UURU