Initial commit
This commit is contained in:
79
TC3_CNCPLCBase/OEM/PRG_Safety.TcPOU
Normal file
79
TC3_CNCPLCBase/OEM/PRG_Safety.TcPOU
Normal file
@@ -0,0 +1,79 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<TcPlcObject Version="1.1.0.1" ProductVersion="3.1.4024.6">
|
||||
<POU Name="PRG_Safety" Id="{fb0a2b6b-e6cb-460c-a9a1-e601b08f918a}" SpecialFunc="None">
|
||||
<Declaration><![CDATA[PROGRAM PRG_Safety
|
||||
VAR
|
||||
bRun AT %Q* : BOOL := TRUE;
|
||||
bReset AT %Q* : BOOL;
|
||||
bErrorAck AT %Q* : BOOL;
|
||||
|
||||
bFallNummerBit0 AT %Q* : BOOL;
|
||||
|
||||
bSiemensReset AT %Q* : BOOL;
|
||||
|
||||
bEStop AT %I* : BOOL;
|
||||
bLSStop AT %I* : BOOL;
|
||||
bLSReducedSpeed AT %I* : BOOL;
|
||||
|
||||
bTest : BOOL;
|
||||
|
||||
tofErrorAck : TOF;
|
||||
END_VAR
|
||||
]]></Declaration>
|
||||
<Implementation>
|
||||
<ST><![CDATA[tofErrorAck(IN := PLCReset OR bTest, PT := T#500MS);
|
||||
bFallNummerBit0 := TRUE;
|
||||
|
||||
// Nothalt Kanal
|
||||
gpCh[0]^.bahn_mc_control.emergency_stop.enable_w :=TRUE;
|
||||
gpCh[0]^.bahn_mc_control.emergency_stop.command_w := NOT bEStop;
|
||||
|
||||
// Nothalt Spindel
|
||||
gpAx[4]^.ipo_mc_control.emergency_stop.enable_w := TRUE;
|
||||
gpAx[4]^.ipo_mc_control.emergency_stop.command_w := NOT bEStop;
|
||||
|
||||
// Feedhold Laserscanner
|
||||
gpCh[0]^.bahn_mc_control.e_feedhold.enable_w := TRUE;
|
||||
gpCh[0]^.bahn_mc_control.e_feedhold.command_w := NOT bLSStop;
|
||||
|
||||
// Reduzierte Geschwindigkeit Laserscanner
|
||||
gpCh[0]^.bahn_mc_control.reduced_speed.enable_w := TRUE;
|
||||
gpCh[0]^.bahn_mc_control.reduced_speed.command_w := NOT bLSReducedSpeed;
|
||||
|
||||
//bErrorAck := tofErrorAck.Q;
|
||||
bSiemensReset := tofErrorAck.Q;
|
||||
bReset := tofErrorAck.Q;
|
||||
bErrorAck := tofErrorAck.Q;
|
||||
|
||||
IF bTest THEN
|
||||
bTest := FALSE;
|
||||
END_IF]]></ST>
|
||||
</Implementation>
|
||||
<LineIds Name="PRG_Safety">
|
||||
<LineId Id="25" Count="0" />
|
||||
<LineId Id="45" Count="0" />
|
||||
<LineId Id="65" Count="0" />
|
||||
<LineId Id="63" Count="0" />
|
||||
<LineId Id="62" Count="0" />
|
||||
<LineId Id="66" Count="0" />
|
||||
<LineId Id="69" Count="0" />
|
||||
<LineId Id="68" Count="0" />
|
||||
<LineId Id="70" Count="1" />
|
||||
<LineId Id="89" Count="0" />
|
||||
<LineId Id="88" Count="0" />
|
||||
<LineId Id="118" Count="0" />
|
||||
<LineId Id="90" Count="0" />
|
||||
<LineId Id="114" Count="0" />
|
||||
<LineId Id="113" Count="0" />
|
||||
<LineId Id="115" Count="1" />
|
||||
<LineId Id="24" Count="0" />
|
||||
<LineId Id="9" Count="0" />
|
||||
<LineId Id="28" Count="0" />
|
||||
<LineId Id="11" Count="0" />
|
||||
<LineId Id="67" Count="0" />
|
||||
<LineId Id="109" Count="0" />
|
||||
<LineId Id="108" Count="0" />
|
||||
<LineId Id="110" Count="1" />
|
||||
</LineIds>
|
||||
</POU>
|
||||
</TcPlcObject>
|
||||
Reference in New Issue
Block a user