P3: Basic PLC Program for SINUMERIK 840D sl
13.13 Block descriptions
Basic Functions
932
Function Manual, 09/2011, 6FC5397-0BP40-2BA0
MCP/HHU monitoring (840D sl)
The following alarms are displayed at HMI in cases of errors for the communication with the machine control
panel (MCP):
• 400260: MCP 1 failure or
• 400261: MCP 2 failure
• 400262: HHU failure
In this case, the input signals from the MCP or from the handheld unit (MCP1In/MCP2In or BHGIn) are reset to 0.
If it is possible to resynchronize the PLC and MCP/HHU, communication is resumed automatically and the error
message reset by the GP.
Call example for 840D sl
An example call for the FB 1 in OB 100 appears below. This example is part of the diskette with basic program for
840D sl.
ORGANIZATION_BLOCK OB 100
VAR_TEMP
OB100_EV_CLASS :
BYTE ;
OB100_STRTUP :
BYTE ;
OB100_PRIORITY :
BYTE ;
OB100_OB_NUMBR :
BYTE ;
OB100_RESERVED_1 :
BYTE ;
OB100_RESERVED_2 :
BYTE ;
OB100_STOP :
WORD ;
OB100_RESERVED_3 :
WORD ;
OB100_RESERVED_4 :
WORD ;
OB100_DATE_TIME :
DATE_AND_TIME;
END_VAR
BEGIN
CALL FB 1, DB 7 (
MCPNum :=
1,
MCP1In :=
P#E0.0,
MCP1Out :=
P#A0.0,
MCP1StatSend :=
P#A8.0,
MCP1StatRec :=
P#A12.0,
MCP1BusAdr :=
6,
MCP1Timeout :=
S5T#700MS,
MCP1Cycl :=
S5T#200MS,
NC-CyclTimeout :=
S5T#200MS,
NC-RunupTimeout :=
S5T#50S);
//INSERT USER PROGRAM HERE
END_ORGANIZATION_BLOCK