diff --git a/Essetre-90580012.mlde b/Essetre-90580012.mlde index d91cc04..a814442 100644 --- a/Essetre-90580012.mlde +++ b/Essetre-90580012.mlde @@ -6,18 +6,22 @@ -- 2023/09/18 DS ver 2.5i4 Aggiunta gestione due tavole accoppiate. -- 2023/09/20 DS ver 2.5i5 Grezzi larghi fino a 3520. Rifatta lavorazione lama in DB per eliminare problema ultimo step. -- 2023/09/20 DS ver 2.5i6 Corretta gestione posizione seconda tavola. Corretto spostamento solidi collisione testa lama. +-- 2024/02/09 AV ver 2.6b1 Forzato posizionamento pezzo sempre in origine 1 +-- Aggiunto magazzino per trucioaltore 600x20mm +-- Tavole azzerate a X negativo (per Essetre Y positivo) + require( 'EmtGenerator') EgtEnableDebug( false) -PP_VER = '2.5i6' +PP_VER = '2.5b1' -- Parametri macchina NumericalControl = 'NUM' -- NUM o TPA -MinY = 0.0 -MaxY = 25500.0 -MinY2 = 10000.0 -MaxY2 = 35500.0 +MinY = -25500.0 +MaxY = 0.0 +MinY2 = -35500.0 +MaxY2 = -10000.0 MinX1 = -5440.0 MaxX1 = -690.0 MinZ1 = -1345.0 @@ -46,12 +50,12 @@ SawDeltaZ = -253.0 SawOffs = 154.0 DimTabX = 10000.0 DimTabY = 3500.0 -DeltaTabX = 12034.96 +DeltaTabX = -23292.5 DeltaTabY = -4789.3 DeltaTabZ = -1150.0 DimTab2X = 10000.0 DimTab2Y = 3500.0 -DeltaTab2X = 12034.96 +DeltaTab2X = -23292.5 DeltaTab2Y = -4789.3 DeltaTab2Z = -1150.0 GantryTabs = 11000.0 @@ -73,8 +77,8 @@ if EgtExistsFile( sData) then if Machine and Machine.Offsets then local MchOffs = Machine.Offsets NumericalControl = EgtIf( MchOffs.TIPO_CN ~= 1, 'NUM', 'TPA') - if MchOffs.MAX_Y then MinY = -MchOffs.MAX_Y end - if MchOffs.MIN_Y then MaxY = -MchOffs.MIN_Y end + if MchOffs.MAX_Y then MaxY = MchOffs.MAX_Y end + if MchOffs.MIN_Y then MinY = MchOffs.MIN_Y end MinX1 = MchOffs.MIN_X or MinX1 MaxX1 = MchOffs.MAX_X or MaxX1 MinZ1 = MchOffs.MIN_Z or MinZ1 @@ -121,8 +125,8 @@ EmtGeneral { local BaseId = EmtBase { Name = 'Base', Geo='BASE/GEO', - Aux={'BASE/TRAVERSA', 'BASE/SUBTABLE', 'BASE/COLLISION', 'BASE/TC', 'BASE/TCR'}} - local vtMove = Vector3d( DeltaTabX - 12034.96, DeltaTabY + 4789.3, DeltaTabZ + 1150) + Aux={'BASE/TRAVERSA', 'BASE/SUBTABLE', 'BASE/COLLISION', 'BASE/TC', 'BASE/TCR', 'BASE/TCR2'}} + local vtMove = Vector3d( DeltaTabX + 23292.5, DeltaTabY + 4789.3, DeltaTabZ + 1150) EgtMove( EgtGetFirstNameInGroup( BaseId, 'SUBTABLE'), vtMove, GDB_RT.GLOB) -- Tavola 1 local YId = EmtAxis { @@ -133,7 +137,7 @@ local YId = EmtAxis { Dir = -X_AX(), Pos = Point3d( 0, 0, 0), Stroke = {MinY, MaxY}, - Home = MinY, + Home = MaxY, Geo = 'Y_AXIS/GEO', Aux = {'Y_AXIS/SOLID'}} EgtMove( YId, vtMove, GDB_RT.GLOB) @@ -153,7 +157,7 @@ local Y2Id = EmtAxis { Dir = -X_AX(), Pos = Point3d( 0, 0, 0), Stroke = {MinY2, MaxY2}, - Home = MaxY2, + Home = MinY2, Geo = 'Y2_AXIS/GEO', Aux = {'Y2_AXIS/SOLID'}} EgtMove( Y2Id, vtMove, GDB_RT.GLOB) @@ -379,7 +383,14 @@ EmtTcPos { TDir = X_AX(), ADir = Z_AX(), Geo = 'BASE/T101'} - +local ptTCR2 = Point3d( -901.3,-4392.7,-79) +EmtTcPos { + Name = 'T201', + Parent = 'Base', + Pos = ptTCR2, + TDir = Z_AX(), + ADir = X_AX(), + Geo = 'BASE/T201'} --------------------------------------------------------------------- -- Funzioni richiamate per modificare i dati macchina in casi particolari --function OnSetTable() diff --git a/Essetre-90580012.nge b/Essetre-90580012.nge index 9bf9257..56b3a36 100644 Binary files a/Essetre-90580012.nge and b/Essetre-90580012.nge differ diff --git a/Essetre-WALL.NUM.mlpe b/Essetre-WALL.NUM.mlpe index 1673488..932329b 100644 --- a/Essetre-WALL.NUM.mlpe +++ b/Essetre-WALL.NUM.mlpe @@ -9,16 +9,16 @@ local TEST_USE = false -- *** GENERATION *** --------------------------------------------------------------------- function OnStart() - EMT.USETO1 = false -- abilitazione uso origine tavola - EMT.MODAL = true -- abilitazione emissione modale - EMT.INCHES = false -- unità di misura mm/inches - EMT.NUM = false -- abilitazione numerazione linee + EMT.USETO1 = false -- abilitazione uso origine tavola + EMT.MODAL = true -- abilitazione emissione modale + EMT.INCHES = false -- unità di misura mm/inches + EMT.NUM = false -- abilitazione numerazione linee --EMT.Nt = 'N' -- token per la numerazione di linea --EMT.LINENBR = 0 -- numero di linea --EMT.LINEINC = 1 -- incremento numerazione linee --EMT.Ft = 'F' -- token per feed --EMT.St = 'S' -- token per speed - EMT.FMAXPINZE = 154000 -- feed massima pinze + EMT.FMAXPINZE = 154000 -- feed massima pinze end --------------------------------------------------------------------- @@ -32,8 +32,8 @@ function OnProgramStart() -- Flag local BtlInfoId = EgtGetFirstNameInGroup( GDB_ID.ROOT, 'BtlInfo') or GDB_ID.NULL EMT.LOAD90 = EgtGetInfo( BtlInfoId, 'LOAD90', 'i') or 0 - -- Imposto uso origine 3 - EMT.ORIG = 3 + -- Imposto uso origine 1 + EMT.ORIG = 1 -- Intestazioni if not TEST_USE then EMT.PRODID = EgtGetInfo( BtlInfoId, 'PRODID', 'i') or 0 diff --git a/Essetre-WALL.mlpe b/Essetre-WALL.mlpe index dc5a487..921908c 100644 --- a/Essetre-WALL.mlpe +++ b/Essetre-WALL.mlpe @@ -69,7 +69,8 @@ function OnSimulStart() { Grp = 'Base', Sub = 'COLLISION', Name = 'COL1'}, { Grp = 'Base', Sub = 'COLLISION', Name = 'COL2'}, { Grp = 'Base', Sub = 'COLLISION', Name = 'TC'}, - { Grp = 'Base', Sub = 'COLLISION', Name = 'CSAW'}} + { Grp = 'Base', Sub = 'COLLISION', Name = 'CSAW'}, + { Grp = 'Base', Sub = 'COLLISION', Name = 'TRUC'}} EgtOutLog( 'MCODET Objects :', 4) local nMcdNullCnt = 0 for i = 1, #McdData do @@ -131,7 +132,7 @@ function OnSimulDispositionStart() EMT.TAB2 = nil if EMT.LB > GantryTabs then EMT.TAB2 = true - EgtSetAxisPos( 'Y2', EgtGetAxisPos( 'Y') + DimTabX + OffsetTabs) + EgtSetAxisPos( 'Y2', EgtGetAxisPos( 'Y') - DimTabX - OffsetTabs) end -- Carico primo utensile sulla testa 1 local sTool = FindFirstToolOnHead( 'H1') @@ -412,7 +413,7 @@ end function OnSimulMoveStart() -- se lunghezza pezzo oltre il limite, aggancio le tavole if EMT.TAB2 then - EgtSetAxisPos( 'Y2', EgtGetAxisPos( 'Y') + DimTabX + OffsetTabs) + EgtSetAxisPos( 'Y2', EgtGetAxisPos( 'Y') - DimTabX - OffsetTabs) EMT.AuxAxes = 1 EMT.A1n = 'Y2' EMT.A1m = 'Y' @@ -454,7 +455,7 @@ function ParkForScrapRemove() local ParkY = min( -( b3Raw:getMin():getX() - 2000), -MinY) SimulMoveAxis( 'Z1', EgtGetAxisHomePos( 'Z1'), MCH_SIM_STEP.RAPID) if EMT.TAB2 then - SimulMoveAxes( 'Y', ParkY, MCH_SIM_STEP.RAPID, 'Y2', ParkY + DimTabX + OffsetTabs, MCH_SIM_STEP.RAPID) + SimulMoveAxes( 'Y', ParkY, MCH_SIM_STEP.RAPID, 'Y2', ParkY - DimTabX - OffsetTabs, MCH_SIM_STEP.RAPID) else SimulMoveAxis( 'Y', ParkY, MCH_SIM_STEP.RAPID) end diff --git a/Scripts/SetUp.lua b/Scripts/SetUp.lua index 3e48061..9f59e55 100644 --- a/Scripts/SetUp.lua +++ b/Scripts/SetUp.lua @@ -38,7 +38,8 @@ local PositionTable={{Pos = "Pos1", TcPos = "T1", Head = "H1", Group = "G1"}, {Pos = "Pos8", TcPos = "T8", Head = "H1", Group = "G1"}, {Pos = "Pos9", TcPos = "T9", Head = "H1", Group = "G1"}, {Pos = "Pos10", TcPos = "T101", Head = "H3", Group = "G1"}, - {Pos = "Pos11", TcPos = "T42", Head = "H2", Group = "G2"}} + {Pos = "Pos11", TcPos = "T201", Head = "H1", Group = "G1"}, + {Pos = "Pos12", TcPos = "T42", Head = "H2", Group = "G2"}} local UsePositionHead = true diff --git a/Wall/WallData.lua b/Wall/WallData.lua index 7591830..9c5902e 100644 --- a/Wall/WallData.lua +++ b/Wall/WallData.lua @@ -33,11 +33,11 @@ local WallData = { MAXDIAM_POCK_CORNER= 70, -- diametro massimo utensile ammesso per tasche con angoli interni RAWCOL = { 255, 160, 32, 30}, -- colore del grezzo SIMUL_VIEW_DIR = 3, -- direzione di vista predefinita per la simulazione (1=NW, 2=SW, 3=NE, 4=SE) - ORIG_CORNER = 'TR', -- angolo tavola per origine di battuta (BR (default), TR, BL, TL) + ORIG_CORNER = 'TL', -- angolo tavola per origine di battuta (BR (default), TR, BL, TL) RAWPART_ROT = 180, -- rotazione del pannello grezzo rispetto alla descrizione BTL CUT_WITH_OUTLINE = false, -- taglio delle feature con l'outline del pezzo - TAB_EXTRA_XP = 0, -- extra spazio su tavola per grezzo in X più - TAB_EXTRA_XM = 10050, -- extra spazio su tavola per grezzo in X meno + TAB_EXTRA_XP = 10050, -- extra spazio su tavola per grezzo in X più + TAB_EXTRA_XM = 0, -- extra spazio su tavola per grezzo in X meno TAB_EXTRA_YP = 0, -- extra spazio su tavola per grezzo in Y più TAB_EXTRA_YM = 20, -- extra spazio su tavola per grezzo in Y meno DELTA_X = 0, -- allontanamento in X dai riferimenti @@ -84,8 +84,8 @@ end ------------------------------------------------------------------------------------------------------------- local function GetOrigCorner( RefPos) - -- sempre origine macchina 3 - return 'TR' + -- sempre origine macchina 1 + return 'TL' end WallData.GetOrigCorner = GetOrigCorner