- in FACEBYBLADE/MILL/CHAINSAW il parametro bOppositeToolDirection diventa OppositeToolDirectionMode (Enabled, Disabled, Optimized solo per blade); strategie modificate di conseguenza
- in FACEBYBLADE se OppositeToolDirectionMode = 'Optimized', la funzione sceglie se lavorare il lato in negativo per far combaciare concordanza e lavorazione verso l'alto
This commit is contained in:
@@ -170,7 +170,7 @@ function BeamExec.GetToolsFromDB()
|
||||
elseif sToolFamily == 'SAWBLADE' then
|
||||
Tool.bIsUsedForLongCut = EgtGetValInNotes( Tool.sUserNotes, 'LONGCUT') == 1 or false -- false come valore di default
|
||||
Tool.dStep = EgtGetValInNotes( Tool.sUserNotes, 'STEP', 'd') or Tool.dThickness -- se non settato nell'utensile, considero lo spessore lama
|
||||
Tool.dSideStep = EgtGetValInNotes( Tool.sUserNotes, 'SIDESTEP', 'd') or Tool.dMaxMaterial -- se non settato nell'utensile, considero un quarto del diametro
|
||||
Tool.dSideStep = EgtGetValInNotes( Tool.sUserNotes, 'SIDESTEP', 'd') or Tool.dMaxMaterial -- se non settato nell'utensile, considero il massimo materiale
|
||||
Tool.dPerformanceIndex = 1 / ( Tool.dDiameter * Tool.dLength)
|
||||
Tool.nQuality = 5
|
||||
-- recupero parametri propri delle motoseghe
|
||||
|
||||
@@ -249,7 +249,7 @@ function STR0003.Make( bAddMachining, Proc, Part, CustomParameters)
|
||||
|
||||
-- primo lato del tunnel o lato di fondo
|
||||
if Proc.Topology.sFamily == 'Tunnel' then
|
||||
OptionalParameters.bOppositeToolDirection = true
|
||||
OptionalParameters.OppositeToolDirectionMode = 'Enabled'
|
||||
Cutting = FaceByBlade.Make( Proc, Part, LongFace, OppositeEdge1, OptionalParameters)
|
||||
else
|
||||
Cutting = FaceByBlade.Make( Proc, Part, LongFace, BottomEdge, OptionalParameters)
|
||||
@@ -258,7 +258,7 @@ function STR0003.Make( bAddMachining, Proc, Part, CustomParameters)
|
||||
|
||||
-- lato opposto del tunnel
|
||||
if Proc.Topology.sFamily == 'Tunnel' then
|
||||
OptionalParameters.bOppositeToolDirection = true
|
||||
OptionalParameters.OppositeToolDirectionMode = 'Enabled'
|
||||
|
||||
Cutting = FaceByBlade.Make( Proc, Part, LongFace, OppositeEdge2, OptionalParameters)
|
||||
Blade.AddResult( Cutting)
|
||||
@@ -270,7 +270,7 @@ function STR0003.Make( bAddMachining, Proc, Part, CustomParameters)
|
||||
|
||||
-- eventuale lavorazione di lama - lato della tasca da cui inizia la lavorazione
|
||||
if BottomEdge.bIsStartOpen then
|
||||
OptionalParameters.bOppositeToolDirection = true
|
||||
OptionalParameters.OppositeToolDirectionMode = 'Enabled'
|
||||
|
||||
Cutting = FaceByBlade.Make( Proc, Part, LongFace, SideEdge1, OptionalParameters)
|
||||
Cutting.dAreaToMachine = Cutting.dDepthToMachine * ( Cutting.dEdgeLength - Blade.Result.Bottom[1].dDepthToMachine)
|
||||
@@ -279,7 +279,7 @@ function STR0003.Make( bAddMachining, Proc, Part, CustomParameters)
|
||||
|
||||
-- eventuale lavorazione di lama - lato della tasca in cui finisce la lavorazione
|
||||
if BottomEdge.bIsEndOpen then
|
||||
OptionalParameters.bOppositeToolDirection = true
|
||||
OptionalParameters.OppositeToolDirectionMode = 'Enabled'
|
||||
|
||||
Cutting = FaceByBlade.Make( Proc, Part, LongFace, SideEdge2, OptionalParameters)
|
||||
Cutting.dAreaToMachine = Cutting.dDepthToMachine * ( Cutting.dEdgeLength - Blade.Result.Bottom[1].dDepthToMachine)
|
||||
@@ -400,7 +400,7 @@ function STR0003.Make( bAddMachining, Proc, Part, CustomParameters)
|
||||
|
||||
OptionalParameters.sSideToMachine = 'End'
|
||||
OptionalParameters.dLengthToMachine = Blade.Result.Side[1].dToolMarkLength
|
||||
OptionalParameters.bOppositeToolDirection = true
|
||||
OptionalParameters.OppositeToolDirectionMode = 'Enabled'
|
||||
|
||||
Mortising = FaceByChainsaw.Make( Proc, Part, LongFace, SideEdge1, OptionalParameters)
|
||||
Mortising.dAreaToMachine = Mortising.dDepthToMachine * ( Mortising.dEdgeLength - Chainsaw.Result.Bottom[1].dDepthToMachine)
|
||||
@@ -409,7 +409,7 @@ function STR0003.Make( bAddMachining, Proc, Part, CustomParameters)
|
||||
|
||||
OptionalParameters.sSideToMachine = 'Start'
|
||||
OptionalParameters.dLengthToMachine = Blade.Result.Side[2].dToolMarkLength
|
||||
OptionalParameters.bOppositeToolDirection = true
|
||||
OptionalParameters.OppositeToolDirectionMode = 'Enabled'
|
||||
|
||||
Mortising = FaceByChainsaw.Make( Proc, Part, LongFace, SideEdge2, OptionalParameters)
|
||||
Mortising.dAreaToMachine = Mortising.dDepthToMachine * ( Mortising.dEdgeLength - Chainsaw.Result.Bottom[1].dDepthToMachine)
|
||||
@@ -427,14 +427,14 @@ function STR0003.Make( bAddMachining, Proc, Part, CustomParameters)
|
||||
|
||||
if BottomEdge.bIsStartOpen then
|
||||
OptionalParameters.dMaxElev = dBladeResidualDepth + BeamData.CUT_EXTRA
|
||||
OptionalParameters.bOppositeToolDirection = true
|
||||
OptionalParameters.OppositeToolDirectionMode = 'Enabled'
|
||||
|
||||
Mortising = FaceByChainsaw.Make( Proc, Part, LongFace, SideEdge1, OptionalParameters)
|
||||
Mortising.dAreaToMachine = Mortising.dDepthToMachine * ( Mortising.dEdgeLength - Chainsaw.Result.Bottom[1].dDepthToMachine)
|
||||
|
||||
elseif BottomEdge.bIsEndOpen then
|
||||
OptionalParameters.dMaxElev = dBladeResidualDepth + BeamData.CUT_EXTRA
|
||||
OptionalParameters.bOppositeToolDirection = true
|
||||
OptionalParameters.OppositeToolDirectionMode = 'Enabled'
|
||||
|
||||
Mortising = FaceByChainsaw.Make( Proc, Part, LongFace, SideEdge2, OptionalParameters)
|
||||
Mortising.dAreaToMachine = Mortising.dDepthToMachine * ( Mortising.dEdgeLength - Chainsaw.Result.Bottom[1].dDepthToMachine)
|
||||
@@ -468,7 +468,7 @@ function STR0003.Make( bAddMachining, Proc, Part, CustomParameters)
|
||||
OptionalParameters.dDepthToMachine = SideEdge1.dElevation + BeamData.CUT_EXTRA
|
||||
OptionalParameters.sSideToMachine = 'End'
|
||||
OptionalParameters.dLengthToMachine = Blade.Result.Side[1].dToolMarkLength
|
||||
OptionalParameters.bOppositeToolDirection = true
|
||||
OptionalParameters.OppositeToolDirectionMode = 'Enabled'
|
||||
|
||||
Mortising = FaceByChainsaw.Make( Proc, Part, LongFace, SideEdge1, OptionalParameters)
|
||||
Mortising.dAreaToMachine = Mortising.dDepthToMachine * ( Mortising.dEdgeLength - Chainsaw.Result.Bottom[1].dDepthToMachine)
|
||||
@@ -506,7 +506,7 @@ function STR0003.Make( bAddMachining, Proc, Part, CustomParameters)
|
||||
|
||||
OptionalParameters.dDepthToMachine = SideEdge1.dElevation + BeamData.CUT_EXTRA
|
||||
OptionalParameters.dMaxElev = Blade.Result.Side[1].dResidualDepth + BeamData.CUT_EXTRA
|
||||
OptionalParameters.bOppositeToolDirection = true
|
||||
OptionalParameters.OppositeToolDirectionMode = 'Enabled'
|
||||
|
||||
Mortising = FaceByChainsaw.Make( Proc, Part, LongFace, SideEdge1, OptionalParameters)
|
||||
Mortising.dAreaToMachine = Mortising.dDepthToMachine * ( Mortising.dEdgeLength - Chainsaw.Result.Bottom[1].dDepthToMachine)
|
||||
@@ -542,7 +542,7 @@ function STR0003.Make( bAddMachining, Proc, Part, CustomParameters)
|
||||
|
||||
elseif Proc.Topology.sName == 'Tunnel-4-Through' then
|
||||
|
||||
OptionalParameters.bOppositeToolDirection = true
|
||||
OptionalParameters.OppositeToolDirectionMode = 'Enabled'
|
||||
OptionalParameters.bExtendWithCornerRadius = true
|
||||
|
||||
-- si lavora solamente l'impronta lama sul lato opposto
|
||||
|
||||
@@ -178,7 +178,7 @@ function STR0004.Make( bAddMachining, Proc, Part, CustomParameters)
|
||||
or not Chainsaw.Result.Bottom[#Chainsaw.Result.Bottom].bIsApplicable)
|
||||
and #Proc.MainFaces.SideFaces == 1 then
|
||||
|
||||
OptionalParameters.bOppositeToolDirection = true
|
||||
OptionalParameters.OppositeToolDirectionMode = 'Enabled'
|
||||
|
||||
if BottomEdge.bIsStartOpen then
|
||||
Mortising = FaceByChainsaw.Make( Proc, Part, LongFace, SideEdge1, OptionalParameters)
|
||||
@@ -202,7 +202,7 @@ function STR0004.Make( bAddMachining, Proc, Part, CustomParameters)
|
||||
not Chainsaw.Result.Bottom[#Chainsaw.Result.Bottom].bIsApplicable) then
|
||||
|
||||
OptionalParameters.dDepthToMachine = SideEdge1.dElevation + BeamData.CUT_EXTRA
|
||||
OptionalParameters.bOppositeToolDirection = true
|
||||
OptionalParameters.OppositeToolDirectionMode = 'Enabled'
|
||||
|
||||
Mortising = FaceByChainsaw.Make( Proc, Part, LongFace, SideEdge1, OptionalParameters)
|
||||
Mortising.dAreaToMachine = Mortising.dDepthToMachine * ( Mortising.dEdgeLength - Chainsaw.Result.Bottom[1].dDepthToMachine)
|
||||
@@ -236,7 +236,7 @@ function STR0004.Make( bAddMachining, Proc, Part, CustomParameters)
|
||||
elseif Proc.Topology.sName == 'Tunnel-4-Through' then
|
||||
|
||||
OptionalParameters.dDepthToMachine = OppositeEdge1.dElevation + BeamData.CUT_EXTRA
|
||||
OptionalParameters.bOppositeToolDirection = true
|
||||
OptionalParameters.OppositeToolDirectionMode = 'Enabled'
|
||||
OptionalParameters.bExtendWithCornerRadius = true
|
||||
|
||||
Mortising = FaceByChainsaw.Make( Proc, Part, LongFace, OppositeEdge1, OptionalParameters)
|
||||
|
||||
@@ -103,7 +103,7 @@
|
||||
{
|
||||
"sName": "bDisableDicing",
|
||||
"sNameNge": "DISABLE_DICING",
|
||||
"sValue": "1",
|
||||
"sValue": "true",
|
||||
"sDescriptionShort": "Disable dicing",
|
||||
"sDescriptionLong": "",
|
||||
"sType": "b",
|
||||
|
||||
@@ -225,7 +225,7 @@ function BLADEKEEPWASTE.Make( Proc, Part, OptionalParameters)
|
||||
Cutting1.dResultWeight = 0.3
|
||||
table.insert( CalculatedMachinings, Cutting1)
|
||||
-- secondo lato
|
||||
OptionalParametersFaceByBlade.bOppositeToolDirection = true
|
||||
OptionalParametersFaceByBlade.OppositeToolDirectionMode = 'Enabled'
|
||||
Cutting2 = FaceByBlade.Make( Proc, Part, BottomFace, BottomEdgeToMachine, OptionalParametersFaceByBlade)
|
||||
Cutting2.nInternalSortingPriority = 3
|
||||
Cutting2.dResultWeight = 0.3
|
||||
|
||||
@@ -345,7 +345,6 @@ local function CutWholeWaste( Proc, Part, OptionalParameters)
|
||||
nToolIndex = ToolInfo.nToolIndex
|
||||
sChosenBladeType = 'TopGuillotine'
|
||||
end
|
||||
|
||||
end
|
||||
end
|
||||
|
||||
@@ -376,7 +375,10 @@ local function CutWholeWaste( Proc, Part, OptionalParameters)
|
||||
dExtendAfterTail = dExtendAfterTail,
|
||||
bReduceBladePath = bReduceBladePath
|
||||
}
|
||||
|
||||
if sChosenBladeType == 'Top' or sChosenBladeType == 'Bottom' then
|
||||
OptionalParametersFaceByBlade.OppositeToolDirectionMode = 'Optimized'
|
||||
end
|
||||
|
||||
Cutting = FaceByBlade.Make( Proc, Part, Proc.Faces[1], EdgeToMachine, OptionalParametersFaceByBlade)
|
||||
end
|
||||
if Cutting.bIsApplicable then
|
||||
|
||||
@@ -250,7 +250,7 @@ function FACEBYBLADE.Make( Proc, Part, FaceToMachine, EdgeToMachine, OptionalPar
|
||||
local dPocketHeight = OptionalParameters.dPocketHeight or 0
|
||||
local dDepthToMachine = OptionalParameters.dDepthToMachine or EdgeToMachine.dElevation
|
||||
local bIsSplitFeature = OptionalParameters.bIsSplitFeature or false
|
||||
local bOppositeToolDirection = OptionalParameters.bOppositeToolDirection or false
|
||||
local OppositeToolDirectionMode = OptionalParameters.OppositeToolDirectionMode or 'Disabled'
|
||||
local bReduceBladePath = OptionalParameters.bReduceBladePath or false
|
||||
local sDepth = OptionalParameters.sDepth or 0
|
||||
local nToolIndex = OptionalParameters.nToolIndex
|
||||
@@ -264,7 +264,7 @@ function FACEBYBLADE.Make( Proc, Part, FaceToMachine, EdgeToMachine, OptionalPar
|
||||
|
||||
-- lunghezze, direzioni e punti caratteristici della lavorazione e del lato lavorato
|
||||
Cutting.dEdgeLength = EdgeToMachine.dLength
|
||||
if bOppositeToolDirection then
|
||||
if OppositeToolDirectionMode == 'Enabled' then
|
||||
Cutting.vtToolDirection = -EdgeToMachine.vtN
|
||||
else
|
||||
Cutting.vtToolDirection = EdgeToMachine.vtN
|
||||
@@ -340,7 +340,7 @@ function FACEBYBLADE.Make( Proc, Part, FaceToMachine, EdgeToMachine, OptionalPar
|
||||
-- inizio e fine aperti o chiusi
|
||||
Cutting.bIsStartClosed = not EdgeToMachine.bIsStartOpen
|
||||
Cutting.bIsEndClosed = not EdgeToMachine.bIsEndOpen
|
||||
-- lato di lavoro e inversione
|
||||
-- lato di lavoro e inversione per avere taglio concorde
|
||||
if TOOLS[Cutting.nToolIndex].bIsCCW then
|
||||
Cutting.nWorkside = MCH_MILL_WS.RIGHT
|
||||
Cutting.bInvert = true
|
||||
@@ -348,7 +348,32 @@ function FACEBYBLADE.Make( Proc, Part, FaceToMachine, EdgeToMachine, OptionalPar
|
||||
Cutting.nWorkside = MCH_MILL_WS.LEFT
|
||||
Cutting.bInvert = false
|
||||
end
|
||||
if bOppositeToolDirection then
|
||||
-- se OppositeToolDirectionMode è Optimized, se possibile e necessario, si attiva per garantire taglio concorde e verso l'alto (massima qualità)
|
||||
if ( OppositeToolDirectionMode == 'Optimized') and ( Proc.nFct == 1) then
|
||||
OppositeToolDirectionMode = 'Disabled'
|
||||
-- la direzione di percorrenza del lato deve essere verso l'alto; bInvert va considerata perchè inverte la direzione di percorrenza.
|
||||
if ( Cutting.bInvert and Cutting.vtEdgeDirection:getZ() > 100 * GEO.EPS_SMALL)
|
||||
or ( ( not Cutting.bInvert) and Cutting.vtEdgeDirection:getZ() < -100 * GEO.EPS_SMALL) then
|
||||
|
||||
-- si attiva OppositeToolDirection solo se non cambiano le condizioni di taglio downUp
|
||||
local dNewMinNzDownUp = TOOLS[nToolIndex].SetupInfo.GetMinNzDownUp( Part.b3Raw, FaceToMachine.vtN, -Cutting.vtToolDirection, TOOLS[nToolIndex])
|
||||
if ( FaceToMachine.vtN:getZ() < dMinNzDownUp) == ( FaceToMachine.vtN:getZ() < dNewMinNzDownUp) then
|
||||
OppositeToolDirectionMode = 'Enabled'
|
||||
Cutting.vtToolDirection = -EdgeToMachine.vtN
|
||||
Cutting.ptEdge1, _, Cutting.ptEdge2 = EgtSurfTmFacetOppositeSide( Proc.id, FaceToMachine.id, -Cutting.vtToolDirection, GDB_ID.ROOT)
|
||||
Cutting.bInvert = not Cutting.bInvert
|
||||
-- se le condizioni downUp cambiano, si setta per tagliare verso l'alto
|
||||
else
|
||||
if Cutting.nWorkside == MCH_MILL_WS.RIGHT then
|
||||
Cutting.nWorkside = MCH_MILL_WS.LEFT
|
||||
Cutting.bInvert = false
|
||||
else
|
||||
Cutting.nWorkside = MCH_MILL_WS.RIGHT
|
||||
Cutting.bInvert = true
|
||||
end
|
||||
end
|
||||
end
|
||||
elseif OppositeToolDirectionMode == 'Enabled' then
|
||||
Cutting.bInvert = not Cutting.bInvert
|
||||
end
|
||||
if Cutting.bToolInvert then
|
||||
@@ -360,7 +385,7 @@ function FACEBYBLADE.Make( Proc, Part, FaceToMachine, EdgeToMachine, OptionalPar
|
||||
-- TODO la depth dovrebbe essere quella del machining
|
||||
Cutting.dDepthToMachine = dDepthToMachine
|
||||
Cutting.dResidualDepth = 0
|
||||
if bOppositeToolDirection then
|
||||
if OppositeToolDirectionMode == 'Enabled' then
|
||||
Cutting.dRadialOffset = -dDepthToMachine
|
||||
else
|
||||
Cutting.dRadialOffset = EdgeToMachine.dElevation - dDepthToMachine
|
||||
@@ -368,7 +393,7 @@ function FACEBYBLADE.Make( Proc, Part, FaceToMachine, EdgeToMachine, OptionalPar
|
||||
else
|
||||
Cutting.dDepthToMachine = TOOLS[Cutting.nToolIndex].dMaxDepth - 1
|
||||
Cutting.dResidualDepth = dDepthToMachine - Cutting.dDepthToMachine
|
||||
if bOppositeToolDirection then
|
||||
if OppositeToolDirectionMode == 'Enabled' then
|
||||
Cutting.dRadialOffset = -Cutting.dDepthToMachine
|
||||
else
|
||||
Cutting.dRadialOffset = EdgeToMachine.dElevation - Cutting.dDepthToMachine
|
||||
@@ -397,7 +422,7 @@ function FACEBYBLADE.Make( Proc, Part, FaceToMachine, EdgeToMachine, OptionalPar
|
||||
end
|
||||
end
|
||||
end
|
||||
if bOppositeToolDirection then
|
||||
if OppositeToolDirectionMode == 'Enabled' then
|
||||
Cutting.dRadialOffset = -dDepthToMachine
|
||||
else
|
||||
Cutting.dRadialOffset = EdgeToMachine.dElevation - dDepthToMachine
|
||||
@@ -423,7 +448,7 @@ function FACEBYBLADE.Make( Proc, Part, FaceToMachine, EdgeToMachine, OptionalPar
|
||||
-- overlap
|
||||
Cutting.dOverlap = 0
|
||||
-- EdgeUse e frame lavorazione
|
||||
if bOppositeToolDirection then
|
||||
if OppositeToolDirectionMode == 'Enabled' then
|
||||
Cutting.nFaceuse = BeamLib.GetNearestOrthoOpposite( -Cutting.vtToolDirection)
|
||||
--Cutting.vtFaceUse = -Cutting.vtToolDirection
|
||||
Cutting.nEdgesFaceUse = EdgeToMachine.id
|
||||
|
||||
@@ -71,13 +71,13 @@ function FACEBYCHAINSAW.Make( Proc, Part, FaceToMachine, EdgeToMachine, Optional
|
||||
local dExtendAfterTail = OptionalParameters.dExtendAfterTail or 10000
|
||||
local dPocketHeight = OptionalParameters.dPocketHeight or 0
|
||||
local bIsSplitFeature = OptionalParameters.bIsSplitFeature or false
|
||||
local bOppositeToolDirection = OptionalParameters.bOppositeToolDirection or false
|
||||
local OppositeToolDirectionMode = OptionalParameters.OppositeToolDirectionMode or 'Disabled'
|
||||
local sDepth = OptionalParameters.sDepth or 'TH'
|
||||
local dLongitudinalStepSpan = OptionalParameters.dLongitudinalStepSpan
|
||||
|
||||
-- lunghezze e punti caratteristici della lavorazione e del lato lavorato
|
||||
Mortising.dEdgeLength = EdgeToMachine.dLength
|
||||
if bOppositeToolDirection then
|
||||
if OppositeToolDirectionMode == 'Enabled' then
|
||||
Mortising.vtToolDirection = -EdgeToMachine.vtN
|
||||
else
|
||||
Mortising.vtToolDirection = EdgeToMachine.vtN
|
||||
@@ -129,7 +129,7 @@ function FACEBYCHAINSAW.Make( Proc, Part, FaceToMachine, EdgeToMachine, Optional
|
||||
Mortising.bIsEndClosed = not EdgeToMachine.bIsEndOpen
|
||||
-- lato di lavoro e inversioni
|
||||
Mortising.bInvert = false
|
||||
if bOppositeToolDirection then
|
||||
if OppositeToolDirectionMode == 'Enabled' then
|
||||
Mortising.nWorkside = MCH_MILL_WS.LEFT
|
||||
Mortising.bToolInvert = true
|
||||
else
|
||||
@@ -143,7 +143,7 @@ function FACEBYCHAINSAW.Make( Proc, Part, FaceToMachine, EdgeToMachine, Optional
|
||||
if TOOLS[Mortising.nToolIndex].dMaxMaterial > dDepthToMachine - 10 * GEO.EPS_SMALL then
|
||||
Mortising.dDepthToMachine = dDepthToMachine
|
||||
Mortising.dResidualDepth = 0
|
||||
if bOppositeToolDirection then
|
||||
if OppositeToolDirectionMode == 'Enabled' then
|
||||
Mortising.dLongitudinalOffset = EdgeToMachine.dElevation - dDepthToMachine
|
||||
else
|
||||
Mortising.dLongitudinalOffset = 0
|
||||
@@ -151,7 +151,7 @@ function FACEBYCHAINSAW.Make( Proc, Part, FaceToMachine, EdgeToMachine, Optional
|
||||
else
|
||||
Mortising.dDepthToMachine = TOOLS[Mortising.nToolIndex].dMaxMaterial - 1
|
||||
Mortising.dResidualDepth = dDepthToMachine - Mortising.dDepthToMachine
|
||||
if bOppositeToolDirection then
|
||||
if OppositeToolDirectionMode == 'Enabled' then
|
||||
Mortising.dLongitudinalOffset = 0
|
||||
else
|
||||
Mortising.dLongitudinalOffset = EdgeToMachine.dElevation - Mortising.dDepthToMachine
|
||||
@@ -181,7 +181,7 @@ function FACEBYCHAINSAW.Make( Proc, Part, FaceToMachine, EdgeToMachine, Optional
|
||||
Mortising.Steps.dStep = TOOLS[Mortising.nToolIndex].dStep
|
||||
Mortising.Steps.nCount = max( 1, ceil( ( min( Mortising.dDepthToMachine, ( Mortising.dMaxElev or Mortising.dDepthToMachine)) + 10 * GEO.EPS_SMALL) / Mortising.Steps.dStep))
|
||||
-- faceuse
|
||||
if bOppositeToolDirection then
|
||||
if OppositeToolDirectionMode == 'Enabled' then
|
||||
Mortising.nFaceuse = BeamLib.GetNearestParalOpposite( -Mortising.vtToolDirection)
|
||||
else
|
||||
Mortising.nFaceuse = BeamLib.GetNearestParalOpposite( Mortising.vtToolDirection)
|
||||
|
||||
@@ -186,7 +186,7 @@ function FACEBYMILL.Make( Proc, Part, FaceToMachine, EdgeToMachine, OptionalPara
|
||||
local dPocketHeight = OptionalParameters.dPocketHeight or 0
|
||||
local dDepthToMachine = OptionalParameters.dDepthToMachine or EdgeToMachine.dElevation
|
||||
local bIsSplitFeature = OptionalParameters.bIsSplitFeature or false
|
||||
local bOppositeToolDirection = OptionalParameters.bOppositeToolDirection or false
|
||||
local OppositeToolDirectionMode = OptionalParameters.OppositeToolDirectionMode or 'Disabled'
|
||||
local sDepth = OptionalParameters.sDepth or 0
|
||||
local nToolIndex = OptionalParameters.nToolIndex
|
||||
local dLongitudinalOffset = OptionalParameters.dLongitudinalOffset or 0
|
||||
@@ -199,7 +199,7 @@ function FACEBYMILL.Make( Proc, Part, FaceToMachine, EdgeToMachine, OptionalPara
|
||||
|
||||
-- lunghezze, direzioni e punti caratteristici della lavorazione e del lato lavorato
|
||||
Milling.dEdgeLength = EdgeToMachine.dLength
|
||||
if bOppositeToolDirection then
|
||||
if OppositeToolDirectionMode == 'Enabled' then
|
||||
Milling.vtToolDirection = -EdgeToMachine.vtN
|
||||
else
|
||||
Milling.vtToolDirection = EdgeToMachine.vtN
|
||||
@@ -287,7 +287,7 @@ function FACEBYMILL.Make( Proc, Part, FaceToMachine, EdgeToMachine, OptionalPara
|
||||
Milling.nWorkside = MCH_MILL_WS.LEFT
|
||||
Milling.bInvert = false
|
||||
end
|
||||
if bOppositeToolDirection then
|
||||
if OppositeToolDirectionMode == 'Enabled' then
|
||||
Milling.bInvert = not Milling.bInvert
|
||||
end
|
||||
if Milling.bToolInvert then
|
||||
@@ -299,7 +299,7 @@ function FACEBYMILL.Make( Proc, Part, FaceToMachine, EdgeToMachine, OptionalPara
|
||||
-- TODO la depth dovrebbe essere quella del machining
|
||||
Milling.dDepthToMachine = dDepthToMachine
|
||||
Milling.dResidualDepth = 0
|
||||
if bOppositeToolDirection then
|
||||
if OppositeToolDirectionMode == 'Enabled' then
|
||||
Milling.dRadialOffset = -dDepthToMachine
|
||||
else
|
||||
Milling.dRadialOffset = EdgeToMachine.dElevation - dDepthToMachine
|
||||
@@ -307,7 +307,7 @@ function FACEBYMILL.Make( Proc, Part, FaceToMachine, EdgeToMachine, OptionalPara
|
||||
else
|
||||
Milling.dDepthToMachine = TOOLS[Milling.nToolIndex].dSideDepth - 1
|
||||
Milling.dResidualDepth = dDepthToMachine - Milling.dDepthToMachine
|
||||
if bOppositeToolDirection then
|
||||
if OppositeToolDirectionMode == 'Enabled' then
|
||||
Milling.dRadialOffset = -Milling.dDepthToMachine
|
||||
else
|
||||
Milling.dRadialOffset = EdgeToMachine.dElevation - Milling.dDepthToMachine
|
||||
@@ -316,7 +316,7 @@ function FACEBYMILL.Make( Proc, Part, FaceToMachine, EdgeToMachine, OptionalPara
|
||||
else
|
||||
Milling.dDepthToMachine = dDepthToMachine
|
||||
Milling.dResidualDepth = 0
|
||||
if bOppositeToolDirection then
|
||||
if OppositeToolDirectionMode == 'Enabled' then
|
||||
Milling.dRadialOffset = -dDepthToMachine
|
||||
else
|
||||
Milling.dRadialOffset = EdgeToMachine.dElevation - dDepthToMachine
|
||||
@@ -350,7 +350,7 @@ function FACEBYMILL.Make( Proc, Part, FaceToMachine, EdgeToMachine, OptionalPara
|
||||
-- overlap
|
||||
Milling.dOverlap = 0
|
||||
-- faceuse e frame lavorazione
|
||||
if bOppositeToolDirection then
|
||||
if OppositeToolDirectionMode == 'Enabled' then
|
||||
Milling.nFaceuse = BeamLib.GetNearestOrthoOpposite( -Milling.vtToolDirection)
|
||||
--Milling.vtFaceUse = -Milling.vtToolDirection
|
||||
Milling.nEdgesFaceUse = EdgeToMachine.id
|
||||
|
||||
Reference in New Issue
Block a user