- Corretto segno coordinata rotazione in sicurezza testa 3
- Testa 3 in home a fine barra - ToolHolders
This commit is contained in:
+17
-3
@@ -1251,6 +1251,8 @@ end
|
||||
|
||||
---------------------------------------------------------------------
|
||||
function OnSimulMoveEnd()
|
||||
-- gruppo della testa
|
||||
local nHSet = GetHeadSet( EMT.HEAD)
|
||||
-- rimozione eventuali sfridi
|
||||
if EMT.FLAG == 301 then
|
||||
ExecRemoveScraps()
|
||||
@@ -1295,8 +1297,12 @@ function OnSimulMoveEnd()
|
||||
if EMT.MOVE == 0 and EMT.FLAG == 3 then
|
||||
-- eventuale rimozione sfridi
|
||||
ExecRemoveScraps()
|
||||
-- ricavo prossimo utensile
|
||||
local sNextTool = GetNextTool( EMT.MCHID)
|
||||
-- vado in home se è ultimo movimento ed è ultima lavorazione
|
||||
local bToXhome = ( IsLastPath( EMT.PATHID) and not sNextTool and nHSet == 3)
|
||||
-- eseguo
|
||||
ExecMoveZmax( EMT.MCHSPLIT)
|
||||
ExecMoveZmax( EMT.MCHSPLIT, bToXhome)
|
||||
EMT.TO_ZMAX = nil
|
||||
end
|
||||
end
|
||||
@@ -1474,7 +1480,7 @@ end
|
||||
---------------------------------------------------------------------
|
||||
function ExecMoveHome( bNearV, bMchSplit)
|
||||
-- risalita a Zmax
|
||||
ExecMoveZmax( bMchSplit)
|
||||
ExecMoveZmax( bMchSplit, true)
|
||||
-- se testa sotto e macchian a 3 teste e gruppo truciolatore a 4 assi
|
||||
if GetHeadSet( EMT.HEAD) == 2 and IsHeadExisting( 3) then
|
||||
if not SimulMoveAxis( 'X2', ParkX2, MCH_SIM_STEP.RAPID) then
|
||||
@@ -1499,7 +1505,7 @@ function ExecMoveHome( bNearV, bMchSplit)
|
||||
end
|
||||
|
||||
---------------------------------------------------------------------
|
||||
function ExecMoveZmax( bMchSplit)
|
||||
function ExecMoveZmax( bMchSplit, bGoToHome)
|
||||
-- set della testa
|
||||
local nSetHead = GetHeadSet( EMT.HEAD)
|
||||
-- posizioni correnti degli assi testa
|
||||
@@ -1586,6 +1592,9 @@ function ExecMoveZmax( bMchSplit)
|
||||
SimulMoveAxes( 'C3', HomeC, MCH_SIM_STEP.COLLROT, 'B3', HomeB, MCH_SIM_STEP.COLLROT)
|
||||
end
|
||||
SimulMoveAxis( 'Z3', MyMaxZ3, MCH_SIM_STEP.RAPID)
|
||||
if bGoToHome then
|
||||
SimulMoveAxis( 'X3', ParkX3, MCH_SIM_STEP.RAPID)
|
||||
end
|
||||
else
|
||||
EmtSetLastError( 1212, "HEAD not managed")
|
||||
end
|
||||
@@ -2645,6 +2654,11 @@ function GetStartMachiningXaxis( nMchId)
|
||||
end
|
||||
end
|
||||
|
||||
---------------------------------------------------------------------
|
||||
function IsLastPath( nPathId)
|
||||
return not EgtGetNext( nPathId)
|
||||
end
|
||||
|
||||
---------------------------------------------------------------------
|
||||
function RollerParkingNeeded( sHead, dAng1p, dAng2p, dAng1, dAng2)
|
||||
if sHead == 'H11' or sHead == 'H12' or sHead == 'H13' or sHead == 'H16' then
|
||||
|
||||
Reference in New Issue
Block a user