First fix for Kuka robot
- Added test at end of Execute if job finished without errors - Added test during starting if robot errors are still present
This commit is contained in:
@@ -291,7 +291,14 @@ END_IF
|
|||||||
// Wait for robot to be done
|
// Wait for robot to be done
|
||||||
IF awJobStatesFromRobot[0] = 0 THEN
|
IF awJobStatesFromRobot[0] = 0 THEN
|
||||||
stJobs.wJobNrForRobot := E_KukaRobot_JobNumberRobot.NO_JOB;
|
stJobs.wJobNrForRobot := E_KukaRobot_JobNumberRobot.NO_JOB;
|
||||||
_eCmd := E_PackMLCmd.COMPLETE;
|
|
||||||
|
// Job finished without errors
|
||||||
|
IF (dwErrorBits = 0) THEN
|
||||||
|
M_CmdComplete();
|
||||||
|
ELSE
|
||||||
|
M_CmdAbort();
|
||||||
|
END_IF
|
||||||
|
|
||||||
END_IF
|
END_IF
|
||||||
END_CASE
|
END_CASE
|
||||||
|
|
||||||
@@ -356,7 +363,8 @@ END_IF
|
|||||||
<Declaration><![CDATA[METHOD PROTECTED M_Idle
|
<Declaration><![CDATA[METHOD PROTECTED M_Idle
|
||||||
]]></Declaration>
|
]]></Declaration>
|
||||||
<Implementation>
|
<Implementation>
|
||||||
<ST><![CDATA[_stJobParams := stHMIInterface.stJobParams;]]></ST>
|
<ST><![CDATA[{warning disable C0371}
|
||||||
|
_stJobParams := stHMIInterface.stJobParams;]]></ST>
|
||||||
</Implementation>
|
</Implementation>
|
||||||
</Method>
|
</Method>
|
||||||
<Method Name="M_Resetting" Id="{dfe4d36a-80aa-4364-bfd8-6ddd41636d59}" FolderPath="StateMachine\">
|
<Method Name="M_Resetting" Id="{dfe4d36a-80aa-4364-bfd8-6ddd41636d59}" FolderPath="StateMachine\">
|
||||||
@@ -435,7 +443,7 @@ CASE _iSSM OF
|
|||||||
_eCmd := E_PackMLCmd.ABORT;
|
_eCmd := E_PackMLCmd.ABORT;
|
||||||
END_IF
|
END_IF
|
||||||
|
|
||||||
IF stState.bProAct THEN
|
IF stState.bProAct AND (dwErrorBits = 0) THEN
|
||||||
stCtrl.bExtStart := 0;
|
stCtrl.bExtStart := 0;
|
||||||
_tonTimeout(IN := FALSE);
|
_tonTimeout(IN := FALSE);
|
||||||
M_StateComplete();
|
M_StateComplete();
|
||||||
|
|||||||
Reference in New Issue
Block a user