DataWall :

- sistemazione varie per macchina NZ.
This commit is contained in:
DarioS
2021-04-29 09:02:35 +02:00
parent 1a658822fe
commit 903638adea
7 changed files with 77 additions and 12 deletions
+20 -2
View File
@@ -1187,6 +1187,7 @@ local function AddMillings( sMilling, vFace, Proc, nRawId, b3Raw, nConeCut, nAdd
dOriDepth = dDepth
-- lo limito e tolgo eventuali Tabs
dDepth = dMaxDepth
if abs( vFace[i].SideAng) > 15 then dDepth = dDepth - 20 end
EgtSetMachiningParam( MCH_MP.LEAVETAB, false)
bNotThrou = true
end
@@ -1212,6 +1213,15 @@ local function AddMillings( sMilling, vFace, Proc, nRawId, b3Raw, nConeCut, nAdd
if #vFace == 1 then
dSal = -dMillDiam / 2
dEal = -dMillDiam / 2
-- se lavorazione completa su faccia singola
elseif vFace[OrigI].Type == 4 then
if vFace[OrigI].PrevAng < -30 then
dSal = -dMillDiam / 2
end
local OrigK = EgtIf( OrigI < #vFace, OrigI + 1, EgtIf( bClosed, 1, nil))
if OrigK and vFace[OrigK].PrevAng < -30 then
dEal = -dMillDiam / 2
end
end
-- se non devo scaricare l'angolo
if nConeCut <= 1 then
@@ -1571,8 +1581,8 @@ local function MakeByCut( Proc, nRawId, b3Raw)
local vtExtr= EgtCurveExtrusion( AuxId, GDB_RT.GLOB)
if vtExtr then
bOpposite = ( Proc.Grp == 4 and vtExtr:getZ() < 0) or ( Proc.Grp == 3 and vtExtr:getZ() > 0)
if vtExtr:getZ() < 0 then bNegZ = true end
end
if vtExtr:getZ() < 0 then bNegZ = true end
end
-- altezza massima delle facce
local dWidth = 0
@@ -1597,11 +1607,19 @@ local function MakeByCut( Proc, nRawId, b3Raw)
-- inserimento dei tagli di lama
local bCtOk, sCtErr = AddCuts( sCutting, vFace, Proc, nRawId, b3Raw, dSawThick)
if not bCtOk then return bCtOk, sCtErr end
-- se ci sono facce inclinate, escludo la sega a catena
local bSlanting = false
for i = 1, #vFace do
if abs( vFace[i].Norm:getZ()) > 0.01 then
bSlanting = true
break
end
end
-- recupero la lavorazione con sega a catena
local sSawing = WM.FindSawing( 'Sawing')
-- recupero la lavorazione di fresatura
local sMilling, dMillMaxDepth = WM.FindMilling( 'FreeContour', dMaxWidth + WD.CUT_EXTRA)
if not sMilling and not sSawing then
if not sMilling and ( not sSawing or bSlanting) then
sMilling = WM.FindMilling( 'FreeContour')
if not sMilling then
local sErr = 'Error : milling not found in library'