|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
FB20 MAIN GLB : Global signals evaluation |
|
|
|
Netzwerk 1: Fault acknowledgement entire plant #M00.FLT_CmpltMaACK_Imp := NOT #M00.FLT_CmpltMaACK_REg AND "HMI KEY".P00.GLB.F1_AckKey; #M00.FLT_CmpltMaACK_REg := "HMI KEY".P00.GLB.F1_AckKey; |
|
|
|
Netzwerk 2: Assing global emergency stop #M00.GLB_Estop := "E00 EStp ok" AND "E00 26S1 Estop" AND "E00 27S5 Estop"; |
|
|
|
Netzwerk 3: Call faults monitoring #FLT(FLT_MODULE := #M00.FLT_PlantIS); |
|
|
|
Netzwerk 4: Evaluate plant failure #M00.FLT_CmpltMaIS := #M00.FLT_PlantIS OR "DI MAIN P03".M00.FLT_ModuleIS OR "DI MAIN P02".M00.FLT_ModuleIS; IF #M00.FLT_CmpltMaIS THEN #M00.FLT_CmpltMaSR := TRUE; END_IF; IF #M00.FLT_CmpltMaSR AND NOT #M00.FLT_CmpltMaACK THEN IF #M00.FLT_CmpltMaACK_Imp THEN #M00.FLT_CmpltMaACK := TRUE; END_IF; ELSIF NOT #M00.FLT_CmpltMaIS AND #M00.FLT_CmpltMaACK THEN #M00.FLT_CmpltMaSR := #M00.FLT_CmpltMaACK := FALSE; END_IF; |
|
|
|
Netzwerk 5: Assign signal light column (modular signal tower) complete machine #M00.SLC_Lamp_RD := #M00.FLT_CmpltMaSR AND NOT #M00.FLT_CmpltMaACK AND "M00_Clock_1Hz" OR #M00.FLT_CmpltMaSR AND #M00.FLT_CmpltMaACK; #M00.SLC_Lamp_GN := NOT (#M00.FLT_CmpltMaSR OR #M00.AutoCmpltMa_run OR #M00.ManuCmpltMa_run) AND (#M00.AutoCmpltMa_run OR #M00.InchCmpltMa_run AND "M00_Clock_1Hz"); #M00.SLC_Lamp_YE := #M00.ManuCmpltMa_run; //AND "M00 Clock_1Hz" OR NOT P00.AutoCmpltMa_run AND NOT P00.ManuCmpltMa_run; |
|
|
|
Netzwerk 6: Query plant at home position #M00.HomPosAll := "DI MAIN P03".M00.HomPosIS AND "DI MAIN P02".M00.HomPosIS; IF #M00.HomPosAll THEN #M00.HomPosSR := TRUE; END_IF; |
|
|
|
Netzwerk 7: Start operating mode AUTOMATIC IF "HMI KEY".P00.GLB.F3_OM_AUTO_ON AND #M00.HomPosSR THEN #M00.OM_AUTO_ON := TRUE; #M00.OM_MANUAL_ON := #M00.OM_HOME_POS_ON := #M00.OM_INCHING_ON := #M00.ManuCmpltMa_run := #M00.InchCmpltMa_run := FALSE; ELSIF #M00.OM_AUTO_ON AND "HMI KEY".P00.GLB.F5_Start THEN #M00.AutoCmpltMa_run := TRUE; END_IF; |
|
|
|
Netzwerk 8: Start operating mode INCHING IF "HMI KEY".P00.GLB.F15_OM_INCHING_ON AND #M00.HomPosSR THEN #M00.OM_INCHING_ON := TRUE; #M00.OM_MANUAL_ON := #M00.OM_HOME_POS_ON := #M00.OM_AUTO_ON := #M00.ManuCmpltMa_run := #M00.AutoCmpltMa_run := FALSE; ELSIF #M00.OM_INCHING_ON AND "HMI KEY".P00.GLB.F5_Start THEN #M00.InchCmpltMa_run := TRUE; END_IF; |
|
|
|
Netzwerk 9: Start operating mode MANUAL IF "HMI KEY".P00.GLB.F4_OM_MANU_ON AND NOT #SET.SSM.S.steps THEN #M00.OM_MANUAL_ON := TRUE; #M00.OM_HOME_POS_ON := #M00.OM_AUTO_ON := #M00.OM_INCHING_ON := #M00.AutoCmpltMa_run := #M00.InchCmpltMa_run := FALSE; ELSIF #M00.OM_MANUAL_ON AND "HMI KEY".P00.GLB.F5_Start THEN #M00.ManuCmpltMa_run := TRUE; END_IF; |
|
|
|
Netzwerk 10: Start home position SET entire plant IF "HMI KEY".P00.GLB.F7_OM_HOM_POS_ON THEN #M00.OM_HOME_POS_ON := TRUE; #M00.OM_AUTO_ON := #M00.OM_MANUAL_ON := #M00.OM_INCHING_ON := #M00.AutoCmpltMa_run := #M00.ManuCmpltMa_run := #M00.InchCmpltMa_run := FALSE; ELSIF #M00.OM_HOME_POS_ON AND NOT #M00.FLT_CmpltMaSR AND "HMI KEY".P00.GLB.F5_Start THEN #SET.SSM.S.steps := TRUE; #M00.HomPosSR := FALSE; END_IF; IF NOT #M00.OM_HOME_POS_ON OR "HMI KEY".P00.GLB.F8_Stop THEN #SET.SSM.S.steps := FALSE; END_IF; #M00.Busy := #SET.SSM.S.steps; #SET.SSM.S.steph := #M00.FLT_CmpltMaSR;
#SET(); |
|
|
|
Netzwerk 11: STOP all operating mode #tmp_llo := (#M00.AutoCmpltMa_run OR #M00.ManuCmpltMa_run OR #M00.InchCmpltMa_run) AND "HMI KEY".P00.GLB.F8_Stop;
IF #tmp_llo OR #M00.FLT_CmpltMaSR THEN #M00.AutoCmpltMa_run := #M00.InchCmpltMa_run := FALSE; END_IF; IF #tmp_llo THEN #M00.ManuCmpltMa_run := FALSE; END_IF; |
|
|
|
Netzwerk 12: Create pulse-OFF entire plant #tmp_llo := #M00.ManuCmpltMa_run OR #M00.AutoCmpltMa_run OR #M00.InchCmpltMa_run OR #SET.SSM.S.steps; #M00.CmpltMaOFF_Imp := NOT #tmp_llo AND #M00.CmpltMaOFF_FEg; #M00.CmpltMaOFF_FEg := #tmp_llo; #M00.TOF_CmpltMaOFF_Pulse(IN := #M00.CmpltMaOFF_Imp, PT := t#500ms); |
|
|
|
Netzwerk 13: Create Impulse-running entire plant #tmp_llo := #M00.AutoCmpltMa_run OR #M00.ManuCmpltMa_run OR #SET.SSM.S.steps OR #M00.InchCmpltMa_run; #M00.CmpltMaRun_Imp := NOT #M00.CmpltMaRun_REg AND #tmp_llo; #M00.CmpltMaRun_REg := #tmp_llo; |
|
|
|
Netzwerk 14: Show key colour on HMI "HMI KEY".P00.GLB.F11_Show_KeyColour_Start_Stop := #M00.AutoCmpltMa_run OR #M00.ManuCmpltMa_run OR #M00.InchCmpltMa_run OR #SET.SSM.S.steps; "HMI KEY".P00.GLB.F14_Show_Key_Start_Stop := #M00.OM_AUTO_ON OR #M00.OM_MANUAL_ON OR #M00.OM_HOME_POS_ON OR #M00.OM_INCHING_ON; |
|
|
|
Netzwerk 15: enable running homing entire plant #M00.Enabled := #M00.OM_HOME_POS_ON AND NOT #M00.FLT_CmpltMaSR; |
|
|
|
Netzwerk 16: Log In 'mc@cea2020' IF "HMI SYS".Login.Operator_0.ID = "HMI SYS".Login.Admin.ID THEN "HMI SYS".Login.Operator_0.Initials := "HMI SYS".Login.Admin.Initials; #M00.LogInID_CEA := #M00.LogInID_OK := TRUE; ELSIF "HMI SYS".Login.Operator_0.ID = "HMI SYS".Login.Operator_1.ID THEN "HMI SYS".Login.Operator_0.Initials := "HMI SYS".Login.Operator_1.Initials; #M00.LogInID_OK := TRUE; #M00.LogInID_CEA := FALSE; ELSIF "HMI SYS".Login.Operator_0.ID = "HMI SYS".Login.Operator_2.ID THEN "HMI SYS".Login.Operator_0.Initials := "HMI SYS".Login.Operator_2.Initials; #M00.LogInID_OK := TRUE; #M00.LogInID_CEA := FALSE; ELSE #M00.LogInID_CEA := #M00.LogInID_OK := FALSE; END_IF; IF NOT #M00.LogInID_OK THEN "HMI SYS".Login.Operator_0.Initials := ''; END_IF; #M00.TON_Login(IN := #M00.LogInID_CEA, PT := #M00.TON_Login.PT); IF #M00.TON_Login.Q THEN "HMI SYS".Login.Operator_0.ID := ''; END_IF; |
|
|
|
Netzwerk 17: Reset Scanned BoxData #M00.ProductCounter.DlyOnReset(IN := "HMI KEY".P00.GLB.F23_Execute, PT := t#2s); IF #M00.ProductCounter.DlyOnReset.Q THEN "DI OUT P03".HBS1_Box_Data := "DI OUT P03".M302_Box_Data := "DI OUT P03".M303_Box_Data := "DI OUT P03".M304_Box_Data := "DI OUT P03".M305_Box_Data := "DI OUT P03".HBS2_Box_Data := "DI MAIN P03".SEQ1.SCANNER_ET200SP.Scanned_BoxData_A := "DI MAIN P03".SEQ1.SCANNER_ET200SP.Scanned_BoxData_B := "DI MAIN P03".SEQ1.SCANNER_ET200SP.Scanned_BoxData_C := "DI MAIN P03".SEQ1.SCANNER_ET200SP.Scanned_BoxData_D := #tmp_del_box_data; END_IF; |
|