Primo commit gestione tastatura

This commit is contained in:
andrea.villa
2025-06-20 17:30:08 +02:00
parent 67bb55537e
commit 6a6dc27560
3 changed files with 78 additions and 20 deletions
+52
View File
@@ -0,0 +1,52 @@
-- ProcessSplit.lua by Egaltech s.r.l. 2025/06/20
-- Gestione tastatura
-- Tabella per definizione modulo
local ProcessProbing = {}
-- Include
require( 'EgtBase')
local BL = require( 'BeamLib')
-- Dati
local BD = require( 'BeamData')
---------------------------------------------------------------------
local function GetProbingMachining( Machinings, nHead)
local sProbeMachining
for i = 1, #Machinings do
if EgtEndsWith( Machinings[i], '_H2') then
sProbeMachining = Machinings[i]
break
end
end
return sProbeMachining
end
---------------------------------------------------------------------
-- Applicazione della lavorazione
function ProcessProbing.Make( Proc, nRawId, nPartId, Info)
local bOk, sErr
-- per eseguire tastatura servono tutti i dati, altriemnti impossibile
if Info.vtProbe and Info.ptProbe and Info.sType then
-- recupero gruppo per geometria addizionale
local nAddGrpId = BL.GetAddGroup( nPartId)
local nIdLine = EgtLinePVL( nAddGrpId, Info.ptProbe, Info.vtProbe, 10) -- TODO lunghezza da portare fuori come parametro
local Machinings = GetMachinings( MCH_MY.PROBING, Info.sType)
local Probing = GetProbingMachining( Machinings, Info.nHead)
-- se c'è la linea e la lavorazione, applico
if Probing and nIdLine then
end
else
bOk = true
sErr = 'Error on probing'
end
return bOk, sErr
end
---------------------------------------------------------------------
return ProcessProbing