- Forzata origine 3 se arriva origine 1
- Corretti zeri piani generici di lavorazione
This commit is contained in:
@@ -5,10 +5,10 @@
|
||||
-- Aggiunta controllo collisione con nuovi oggetti
|
||||
|
||||
require( 'EmtGenerator')
|
||||
EgtEnableDebug( false)
|
||||
EgtEnableDebug( true)
|
||||
if not EmtModifyHeadAuxDirection then error( 'A newer version of the program is required (minimum 2.3j5)') end
|
||||
|
||||
PP_VER = '3.1d1_DEV8'
|
||||
PP_VER = '3.1d1_DEV9'
|
||||
PP_NVER = '2.7.4.1'
|
||||
|
||||
-- Parametri macchina
|
||||
@@ -34,9 +34,9 @@ MinX2 = 1047.0
|
||||
MaxX2 = 6080.0
|
||||
MinZ2 = -770.0
|
||||
MaxZ2 = 0.0
|
||||
SawOffsX = 111.0
|
||||
SawOffsX = 110.0
|
||||
SawOffsY = 0
|
||||
SawOffsZ = -150.25
|
||||
SawOffsZ = -149.55
|
||||
SawC1Offs = 0
|
||||
SawB1Offs = 0
|
||||
SawOffs = 0.0
|
||||
|
||||
+22
-23
@@ -39,7 +39,11 @@ end
|
||||
function OnProgramStart()
|
||||
-- Info da gruppo BtlInfo
|
||||
local BtlInfoId = EgtGetFirstNameInGroup( GDB_ID.ROOT, 'BtlInfo') or GDB_ID.NULL
|
||||
EMT.ORIG = EgtGetInfo( BtlInfoId, 'REFPOS', 'i') or 1
|
||||
EMT.ORIG = EgtGetInfo( BtlInfoId, 'REFPOS', 'i') or 1
|
||||
-- CASO SPECIALE: questa macchina utilizza origine 3 anche se viene passata origine 1 da TS3
|
||||
if EMT.ORIG == 1 then
|
||||
EMT.ORIG = 3
|
||||
end
|
||||
-- Intestazioni
|
||||
if not TEST_USE then
|
||||
local BtlInfoId = EgtGetFirstNameInGroup( GDB_ID.ROOT, 'BtlInfo') or GDB_ID.NULL
|
||||
@@ -253,7 +257,7 @@ function OnPathEnd()
|
||||
if EMT.HEAD == 'H21' or EMT.HEAD == 'H22' or EMT.HEAD == 'H23' then
|
||||
EmtOutput( 'G124 X'..EmtLenToString( EMT.NAIL_START_L1, 3)..' Y'..EmtLenToString( EMT.NAIL_START_L2, 3)..' Z'..EmtLenToString( EMT.NAIL_START_L3, 3)..
|
||||
' B'..EmtLenToString( EMT.NAIL_END_L1, 3)..' C'..EmtLenToString( EMT.NAIL_END_L2, 3)..' EA'..EmtLenToString( dStep, 3)..' EB1'..
|
||||
' W'..EmtLenToString( dSafeZ, 3)..EMT.NAIL_END)
|
||||
' W'..EmtLenToString( dSafeZ, 3))
|
||||
else
|
||||
local sExtra = ''
|
||||
local bInvert = false
|
||||
@@ -350,11 +354,11 @@ function OnRapid()
|
||||
local sOut = 'G101' .. EmtGetAxis( 'L1') .. EmtGetAxis( 'L2') .. EmtGetAxis( 'L3') ..
|
||||
EmtGetAxis( 'R2') .. EmtGetAxis( 'R1')
|
||||
if EMT.HEAD == 'H1' or EMT.HEAD == 'H12' or EMT.HEAD == 'H3' or ( EMT.HEAD == 'H14' and not EMT.DOUBLE) then
|
||||
sOut = sOut .. ' U' .. EmtLenToString( MinX2, 3) .. ' W0 V0 A0'
|
||||
sOut = sOut .. ' U' .. EmtLenToString( -MaxX2, 3) .. ' W0 V0 A0'
|
||||
elseif EMT.HEAD == 'H14' then
|
||||
sOut = sOut .. ' U' .. EmtLenToString( EMT.L2 - EMT.DELTA, 3) .. ' W0 V0 A0'
|
||||
elseif EMT.HEAD == 'H2' or EMT.HEAD == 'H21' or EMT.HEAD == 'H22' or EMT.HEAD == 'H23' then
|
||||
sOut = sOut .. ' U' .. EmtLenToString( MaxX1, 3) .. ' W0 V0 A0'
|
||||
sOut = sOut .. ' U' .. EmtLenToString( -MinX1, 3) .. ' W0 V0 A0'
|
||||
else
|
||||
EmtSetLastError( 1211, "Unknown Head : " .. EMT.HEAD)
|
||||
end
|
||||
@@ -431,10 +435,10 @@ function OnRapid()
|
||||
MyAdjustLinearAxes()
|
||||
EmtAdjustRotaryAxes()
|
||||
-- se fresa o punta su testa 1 raddrizzo l'utensile in risalita
|
||||
if EMT.HEAD == 'H1' and EMT.TCPOS ~= 'T201' and EMT.TCPOS ~= 'T202' and EMT.TCPOS ~= 'T203' then
|
||||
if ( EMT.HEAD == 'H1' or EMT.HEAD == 'H12') and EMT.TCPOS ~= 'T201' and EMT.TCPOS ~= 'T202' and EMT.TCPOS ~= 'T203' then
|
||||
local sOut = 'G101' .. EmtGetAxis( 'L1') .. EmtGetAxis( 'L2') .. EmtGetAxis( 'L3') ..
|
||||
EmtGetAxis( 'R2') .. EmtGetAxis( 'R1') ..
|
||||
' U' .. EmtLenToString( MinX2, 3) .. ' W0 V0 A0'
|
||||
' U' .. EmtLenToString( -MaxX2, 3) .. ' W0 V0 A0'
|
||||
local sET = GetET()
|
||||
local sEU = GetEU()
|
||||
local sEE = GetEE()
|
||||
@@ -449,7 +453,7 @@ function OnRapid()
|
||||
elseif EMT.HEAD == 'H3' then
|
||||
local sOut = 'G101' .. EmtGetAxis( 'L1') .. EmtGetAxis( 'L2') .. EmtGetAxis( 'L3') ..
|
||||
EmtGetAxis( 'R2') .. EmtGetAxis( 'R1') ..
|
||||
' U' .. EmtLenToString( MinX2, 3) .. ' W0 V0 A0'
|
||||
' U' .. EmtLenToString( -MaxX2, 3) .. ' W0 V0 A0'
|
||||
local sET = GetET()
|
||||
local sEU = GetEU()
|
||||
local sEE = GetEE()
|
||||
@@ -461,7 +465,7 @@ function OnRapid()
|
||||
sOut = sOut .. sET .. sEU .. sEE .. sEF .. sEM .. sES .. sEL .. sER
|
||||
EmtOutput( sOut)
|
||||
sOut = 'G101' .. ' X' .. EmtLenToString( ( MinX1 + MaxX1) / 2, 3)..
|
||||
' U' .. EmtLenToString( MinX2, 3) .. ' W0 V0 A0'
|
||||
' U' .. EmtLenToString( -MaxX2, 3) .. ' W0 V0 A0'
|
||||
EmtOutput( sOut)
|
||||
end
|
||||
-- dichiarazione risalita a Zmax
|
||||
@@ -674,7 +678,7 @@ function CalcInterpPlane()
|
||||
if EMT.HEAD == 'H1' or EMT.HEAD == 'H12' or EMT.HEAD == 'H3' then
|
||||
EMT.IPLGLFR = Frame3d( ptS, vtE)
|
||||
else
|
||||
EMT.IPLGLFR = Frame3d( ptS, Y_AX(), -X_AX(), Z_AX())
|
||||
EMT.IPLGLFR = Frame3d( ptS, -Y_AX(), X_AX(), Z_AX())
|
||||
end
|
||||
--EmtOutput( 'IPLGLFR='..tostring(EMT.IPLGLFR))
|
||||
local _, dAngV, dAngO = SphericalFromVector( vtE)
|
||||
@@ -691,24 +695,19 @@ function CalcInterpPlane()
|
||||
end
|
||||
dAngO = 0
|
||||
end
|
||||
local xOut = yS - DeltaTabY
|
||||
local yOut = - ( xS - DeltaTabX - DimTabX)
|
||||
|
||||
local xOut = - ( yS - DeltaTabY)
|
||||
local yOut = xS - DeltaTabX - DimTabX
|
||||
local zOut = zS
|
||||
if EMT.ORIG == 2 then
|
||||
xOut = yS - DeltaTabY
|
||||
yOut = - ( xS - DeltaTabX)
|
||||
xOut = - ( yS - DeltaTabY - DimTabY)
|
||||
yOut = xS - DeltaTabX - DimTabX
|
||||
elseif EMT.ORIG == 3 then
|
||||
xOut = yS - DeltaTabY
|
||||
yOut = - ( xS - DeltaTabX - DimTabX)
|
||||
xOut = - ( yS - DeltaTabY)
|
||||
yOut = xS - DeltaTabX
|
||||
elseif EMT.ORIG == 4 then
|
||||
xOut = yS - DeltaTabY - DimTabY
|
||||
yOut = - ( xS - DeltaTabX - DimTabX)
|
||||
elseif EMT.ORIG == 5 then
|
||||
xOut = yS - DeltaTabY - DimTabY
|
||||
yOut = - ( xS - DeltaTabX - Orig5DeltaX)
|
||||
elseif EMT.ORIG == 6 then
|
||||
xOut = yS - DeltaTabY
|
||||
yOut = - ( xS - DeltaTabX - Orig5DeltaX)
|
||||
xOut = - ( yS - DeltaTabY - DimTabY)
|
||||
yOut = xS - DeltaTabX
|
||||
end
|
||||
EMT.IPLGLSTR = ' EX'..EmtLenToString( xOut)..' EY'..EmtLenToString( yOut)..' EZ'..EmtLenToString( zOut)..
|
||||
' EA0'..' EB'..EgtNumToString( dAngV)..' EC'..EgtNumToString( dAngO)..' ED'..EgtNumToString( dAngO2)
|
||||
|
||||
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
+3
-5
@@ -28,12 +28,10 @@ local WallData = {
|
||||
MILL_OVERLAP = 5, -- sovrapposizione tra due mezze fresature
|
||||
MAX_CLEAN_CRN30 = 60, -- massimo spessore per pulitura angolo con fresa 30deg
|
||||
MAX_CLEAN_CRN60 = 150, -- massimo spessore per pulitura angolo con fresa 60deg
|
||||
MILL_MAX_DEPTH_AS_MAT = true, -- massimo affondamento frese uguale ad altezza tagliente (max materiale)
|
||||
T14_T12_DOUBLE = true, -- abilita chiodatura in doppio con teste T14 e T12
|
||||
MILL_MAX_DEPTH_AS_MAT = false, -- massimo affondamento frese uguale ad altezza tagliente (max materiale)
|
||||
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 = 'BL', -- posizione origine (TL,BL,TR,BR,TM,BM)
|
||||
MID_REF = 27000, -- posizione X dell'origine intermedia
|
||||
SIMUL_VIEW_DIR = 2, -- direzione di vista predefinita per la simulazione (1=NW, 2=SW, 3=NE, 4=SE)
|
||||
ORIG_CORNER = 'BL', -- posizione origine (TL,BL,TR,BR,TM,BM)
|
||||
USE_POSY = true -- utilizzare POSY di BTL (spostamento sullo spessore per pareti a layer)
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user