From a6a61a8980b1973e38e18b94b6a409cc7d867c5a Mon Sep 17 00:00:00 2001 From: "andrea.villa" Date: Thu, 18 Jun 2026 16:48:11 +0200 Subject: [PATCH] In Drill, gestione delle svuotature in doppio tipo NT --- LuaLibs/ProcessDrill.lua | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/LuaLibs/ProcessDrill.lua b/LuaLibs/ProcessDrill.lua index e344bd3..4d3cd9d 100644 --- a/LuaLibs/ProcessDrill.lua +++ b/LuaLibs/ProcessDrill.lua @@ -348,6 +348,11 @@ function ProcessDrill.Make( Proc, nPhase, nRawId, nPartId, dCurrOvmH) if EgtGetInfo( Proc.Id, 'Q04', 'i') == 1 then return FreeContour.Make( Proc, nPhase, nRawId, nPartId, dCurrOvmH) end + + -- verifico se macchina configurata per avere le nuove svuotature in doppio + local sIniMachFile = EgtGetCurrMachineDir()..'\\'..EgtGetCurrMachineName()..'.ini' + local dPockDoubleNTActive = ( EgtGetStringFromIni( 'Machinings', 'PocketingDoubleNT', '0', sIniMachFile) == '1') + -- default per costanti BD.DRILL_VX_MAX_ANGLEDRILL = ( BD.DRILL_VX_MAX_ANGLEDRILL or 0.928) -- ingombro del pezzo @@ -653,7 +658,7 @@ function ProcessDrill.Make( Proc, nPhase, nRawId, nPartId, dCurrOvmH) local dLastStepDepth if Proc.Double and Proc.Double > 0 then if ( sType == 'Pocket_AT' or sType == 'Pocket') then - if bOpen then + if not dPockDoubleNTActive and bOpen then local dReduceDepth = MIRROR_POCKETS_MIN_DISTANCE / 2 + 10 dLastStepDepth = dDepth + dReduceDepth dDepth = dDepth - dReduceDepth @@ -723,7 +728,7 @@ function ProcessDrill.Make( Proc, nPhase, nRawId, nPartId, dCurrOvmH) return false, sWarn else -- se DrillPocket passante in doppio si fa lavorazione aggiuntiva dell'ultimo step - if Proc.Double and Proc.Double > 0 and ( sType == 'Pocket_AT' or sType == 'Pocket') and bOpen then + if not dPockDoubleNTActive and Proc.Double and Proc.Double > 0 and ( sType == 'Pocket_AT' or sType == 'Pocket') and bOpen then if dLastStepDepth > dMaxDepth + 10 * GEO.EPS_SMALL then sMyWarn = 'Warning in drill pocket last step: depth (' .. EgtNumToString( dLastStepDepth, 1) .. ') bigger than max tool depth (' .. EgtNumToString( dMaxDepth, 1) .. ')' return false, sMyWarn