Compare commits

..

1 Commits

Author SHA1 Message Date
andrea.villa 27c3aaf1f1 Allineamento con comon ver. 3.1f4 2026-06-17 09:02:52 +02:00
4 changed files with 49 additions and 20 deletions
+43 -17
View File
@@ -422,6 +422,14 @@ function OnToolSelect()
if EMT.TDIST and abs( EMT.TDIST) < 0.1 then EMT.TDIST = nil end
EMT.TUSERNOTES = EgtTdbGetCurrToolParam( MCH_TP.USERNOTES)
EMT.ISPROBING = HeadIsProbe( EMT.HEAD)
-- gruppo della testa
local nHSet = GetHeadSet( EMT.HEAD)
if nHSet == 1 and EMT.PRESEL_H1 then
EMT.PRESEL_H1 = nil
elseif nHSet == 2 and EMT.PRESEL_H2 then
EMT.PRESEL_H2 = nil
end
end
end
@@ -3382,12 +3390,14 @@ function PreselectNextDiffHead( nMchId, sHead)
local nHSet = GetHeadSet( sHead)
local bVerifyPresel = true
-- se lavorazione con testa 1 e sotto al limite massimo di preselezione della testa 2, allora non si fa preselezione
if nHSet == 1 and Limit_T1_Presel_T2 and EMT.MAXMIN[2] < Limit_T1_Presel_T2 then
bVerifyPresel = false
-- se lavorazione con testa 1 e sopra al limite minimo di preselezione della testa 1, allora non si fa preselezione
elseif nHSet == 2 and Limit_T2_Presel_T1 and EMT.MAXMIN[2] > Limit_T2_Presel_T1 then
bVerifyPresel = false
if not EMT.LOAD then
-- se lavorazione con testa 1 e sotto al limite massimo di preselezione della testa 2, allora non si fa preselezione
if nHSet == 1 and Limit_T1_Presel_T2 and EMT.MAXMIN[2] < Limit_T1_Presel_T2 then
bVerifyPresel = false
-- se lavorazione con testa 1 e sopra al limite minimo di preselezione della testa 1, allora non si fa preselezione
elseif nHSet == 2 and Limit_T2_Presel_T1 and EMT.MAXMIN[2] > Limit_T2_Presel_T1 then
bVerifyPresel = false
end
end
-- flag preselezione eseguita
@@ -3456,20 +3466,36 @@ function PreselectNextDiffHead( nMchId, sHead)
end
-- se non eseguita preselezione
if not bPresel then
-- mi assicuro che l'altra testa sia in parcheggio
if nHSet == 1 then
-- non può essere la sega a catena
if EMT.PREVHEAD_H2 ~= 'H23' then
EmitMoveDataHead( 2, { X=-ParkX2, Z=MaxZ2, B=ParkB2, C=ParkC2, TPos=AdjustTcPos( false, EMT.PREVTCPOS_H2)})
EmitMoveStartHead( 2)
end
-- se era stato preselezionato un utensile e adesso non posso preselezionare, attendo la testa
if EMT.PRESEL_H2 then
EmitMoveWaitHead( 2)
EMT.PRESEL_H2 = nil
elseif EMT.PRESEL_H1 then
EmitMoveWaitHead( 1)
EMT.PRESEL_H1 = nil
-- se non era stato preselezionato nulla
else
-- non può essere la sega a catena
if EMT.PREVHEAD_H1 ~= 'H13' and EMT.PREVHEAD_H1 ~= 'H15' then
EmitMoveDataHead( 1, { X=-ParkX1, Z=MaxZ1, B=ParkB1, C=ParkC1, TPos=AdjustTcPos( false, EMT.PREVTCPOS_H1)})
EmitMoveStartHead( 1)
-- mi assicuro che l'altra testa sia in parcheggio
if nHSet == 1 then
-- non può essere la sega a catena
if EMT.PREVHEAD_H2 ~= 'H23' then
EmitMoveDataHead( 2, { X=-ParkX2, Z=MaxZ2, B=ParkB2, C=ParkC2, TPos=AdjustTcPos( false, EMT.PREVTCPOS_H2)})
EmitMoveStartHead( 2)
end
else
-- non può essere la sega a catena
if EMT.PREVHEAD_H1 ~= 'H13' and EMT.PREVHEAD_H1 ~= 'H15' then
EmitMoveDataHead( 1, { X=-ParkX1, Z=MaxZ1, B=ParkB1, C=ParkC1, TPos=AdjustTcPos( false, EMT.PREVTCPOS_H1)})
EmitMoveStartHead( 1)
end
end
end
else
if nHSet == 1 then
EMT.PRESEL_H2 = true
elseif nHSet == 1 then
EMT.PRESEL_H2 = true
end
end
end
+2 -2
View File
@@ -32,8 +32,8 @@
require( 'EmtGenerator')
EgtEnableDebug( false)
PP_VER = '3.1f3'
PP_NVER = '3.1.6.3'
PP_VER = '3.1f4'
PP_NVER = '3.1.6.4'
MIN_MACH_VER = '2.5k1'
MACH_NAME = EgtGetCurrMachineName()
+3
View File
@@ -1,5 +1,8 @@
==== Common_ONE-PF Update Log ====
Versione 3.1f4 (17/06/2026)
- (MLDE-GEN) Corretta preselezione in caso di testa in lavoro troppo vicina a quella che sta preselezionando. Da aggiungere in MLDE parametri 'Limit_T1_Presel_T2' e 'Limit_T2_Presel_T1'
Versione 3.1f3 (08/06/2026)
- (GEN) M77 viene ora eseguita, prima era commentata.
+1 -1
View File
@@ -3,7 +3,7 @@
local InfoCommon_STD_PP = {
NAME = 'Common_ONE-PF', -- nome script PP standard
VERSION = '3.1f3', -- versione script
VERSION = '3.1f4', -- versione script
MIN_MACH_VER_PP_COMMON = '3.1b2' -- versione minima kernel
}