|
|
|
@@ -406,7 +406,6 @@ local function GetParameters_Essetre( Proc, sStrategyIdToGet)
|
|
|
|
|
local idSlaveProc = PROCESSINGS[Proc.nIndexPartInParts].Rotation[Proc.nCurrentRotation][Proc.SlaveProcIndexes[1]].id
|
|
|
|
|
local dDepthChamfer = EgtGetInfo( idSlaveProc or GDB_ID.NULL, 'Q06', 'd') or 0
|
|
|
|
|
table.insert( Parameters, { sName = 'dDepthChamfer', sValue = dDepthChamfer, sType = 'd'})
|
|
|
|
|
|
|
|
|
|
local dCuttingStrategy = EgtGetInfo( idSlaveProc or GDB_ID.NULL, 'Q05', 'd') or 0
|
|
|
|
|
local bForceChainSaw = dCuttingStrategy > 0
|
|
|
|
|
table.insert( Parameters, { sName = 'bForceChainSaw', sValue = bForceChainSaw, sType = 'b'})
|
|
|
|
@@ -419,17 +418,30 @@ local function GetParameters_Essetre( Proc, sStrategyIdToGet)
|
|
|
|
|
local dDepthChamfer = EgtGetInfo( Proc.id or GDB_ID.NULL, 'Q06', 'd') or 0
|
|
|
|
|
table.insert( Parameters, { sName = 'dDepthChamfer', sValue = dDepthChamfer, sType = 'd'})
|
|
|
|
|
local bForcePocketing = EgtGetInfo( Proc.id or GDB_ID.NULL, 'Q07', 'd') == 1
|
|
|
|
|
-- tutte le strategie che non siano svuotatura, devono essere rimosse
|
|
|
|
|
if bForcePocketing and sStrategyIdToGet ~= 'STR0002' then
|
|
|
|
|
Parameters.bToRemove = true
|
|
|
|
|
else
|
|
|
|
|
if sStrategyIdToGet == 'STR0002' then
|
|
|
|
|
-- non ci sono Q per questa strategia
|
|
|
|
|
elseif sStrategyIdToGet == 'STR0005' then
|
|
|
|
|
if bForcePocketing then
|
|
|
|
|
Parameters = { { bToRemove = true}}
|
|
|
|
|
else
|
|
|
|
|
local dCuttingStrategy = EgtGetInfo( Proc.id or GDB_ID.NULL, 'Q04', 'd') or 0
|
|
|
|
|
local sCuttingStrategy = EgtIf( dCuttingStrategy == 1, 'KEEP_WASTE_ATTACHED', 'AUTO')
|
|
|
|
|
table.insert( Parameters, { sName = 'sCuttingStrategy', sValue = sCuttingStrategy, sType = 's'})
|
|
|
|
|
end
|
|
|
|
|
end
|
|
|
|
|
-- Feature : Drill (1-40)
|
|
|
|
|
elseif ID.IsDrill( Proc) then
|
|
|
|
|
if sStrategyIdToGet == 'STR0011' then
|
|
|
|
|
local dDepthPreHole = ( EgtGetInfo( Proc.id or GDB_ID.NULL, 'Q03', 'd') or 0) == 1
|
|
|
|
|
table.insert( Parameters, { sName = 'dDepthPreHole', sValue = dDepthPreHole, sType = 'd'})
|
|
|
|
|
elseif sStrategyIdToGet == 'STR0013' then
|
|
|
|
|
local bOnlyContouring = ( EgtGetInfo( Proc.id or GDB_ID.NULL, 'Q01', 'd') or 0) == 1
|
|
|
|
|
table.insert( Parameters, { sName = 'bOnlyContouring', sValue = bOnlyContouring, sType = 'b'})
|
|
|
|
|
end
|
|
|
|
|
local bDrillFromOneSide = ( EgtGetInfo( Proc.id or GDB_ID.NULL, 'Q02', 'd') or 0) == 1
|
|
|
|
|
local sDrillingMode = EgtIf( bDrillFromOneSide, 'PREFER_ONE', 'AUTO')
|
|
|
|
|
table.insert( Parameters, { sName = 'sDrillingMode', sValue = sDrillingMode, sType = 's'})
|
|
|
|
|
end
|
|
|
|
|
|
|
|
|
|
return Parameters
|
|
|
|
@@ -500,18 +512,52 @@ local function GetTools_Essetre( Proc, sMachiningCategory)
|
|
|
|
|
end
|
|
|
|
|
ToolList = GetToolsFromMachDataFile( DrillData, TagList)
|
|
|
|
|
end
|
|
|
|
|
elseif sMachiningCategory == 'Milling' or sMachiningCategory == 'MillingFinish' or sMachiningCategory == 'MillingAntiSplint' then
|
|
|
|
|
elseif sMachiningCategory == 'Milling' or sMachiningCategory == 'MillingFinish' or sMachiningCategory == 'MillingAntiSplint' or sMachiningCategory == 'MillingChamfer' then
|
|
|
|
|
if EgtExistsFile( sMachDir .. '\\Beam\\MillingData.lua') then
|
|
|
|
|
local MillingData = dofile( sMachDir .. '\\Beam\\MillingData.lua')
|
|
|
|
|
-- TODO da fare!!
|
|
|
|
|
TagList = { 'Prof', 'FreeContour', 'Tenon', 'DtTenon', 'DtMortise', 'BirdsMouth', 'Chamfer', 'Mark', 'Text', 'Long2Cut',
|
|
|
|
|
'Long2CutDown', 'LongSmallCut', 'BHSideMill', 'CleanCorner', 'ProfTCone', 'Long2CutSide', 'SmallToolContour',
|
|
|
|
|
'AntiSplintMillCut', 'SideMillAsBlade', 'Prof_end'}
|
|
|
|
|
-- si cercano TAG esclusivi
|
|
|
|
|
if sMachiningCategory == 'MillingAntiSplint' then
|
|
|
|
|
TagList = { 'AntiSplintMillCut'}
|
|
|
|
|
elseif ID.IsTenon( Proc) then
|
|
|
|
|
TagList = { 'Tenon'}
|
|
|
|
|
elseif ID.IsDovetailTenon( Proc) then
|
|
|
|
|
TagList = { 'DtTenon'}
|
|
|
|
|
elseif ID.IsDovetailMortise( Proc) then
|
|
|
|
|
TagList = { 'DtMortise'}
|
|
|
|
|
elseif ID.IsHeadConcaveProfile( Proc) or ID.IsHeadConvexProfile( Proc) or ID.IsHeadCamberedProfile( Proc) or ID.IsRoundArch( Proc) or ID.IsHeadProfile( Proc) then
|
|
|
|
|
if sMachiningCategory == 'MillingFinish' then
|
|
|
|
|
TagList = { 'Prof_end'}
|
|
|
|
|
end
|
|
|
|
|
if not TagList or #TagList == 0 then
|
|
|
|
|
TagList = { 'Prof', 'Prof_end'}
|
|
|
|
|
end
|
|
|
|
|
elseif ID.IsFreeContour( Proc) then
|
|
|
|
|
TagList = { 'FreeContour', 'Prof', 'Prof_end'}
|
|
|
|
|
elseif ID.IsMarking( Proc) then
|
|
|
|
|
TagList = { 'Mark'}
|
|
|
|
|
elseif sMachiningCategory == 'MillingChamfer' then
|
|
|
|
|
TagList = { 'Chamfer', 'Mark'}
|
|
|
|
|
elseif ID.IsText( Proc) then
|
|
|
|
|
TagList = { 'Text'}
|
|
|
|
|
elseif ID.IsTyroleanDovetail( Proc) or ID.IsDovetail( Proc) then
|
|
|
|
|
TagList = { 'ProfTCone', 'Long2Cut'}
|
|
|
|
|
elseif ID.IsBirdsMouth( Proc) then
|
|
|
|
|
TagList = { 'BirdsMouth'}
|
|
|
|
|
elseif sMachiningCategory == 'MillingFinish' then
|
|
|
|
|
TagList = { 'CleanCorner', 'SmallToolContour'}
|
|
|
|
|
elseif ID.IsSlot( Proc) or ID.IsFrontSlot( Proc) or ID.IsLapJoint( Proc) or ID.IsNotchRabbet( Proc) or ID.IsNotch( Proc) or
|
|
|
|
|
ID.IsPocket( Proc) or ID.IsMortise( Proc) or ID.IsFrontMortise( Proc) then
|
|
|
|
|
TagList = { 'SideMillAsBlade', 'BHSideMill', 'Long2Cut', 'Long2CutDown', 'LongSmallCut', 'Long2CutSide'}
|
|
|
|
|
elseif ID.IsDoubleLongitudinalCut( Proc) or ID.IsDoubleLongitudinalCut( Proc) then
|
|
|
|
|
TagList = { 'Long2Cut', 'Long2CutDown', 'LongSmallCut', 'Long2CutSide'}
|
|
|
|
|
end
|
|
|
|
|
|
|
|
|
|
ToolList = GetToolsFromMachDataFile( MillingData, TagList)
|
|
|
|
|
end
|
|
|
|
|
elseif sMachiningCategory == 'Pocketing' then
|
|
|
|
|
if EgtExistsFile( sMachDir .. '\\Beam\\PocketingData.lua') then
|
|
|
|
|
local PocketingData = dofile( sMachDir .. '\\Beam\\PocketingData.lua')
|
|
|
|
|
-- si cercano TAG esclusivi
|
|
|
|
|
if ID.IsMortise( Proc) then
|
|
|
|
|
TagList = { 'Mortise', 'Mortise'}
|
|
|
|
|
else
|
|
|
|
|