DataBeam :
- in Process Cut aumentato angolo da sotto con FAST - in Process LapJoint corretto caso con due facce che non è un LongDoubleCut ma che veniva identificato come tale - in Process LongDoubleCut migliorato controllo lunghezze di lavorazione con fresa quando divisa in due parti.
This commit is contained in:
@@ -236,7 +236,7 @@ local function MakeFromTop( sCutting, Proc, nPhase, nRawId, nPartId, dOvmHead, b
|
||||
local ptC, vtN = EgtSurfTmFacetCenter( Proc.Id, 0, GDB_ID.ROOT)
|
||||
-- limiti di taglio (se molto di lato e inclinati sono permessi fino a -45deg)
|
||||
local dNzLimDwnUp = BL.GetNzLimDownUp( b3Raw)
|
||||
if not BD.C_SIMM and abs( vtN:getX()) < 0.5 then dNzLimDwnUp = -0.707 end
|
||||
if not BD.C_SIMM and abs( vtN:getY()) > 0.25 then dNzLimDwnUp = -0.708 end
|
||||
local bDownCut = ( vtN:getZ() <= dNzLimDwnUp)
|
||||
if bFromBottom == nil then
|
||||
bFromBottom = ( vtN:getZ() > 0.25 and b3Solid:getDimX() < BD.LEN_SHORT_PART and not Proc.AdvTail and vtN:getX() < 0)
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
-- ProcessLapJoint.lua by Egaltech s.r.l. 2022/01/26
|
||||
-- ProcessLapJoint.lua by Egaltech s.r.l. 2022/02/07
|
||||
-- Gestione calcolo mezzo-legno per Travi
|
||||
-- 2019/10/08 Agg. gestione OpenPocket.
|
||||
-- 2021/01/24 Con sega a catena ora sempre impostato asse A.
|
||||
@@ -34,6 +34,7 @@
|
||||
-- 2021/11/22 Corretta segnalazione warning su foro di L20 e L25.
|
||||
-- 2022/01/19 Cambiata % lunghezza pezzo per spezzatura. Tolta correzione spessore fresa a disco con superficie da lavorare verso Z-.
|
||||
-- 2022/01/26 Migliorato controllo uso testa da sotto nel caso due facce con lama.
|
||||
-- 2022/02/07 Corretto caso con due facce che non è un LongDoubleCut ma che veniva identificato come tale.
|
||||
|
||||
-- Tabella per definizione modulo
|
||||
local ProcessLapJoint = {}
|
||||
@@ -5426,7 +5427,7 @@ function ProcessLapJoint.Make( Proc, nPhase, nRawId, nPartId, dOvmHead)
|
||||
-- determino se due facce lunghe oppure una lunga e l'altra terminale
|
||||
local b3Fac1 = EgtSurfTmGetFacetBBoxGlob( Proc.Id, 0, GDB_BB.STANDARD)
|
||||
local b3Fac2 = EgtSurfTmGetFacetBBoxGlob( Proc.Id, 1, GDB_BB.STANDARD)
|
||||
if abs( b3Fac1:getDimX() - b3Fac2:getDimX()) < 50 then
|
||||
if abs( b3Fac1:getDimX() - b3Fac2:getDimX()) < 50 and abs( b3Fac1:getCenter():getX() - b3Fac2:getCenter():getX()) < 50 then
|
||||
-- leggo i parametri Q per utilizzare la fresa di fianco e/o lama
|
||||
local nUseSideTool = EgtGetInfo( Proc.Id, Q_SIDE_ROUGH_TOOL, 'i') or 0
|
||||
local bUseBlade = EgtGetInfo( Proc.Id, Q_ANTISPLINT_TYPE, 'i') == 1
|
||||
@@ -5502,8 +5503,11 @@ function ProcessLapJoint.Make( Proc, nPhase, nRawId, nPartId, dOvmHead)
|
||||
end
|
||||
-- due facce
|
||||
elseif Proc.Fct == 2 then
|
||||
-- se praticamente è lunga come la trave
|
||||
if Proc.Box:getDimX() > 0.8 * b3Solid:getDimX() then
|
||||
-- se praticamente è lunga come la trave e sono due facce lunghe
|
||||
local b3Fac1 = EgtSurfTmGetFacetBBoxGlob( Proc.Id, 0, GDB_BB.STANDARD)
|
||||
local b3Fac2 = EgtSurfTmGetFacetBBoxGlob( Proc.Id, 1, GDB_BB.STANDARD)
|
||||
if Proc.Box:getDimX() > 0.8 * b3Solid:getDimX() and
|
||||
abs( b3Fac1:getDimX() - b3Fac2:getDimX()) < 50 and abs( b3Fac1:getCenter():getX() - b3Fac2:getCenter():getX()) < 50 then
|
||||
local nUseSideTool = EgtGetInfo( Proc.Id, Q_SIDE_ROUGH_TOOL, 'i') or 0
|
||||
return Long2Cut.Make( Proc, nPhase, nRawId, nPartId, bUseBlade, nUseSideTool)
|
||||
-- altrimenti
|
||||
|
||||
@@ -1,9 +1,10 @@
|
||||
-- ProcessLongDoubleCut.lua by Egaltech s.r.l. 2021/11/08
|
||||
-- ProcessLongDoubleCut.lua by Egaltech s.r.l. 2022/02/08
|
||||
-- Gestione calcolo doppio taglio longitudinale per Travi
|
||||
-- 2021/05/18 Possibile taglio con lama anche di fianco su macchina con testa da sotto.
|
||||
-- 2021/06/29 Corretta gestione caso equivalente a due smussi.
|
||||
-- 2021/10/29 Aggiunta opzione tipo lavorazione 'LongCut'.
|
||||
-- 2021/11/08 Se con lama e flag BD.USE_LONGCUT si lavora in direzione contraria allo standard.
|
||||
-- 2022/02/08 Sistemate lunghezze fresature quando due sole.
|
||||
|
||||
-- Tabella per definizione modulo
|
||||
local ProcessLong2Cut = {}
|
||||
@@ -381,7 +382,6 @@ function ProcessLong2Cut.Make( Proc, nPhase, nRawId, nPartId, bForcedBladeMaster
|
||||
end
|
||||
|
||||
-- Se senza facce limitanti, da sopra o ( da tutte i lati con testa da sotto) e taglio di lama e lunghezza facce maggiore del parametro lunghezza minima
|
||||
-- if nFaceLimit == 0 and ( nSide == 1 or ( abs(nSide) >= 0 and BD.DOWN_HEAD)) and bUseBlade and Proc.Box:getDimX() > dLimMinPiece - 1 then
|
||||
if nFaceLimit == 0 and ( bCanUseUnderBlade or bCanUseBlade) and bUseBlade and Proc.Box:getDimX() > dLimMinPiece - 1 then
|
||||
|
||||
local sCutting
|
||||
@@ -503,8 +503,7 @@ function ProcessLong2Cut.Make( Proc, nPhase, nRawId, nPartId, bForcedBladeMaster
|
||||
dC = dCDn
|
||||
end
|
||||
|
||||
-- disabilitato la selezione del codolo, prende sempre quello più piccolo. Non cancellare quello disabiliato in caso di ripristino
|
||||
-- local dDimStrip = EgtIf( nSide ~= 0, BD.DIM_STRIP_SMALL, BD.DIM_STRIP)
|
||||
-- uso codolo piccolo
|
||||
local dDimStrip = BD.DIM_STRIP_SMALL * EgtIf( nSide == -1, -1, 1)
|
||||
local nM = 0
|
||||
-- se convesso lavoro ogni faccia in due metà lasciando attaccata la parte centrale
|
||||
@@ -572,7 +571,6 @@ function ProcessLong2Cut.Make( Proc, nPhase, nRawId, nPartId, bForcedBladeMaster
|
||||
local nMchFId
|
||||
local sCuttingName
|
||||
local bMachDown
|
||||
-- if ( k == 1 and bCanUseBlade) or ( k == 2 and ( bCanUseBlade and not bCanUseUnderBlade)) then
|
||||
if bCanUseBlade and not bCanUseUnderBlade then
|
||||
sNameF = 'L2C_' .. ( EgtGetName( Proc.Id) or tostring( Proc.Id)) .. '_' .. tostring(j) .. '_' .. tostring( nM)
|
||||
nMchFId = EgtAddMachining( sNameF, sCutting)
|
||||
@@ -580,7 +578,6 @@ function ProcessLong2Cut.Make( Proc, nPhase, nRawId, nPartId, bForcedBladeMaster
|
||||
-- setto le variabili delle distanze dagli estremi
|
||||
dEndAccDist = dEndAccDistUp
|
||||
dStartAccDist = dStartAccDistUp
|
||||
-- elseif ( k == 2 and bCanUseUnderBlade) or ( k == 1 and ( bCanUseUnderBlade and not bCanUseBlade)) then
|
||||
elseif bCanUseUnderBlade and not bCanUseBlade then
|
||||
sNameF = 'L2CD_' .. ( EgtGetName( Proc.Id) or tostring( Proc.Id)) .. '_' .. tostring(j) .. '_' .. tostring( nM)
|
||||
nMchFId = EgtAddMachining( sNameF, sCuttingDn)
|
||||
@@ -947,10 +944,10 @@ function ProcessLong2Cut.Make( Proc, nPhase, nRawId, nPartId, bForcedBladeMaster
|
||||
local nIncStep = 2
|
||||
if bStartFixed and bEndFixed then
|
||||
dC = ( dLen - dStartAccDist - dEndAccDist) / nC
|
||||
-- se distanza rimanente è < della metà del minimo della distanza estremi allora aggiungo un passo in più
|
||||
-- se distanza rimanente è < della metà del minimo della distanza estremi allora aggiungo un solo passo in più
|
||||
local dMinDist = EgtIf( min( dStartAccDist, dEndAccDist) / 2 > 300 , 300, min( dStartAccDist, dEndAccDist) / 2)
|
||||
if dC < dMinDist then
|
||||
dC = dLen / ( nC + 2)
|
||||
dC = dLen / ( nC + 1)
|
||||
dStartAccDist = dC
|
||||
dEndAccDist = dC
|
||||
nIncStep = 1
|
||||
@@ -1263,20 +1260,43 @@ function ProcessLong2Cut.Make( Proc, nPhase, nRawId, nPartId, bForcedBladeMaster
|
||||
local nC = ceil( ( dLen - dStartAccDist - dEndAccDist) / BD.LONGCUT_MAXLEN)
|
||||
local dC = 0
|
||||
if nC > 0 then
|
||||
local nIncStep = 2
|
||||
if bStartFixed and bEndFixed then
|
||||
dC = ( dLen - dStartAccDist - dEndAccDist) / nC
|
||||
-- se distanza rimanente è < della metà del minimo della distanza estremi allora aggiungo un solo passo in più
|
||||
local dMinDist = EgtIf( min( dStartAccDist, dEndAccDist) / 2 > 300 , 300, min( dStartAccDist, dEndAccDist) / 2)
|
||||
if dC < dMinDist then
|
||||
dC = dLen / ( nC + 1)
|
||||
dStartAccDist = dC
|
||||
dEndAccDist = dC
|
||||
nIncStep = 1
|
||||
elseif dC < min( dStartAccDist, dEndAccDist) then
|
||||
dC = dLen / ( nC + 2)
|
||||
dStartAccDist = dC
|
||||
dEndAccDist = dC
|
||||
end
|
||||
elseif bStartFixed then
|
||||
dC = ( dLen - dStartAccDist) / ( nC + 1)
|
||||
dEndAccDist = dC
|
||||
if dC < dStartAccDist then
|
||||
dC = dLen / ( nC + 2)
|
||||
dStartAccDist = dC
|
||||
dEndAccDist = dC
|
||||
end
|
||||
elseif bEndFixed then
|
||||
dC = ( dLen - dEndAccDist) / ( nC + 1)
|
||||
dStartAccDist = dC
|
||||
if dC < dEndAccDist then
|
||||
dC = dLen / ( nC + 2)
|
||||
dStartAccDist = dC
|
||||
dEndAccDist = dC
|
||||
end
|
||||
else
|
||||
dC = dLen / ( nC + 2)
|
||||
dStartAccDist = dC
|
||||
dEndAccDist = dC
|
||||
end
|
||||
nC = nC + 2
|
||||
nC = nC + nIncStep
|
||||
else
|
||||
if dLen > min( dStartAccDist, dEndAccDist) then
|
||||
nC = 2
|
||||
|
||||
Reference in New Issue
Block a user