DataBeam :
- aggiunta gestione scelta utensile in base al raggio in mortase con coda di rondine - corretta gestione estremi di taglio doppio longitudinale.
This commit is contained in:
@@ -1,4 +1,4 @@
|
||||
-- ProcessDtMortise.lua by Egaltech s.r.l. 2020/10/21
|
||||
-- ProcessDtMortise.lua by Egaltech s.r.l. 2020/10/27
|
||||
-- Gestione calcolo mortase a coda di rondine per Travi
|
||||
|
||||
-- Tabella per definizione modulo
|
||||
@@ -159,13 +159,29 @@ function ProcessDtMortise.Make( Proc, nPhase, nRawId, nPartId, dCurrOvmH)
|
||||
if not bOk then return bOk, sErr end
|
||||
end
|
||||
end
|
||||
-- recupero la lavorazione
|
||||
-- recupero il raggio minimo della mortasa
|
||||
local dMinRad = 1000
|
||||
local nSt, nEnd = EgtCurveDomain( AuxId)
|
||||
for i = nSt, nEnd - 1 do
|
||||
local dRad = EgtCurveCompoRadius( AuxId, i)
|
||||
if dRad > 0 and dRad < dMinRad then
|
||||
dMinRad = dRad
|
||||
end
|
||||
end
|
||||
-- recupero la lavorazione : prima ricerca per sola tipologia
|
||||
local sMilling = ML.FindMilling( 'DtMortise')
|
||||
if not sMilling then
|
||||
local sErr = 'Milling not found in library : Error on DtMortise ' .. tostring( Proc.Id)
|
||||
EgtOutLog( sErr)
|
||||
return false, sErr
|
||||
end
|
||||
-- recupero la lavorazione : seconda ricerca con tipologia e diametro massimo
|
||||
sMilling = ML.FindMilling( 'DtMortise', nil, nil, 2 * dMinRad)
|
||||
if not sMilling then
|
||||
local sErr = 'Radius too small : Error on DtMortise ' .. tostring( Proc.Id)
|
||||
EgtOutLog( sErr)
|
||||
return false, sErr
|
||||
end
|
||||
-- recupero il diametro dell'utensile e l'angolo di spoglia
|
||||
local dToolDiam = 100
|
||||
local dMaxMat = 30
|
||||
@@ -182,16 +198,6 @@ function ProcessDtMortise.Make( Proc, nPhase, nRawId, nPartId, dCurrOvmH)
|
||||
bCW = ( dSpeed >= 0)
|
||||
end
|
||||
end
|
||||
-- verifico se raggio troppo piccolo per l'utensile
|
||||
local nSt, nEnd = EgtCurveDomain( AuxId)
|
||||
for i = nSt, nEnd - 1 do
|
||||
local dRad = EgtCurveCompoRadius( AuxId, i)
|
||||
if dRad > 0 and dRad < dToolDiam / 2 - GEO.EPS_ZERO then
|
||||
local sErr = 'Radius too small : Error on DtMortise ' .. tostring( Proc.Id)
|
||||
EgtOutLog( sErr)
|
||||
return false, sErr
|
||||
end
|
||||
end
|
||||
-- se con tasca, la lavoro
|
||||
if bPocket then
|
||||
-- recupero il contorno della tasca (seconda curva ausiliaria)
|
||||
|
||||
Reference in New Issue
Block a user