From f0c708f3f1a0e1f2bd0f093dbed34567f03795a8 Mon Sep 17 00:00:00 2001 From: Dario Sassi Date: Sat, 15 Feb 2020 10:04:03 +0000 Subject: [PATCH] DataBeam : - migliorie gestione massimo affondamento frese - miglioria ingombro tagli in testa o coda. --- LuaLibs/BeamExec.lua | 5 +++-- LuaLibs/MachiningLib.lua | 2 +- LuaLibs/ProcessCut.lua | 6 +++--- LuaLibs/ProcessLapJoint.lua | 2 +- LuaLibs/ProcessMortise.lua | 9 +++++---- 5 files changed, 13 insertions(+), 11 deletions(-) diff --git a/LuaLibs/BeamExec.lua b/LuaLibs/BeamExec.lua index 88d732d..422c072 100644 --- a/LuaLibs/BeamExec.lua +++ b/LuaLibs/BeamExec.lua @@ -1,4 +1,4 @@ --- BeamExec.lua by Egaltech s.r.l. 2020/01/28 +-- BeamExec.lua by Egaltech s.r.l. 2020/02/14 -- Libreria esecuzione lavorazioni per Travi -- 2019/07/11 Aggiunta gestione stato rotazione di feature per TS3. -- 2019/09/04 Corretto controllo feature di testa e coda con sovramateriale di testa elevato. @@ -95,7 +95,8 @@ _G.package.loaded.ProcessDecor = nil local Decor = require( 'ProcessDecor') EgtOutLog( ' BeamExec started', 1) - +EgtMdbSetGeneralParam( MCH_GP.MAXDEPTHSAFE, BD.COLL_SIC) +EgtMdbSave() ------------------------------------------------------------------------------------------------------------- -- *** Inserimento delle travi nel grezzo *** diff --git a/LuaLibs/MachiningLib.lua b/LuaLibs/MachiningLib.lua index 8159585..1dd8674 100644 --- a/LuaLibs/MachiningLib.lua +++ b/LuaLibs/MachiningLib.lua @@ -1,4 +1,4 @@ --- MachiningLib.lua by Egaltech s.r.l. 2019/10/07 +-- MachiningLib.lua by Egaltech s.r.l. 2020/02/14 -- Libreria ricerca lavorazioni per Travi -- Tabella per definizione modulo diff --git a/LuaLibs/ProcessCut.lua b/LuaLibs/ProcessCut.lua index a2b2085..c5c27fb 100644 --- a/LuaLibs/ProcessCut.lua +++ b/LuaLibs/ProcessCut.lua @@ -1,4 +1,4 @@ --- ProcessCut.lua by Egaltech s.r.l. 2020/01/07 +-- ProcessCut.lua by Egaltech s.r.l. 2020/02/14 -- Gestione calcolo singoli tagli di lama per Travi -- Tabella per definizione modulo @@ -187,13 +187,13 @@ function ProcessCut.Make( Proc, nPhase, nRawId, nPartId, dOvmHead, bFromBottom) if Proc.Head then local dOffs = b3Raw:getMax():getX() - dOvmHead - Proc.Box:getMin():getX() if abs( vtN:getZ()) > 0.5 then - dOffs = 0.4 * dOffs + dOffs = dOffs - 0.6 * Proc.Box:getDimX() end BL.UpdateHCING( nRawId, dOffs) elseif Proc.Tail then local dOffs = Proc.Box:getMax():getX() - b3Solid:getMin():getX() if abs( vtN:getZ()) > 0.5 then - dOffs = 0.4 * dOffs + dOffs = dOffs - 0.6 * Proc.Box:getDimX() end BL.UpdateTCING( nRawId, dOffs) end diff --git a/LuaLibs/ProcessLapJoint.lua b/LuaLibs/ProcessLapJoint.lua index cc8314b..4fb128e 100644 --- a/LuaLibs/ProcessLapJoint.lua +++ b/LuaLibs/ProcessLapJoint.lua @@ -881,7 +881,7 @@ local function MakeMoreFaces( Proc, nPhase, nRawId, nPartId) if Proc.Fct < 3 or bIsU then sMchFind = 'OpenPocket' end local dDiam = min( dH, dV) local dCollSic = 2 * BD.COLL_SIC - if abs( vtN:getX()) > 0.996 or abs( vtN:getY()) > 0.996 or abs( vtN:getZ()) > 0.996 then dCollSic = BD.COLL_SIC end + if abs( vtN:getX()) > 0.996 or abs( vtN:getY()) > 0.996 or abs( vtN:getZ()) > 0.996 then dCollSic = 0 end --EgtOutLog( 'Mortise Find Diam =' .. EgtNumToString( dDiam)) local sPocketing = ML.FindPocketing( sMchFind, dDiam, dFacElev + dCollSic) -- se non trova una svuotatura adatta diff --git a/LuaLibs/ProcessMortise.lua b/LuaLibs/ProcessMortise.lua index a1825d6..76b2990 100644 --- a/LuaLibs/ProcessMortise.lua +++ b/LuaLibs/ProcessMortise.lua @@ -196,8 +196,9 @@ function ProcessMortise.Make( Proc, nPhase, nRawId, nPartId) -- se elevazione superiore a massimo affondamento della fresa, riduco opportunamente if dMorH > dMaxDepth + 10 * GEO.EPS_SMALL then sWarn = 'Warning in mortise : elevation (' .. EgtNumToString( dMorH,1) .. ') bigger than max tool depth (' .. EgtNumToString( dMaxDepth,1) .. ')' - if not bRevertSide then -- se non ho invertito la direzione di estrusione - nDepthMin = dMaxDepth - EgtIf( bNotExistBtm and not bForceOneSide, dMorH*2, dMorH) + -- se non ho invertito la direzione di estrusione + if not bRevertSide then + nDepthMin = dMaxDepth - EgtIf( bNotExistBtm and not bForceOneSide, dMorH * 2, dMorH) else nDepthMin = dMaxDepth end @@ -243,10 +244,10 @@ function ProcessMortise.Make( Proc, nPhase, nRawId, nPartId) EgtSetMachiningParam( MCH_MP.SCC, MCH_SCC.ADIR_YM) end -- se altezza mortasa differente da altezza massima lavorabile - if abs(dMorH - dMaxDepth) > GEO.EPS_SMALL then + if abs( dMorH - dMaxDepth) > GEO.EPS_SMALL then nDepthMin = -dMorH else -- se sono uguali setto - nDepthMin = -(dMorH - BD.CUT_EXTRA) + nDepthMin = -( dMorH - BD.CUT_EXTRA) end -- setto profondità