Compare commits

..

4 Commits

Author SHA1 Message Date
luca.mazzoleni dc92797882 update dimensioni massime pezzo 2023-12-18 14:34:27 +01:00
andrea.villa af849eda23 Aggiunto commento in MLDE e aggiornamento versione 2023-12-18 09:55:07 +01:00
andrea.villa 89c0d3b8ed Corretti vari offset in simulazione 2023-12-18 09:52:43 +01:00
andrea.villa bc51f5e94f Versione rilasciabile. Rimossa gestione (embrionale) lama su aggregato da sotto per evitare eventuali problemi. 2023-12-13 09:33:08 +01:00
26 changed files with 830 additions and 3611 deletions
-318
View File
@@ -1,318 +0,0 @@
variables:
VERS_MAIN: '1.0'
MACH_NAME: ''
MACH_NAME_TEST: ''
MANUFACTURER: ''
NEW_REL: ''
NET_SHARE_X: '\\10.74.82.201\EgwTech'
NET_SHARE_Z: '\\10.74.82.201\Artifacts'
NET_SHARE_S: '\\10.74.82.201\Scambio'
NET_SHARE_R: '\\10.74.82.201\EgwTech'
NET_SHARE_H: '\\10.74.82.252\team drives'
NET_USERQ: 'steamw\egalware'
NET_USER_SERVICES: 'steamw\services'
MACH_VERS: '0.0.0.0'
TEMP_PATH: 'C:\MachinesDeploy'
MACHINES_PATH_R: 'R:\EgtData\Machines_GIT'
DEST_MACHINES_PATH_H: 'H:'
SRC_PATH: ''
BASE_PATH: ''
TEST_PATH: ''
URL_VERSIONS_LOG: "https://liman.egalware.com/ELM.API/api/release/save"
MACH_VERS_NUM: '0.0.0.0'
CRITICAL_STRING: "#critical#"
TOOLS_MACHINE_PATH: ""
#Note compilazione LUA:
# lua54 -o bin\$FileName -s $FileName: -o = output, -s = NON include i debug symbols
# helper copia script verso cartella di rete S:\ delle cartelle bin
.ReplicaS: &ReplicaS
- |
net use S: /delete
SLEEP 2
net use S: $env:NET_SHARE_S /u:$env:NET_USERQ $SDRIVE_PASSWD
ROBOCOPY /MIR $env:BASE_PATH S:\LucaM\MachinesDeploy\$env:MACH_NAME\$env:MACH_VERS\ /XD "bin" /XD "$env:MACH_NAME_TEST"
SLEEP 2
net use S: /delete
# helper copia script verso cartella di rete R:\
.ReplicaR: &ReplicaR
- |
net use R: /delete
SLEEP 2
net use R: $env:NET_SHARE_R /u:$env:NET_USERQ $ZDRIVE_PASSWD
echo "-----------------------"
echo " Copia macchina su R"
echo "-----------------------"
$customerPathR = $env:MACHINES_PATH_R + "\" + $env:MANUFACTURER
ROBOCOPY /MIR "$env:SRC_PATH" "$customerPathR\$env:MACH_NAME\" /XD "bin"
ROBOCOPY "$env:TEST_PATH" "$customerPathR\_TestMachines\$env:MACH_NAME_TEST\" /E /XD "bin"
ROBOCOPY /MIR "$env:BASE_PATH" "$customerPathR\_Deploy\$env:MACH_NAME\$env:MACH_VERS\" /XD "bin" /XD "$env:MACH_NAME_TEST"
SLEEP 2
net use R: /delete
# helper copia script verso drive condiviso
.ReplicaStor01: &ReplicaStor01
- |
net use H: /delete
SLEEP 2
net use H: $env:NET_SHARE_H /u:$env:NET_USER_SERVICES $SRVCS_PASSWD
echo "-----------------------"
echo " Copia macchina su stor01"
echo "-----------------------"
SLEEP 2
$customerPathH = $env:DEST_MACHINES_PATH_H + "\" + $env:MANUFACTURER + "\test"
$destinationPath = "$customerPathH\$env:MACH_NAME" + "\"
ROBOCOPY "$env:BASE_PATH" "$destinationPath\" *.zip
SLEEP 2
net use H: /delete
# helper copia script verso cartella di rete R:\ per develop
.ReplicaR_DEV: &ReplicaR_DEV
- |
net use R: /delete
SLEEP 2
net use R: $env:NET_SHARE_R /u:$env:NET_USERQ $ZDRIVE_PASSWD
echo "-----------------------"
echo " Copia macchina su R - DEV"
echo "-----------------------"
$customerPathR = $env:MACHINES_PATH_R + "\" + $env:MANUFACTURER
ROBOCOPY /MIR "$env:BASE_PATH" "$customerPathR\_Deploy\$env:MACH_NAME\_DEV\$env:MACH_VERS\" /XD "bin" /XD "$env:MACH_NAME_TEST"
SLEEP 2
net use R: /delete
#helper copia sorgenti da R a percorso temporaneo
.CreateBaseFolder: &CreateBaseFolder
- |
net use R: /delete
SLEEP 2
net use R: $env:NET_SHARE_R /u:$env:NET_USERQ $ZDRIVE_PASSWD
echo "-----------------------"
echo " Recupero file non git da R e copia su macchina virtuale"
echo "-----------------------"
# test se la cartella con gli utensili esiste per questa macchina
if (!(Test-Path -Path $env:TOOLS_MACHINE_PATH)) {
echo "-----------------------"
echo "CANNOT FIND TOOLS FOR THIS MACHINE!!"
echo "-----------------------"
Exit 1}
ROBOCOPY "$env:TOOLS_MACHINE_PATH" "$env:SRC_PATH" /E /XF "*.bat" /XF "*.yml" /XF ".gitignore" /XD ".git" /XF "UpdateLog.txt" /XD ".vscode"
ROBOCOPY "$env:TOOLS_MACHINE_PATH" "$env:TEST_PATH" /E /XF "*.bat" /XF "*.yml" /XF ".gitignore" /XD ".git" /XF "UpdateLog.txt" /XD ".vscode"
ROBOCOPY "$env:TOOLS_MACHINE_PATH" "$env:SRC_PATH\bin\$env:MACH_NAME\" /E /XF "*.bat" /XF "*.yml" /XF ".gitignore" /XD ".git" /XF "UpdateLog.txt" /XD ".vscode"
SLEEP 2
net use R: /delete
# helper compilazione LUA a 32 e 64 bit
.LuaCompile: &LuaCompile
- |
Set-Alias lua54 C:\Tools\Lua32\luac54
echo "-----------------------"
echo " Copia file su macchina virtuale"
echo "-----------------------"
ROBOCOPY . "$env:SRC_PATH" /E /XF "*.bat" /XF "*.yml" /XF ".gitignore" /XD ".git" /XF "UpdateLog.txt" /XD ".vscode"
ROBOCOPY . "$env:TEST_PATH" /E /XF "*.bat" /XF "*.yml" /XF ".gitignore" /XD ".git" /XF "UpdateLog.txt" /XD ".vscode"
Rename-Item -Path "$env:TEST_PATH\$env:MACH_NAME.mlde" -NewName "$env:MACH_NAME_TEST.mlde"
Rename-Item -Path "$env:TEST_PATH\$env:MACH_NAME.ini" -NewName "$env:MACH_NAME_TEST.ini"
ROBOCOPY . "$env:SRC_PATH\bin\$env:MACH_NAME\" /E /XF "*.bat" /XF "*.yml" /XF ".gitignore" /XD ".git" /XF "UpdateLog.txt" /XD ".vscode"
echo "-----------------------"
echo " Compilazione file *.lua 32/64bit"
echo "-----------------------"
$FileList = Get-ChildItem * -Include( "*.mlpe", "*.mlse")
ForEach ($File in $FileList) {
$FileName = Split-Path $File -leaf
lua54 -o $env:SRC_PATH\bin\$env:MACH_NAME\$FileName -s $FileName
echo "lua54 -o bin\$FileName -s $FileName"
}
# helper recupero nome macchina e costruttore
.machName-fix: &machName-fix
- |
echo "-----------------------"
echo " Recupero nome macchina e costruttore"
echo "-----------------------"
$fileName = dir *.mlde
$env:MACH_NAME = $fileName.BaseName
$env:MACH_NAME_TEST = $env:MACH_NAME + ".TEST"
$comp = $fileName.BaseName -split "-"
$env:MANUFACTURER = $comp[0]
Write-Output $env:MANUFACTURER
# helper calcolo versione
.version-fix: &version-fix
- |
echo "-----------------------"
echo " Calcolo versione"
echo "-----------------------"
# calcolo versione formato stringa
$fPath = "$env:MACH_NAME.mlde";
$vLine = Select-String -path $fPath -Pattern '^PP_VER';
$comp = $vLine -split "=";
$env:MACH_VERS = $comp[1].Replace("'","").Trim()
# display versione formato stringa
Write-Output $env:MACH_VERS
# calcolo versione formato numerico
$fPath = "$env:MACH_NAME.mlde";
$vLine = Select-String -path $fPath -Pattern '^PP_NVER';
$comp = $vLine -split "=";
$env:MACH_VERS_NUM = $comp[1].Replace("'","").Trim()
# display versione formato numerico
Write-Output $env:MACH_VERS_NUM
# helper calcolo versione se develop
.version-fix_DEV: &version-fix_DEV
- |
echo "-----------------------"
echo " Calcolo versione - DEV"
echo "-----------------------"
$commitAuthor = $CI_COMMIT_AUTHOR -split " "
$commitAuthor = $commitAuthor[0].Trim()
$env:MACH_VERS = $commitAuthor
# display versione
Write-Output $env:MACH_VERS
# helper creazione folders
.folder-fix: &folder-fix
- |
echo "-----------------------"
echo " Creazione cartelle su macchina virtuale"
echo "-----------------------"
$env:TOOLS_MACHINE_PATH = "$env:MACHINES_PATH_R\$env:MANUFACTURER\_DefaultMachineSetup\$env:MACH_NAME"
Write-Output $env:TOOLS_MACHINE_PATH
$env:SRC_PATH = "$env:TEMP_PATH\$env:MACH_NAME\$env:MACH_VERS\$env:MACH_NAME";
$env:BASE_PATH = "$env:TEMP_PATH\$env:MACH_NAME\$env:MACH_VERS";
$env:TEST_PATH = "$env:TEMP_PATH\$env:MACH_NAME\$env:MACH_VERS\$env:MACH_NAME_TEST";
Write-Output $env:BASE_PATH;
if (Test-Path $env:BASE_PATH) { Remove-Item -Path "$env:BASE_PATH\*" -R -Force };
Write-Output $env:TEST_PATH;
# helper compressione e pulizia folders
.ZipClean: &ZipClean
- |
" Compressione file su macchina virtuale"
$7zipPath = $env:ProgramFiles+"\7-Zip\7z.exe";
if (-not (Test-Path -Path $7zipPath -PathType Leaf)) {
throw "7 zip file '$7zipPath' not found"
}
Set-Alias 7zip $7zipPath
$Target = "$env:BASE_PATH\$env:MACH_NAME.zip"
cd "$env:SRC_PATH\bin\"
$Source = "*"
7zip a -tzip $Target $Source
Write-Output "called ZIP $Source --> $Target"
# helper invio notifica a log versioni online (LiMan)
.SendToVersionsLog: &SendToVersionsLog
- |
echo "-----------------------"
echo " Invio versione a log online"
echo "-----------------------"
$tags = ""
$date = ""
# se critico scrive tag
if ( $CI_COMMIT_MESSAGE | Select-String -Pattern $env:CRITICAL_STRING) {
$tags = "CRITICAL"
$date = (Get-Date).AddDays(1).toString("yyyy-MM-ddTHH:mm:ss.fffZ")
}
else
{
$date = (Get-Date).AddDays(3).toString("yyyy-MM-ddTHH:mm:ss.fffZ")
}
$body =
@{
codInst = "EgalWare"
codApp = $env:MACH_NAME
uplAppId = "UpdateManager"
masterKey = $LiMan_Key
tipo = "Machine"
versNum = $env:MACH_VERS_NUM
versText = $env:MACH_VERS
releaseDate = $date
relTags = $tags
}
$jsonBody = ConvertTo-Json -InputObject $body
echo $jsonBody
Invoke-WebRequest -Method Post -URI $env:URL_VERSIONS_LOG -ContentType "application/json" -Body $jsonBody -UseBasicParsing
# helper esecuzione test
.RunTest: &RunTest
- |
Write-Output "Test done!"
stages:
- build
# - test
# - deploy
LuaCompile:build:
stage: build
only:
- main
- master
tags:
- win
before_script:
- *machName-fix
- *version-fix
- *folder-fix
script:
- *CreateBaseFolder
- *LuaCompile
- *ZipClean
- *ReplicaR
- *ReplicaStor01
- *SendToVersionsLog
LuaCompileDev:build:
stage: build
only:
- develop
tags:
- win
before_script:
- *machName-fix
- *version-fix_DEV
- *folder-fix
script:
- *CreateBaseFolder
- *LuaCompile
- *ZipClean
- *ReplicaR_DEV
# LuaCompile:test:
# stage: test
# needs: ["LuaCompile:build"]
# only:
# - main
# - master
# - develop
# tags:
# - win
# before_script:
# - *version-fix
# - *folder-fix
# script:
# - *LuaCompile
# - *RunTest
# LuaCompile:deploy:
# stage: deploy
# needs: ["LuaCompile:test"]
# only:
# - main
# - master
# tags:
# - win
# before_script:
# - *version-fix
# - *folder-fix
# script:
# - *LuaCompile
# - *ZipClean
# - *ReplicaR
+14 -120
View File
@@ -5,15 +5,14 @@ EgtOutLog( ' PF1250-BeamData started')
-- Tabella per definizione modulo
local BeamData = {
RIGHT_LOAD = false, -- flag carico da destra
RIGHT_LOAD = false, -- flag carico da destra
SIMUL_VIEW_DIR = 2, -- direzione di vista predefinita per la simulazione (1=NW, 2=SW, 3=NE, 4=SE)
MIN_WIDTH = 40, -- larghezza minima del grezzo
MIN_HEIGHT = 40, -- altezza minima del grezzo
MAX_WIDTH = 1300, -- larghezza massima del grezzo
MAX_HEIGHT = 600, -- altezza massima del grezzo
LEN_SHORT_PART = 1200, -- lunghezza massima pezzo piccolo
LEN_VERY_SHORT_PART = 800, -- lunghezza massima pezzo molto corto (molto probabile lo scarico a caduta)
MAX_RAW = 26000, -- massima lunghezza grezzo (deve essere minore di LenTable - RAW_OFFSET)
MAX_RAW = 20000, -- massima lunghezza grezzo (deve essere minore di LenTable - RAW_OFFSET)
STD_RAW = 14000, -- lunghezza standard della barra di grezzo
OVM_HEAD = 10, -- sovramateriale testa
OVM_MID = 5.4, -- sovramateriale intermedio (spessore lama)
@@ -41,7 +40,6 @@ local BeamData = {
DRILL_TOL = 0.2, -- tolleranza tra diametro foro e diametro punta
DRILL_VZ_MIN = - 0.51, -- componente limite in Z del versore di un foro
DRILL_VX_MAX = 0.867, -- componente limite in X del versore di un foro sulle facce laterali
MAX_ANGLE_DRILL_CUT = 15, -- delta angolo massimo tra foro e taglio che lo attraversa
DRILL_OVERLAP = 5, -- sovrapposizione tra due mezze forature
MILL_OVERLAP = 5, -- sovrapposizione tra due mezze fresature
MAX_DIST_HTFEA = 50.0, -- massima distanza di feature da testa o coda per essere considerata tale
@@ -69,23 +67,22 @@ local BeamData = {
DH_MAX_TOP = 370, -- quota massima raggiungibile dalla testa da sotto dal sotto del pezzo
KIOTP = 2, -- coefficiente moltiplicativo per attacco/uscita lama tangente anzichè perpendicolare
MAXDIAM_POCK_CORNER = 30, -- diametro massimo utensile ammesso per tasche con angoli interni
USE_LONGCUT = true, -- per i tagli longitudinali usare solo la lavorazione di lama LongCut
USE_LONGCUT = false, -- per i tagli longitudinali usare solo la lavorazione di lama LongCut
ADVANCE_TAIL_CUT = true, -- per spostare prima del taglio di separazione il taglio di coda su pezzi corti con robabile caduta
ADVANCE_TAIL_OFFS = 5, -- accorciamento taglio di coda avanzato (minimo 1)
ADVANCE_TAIL_OFFS = 5, -- accorciamento taglio di coda avanzato (minimo 1)
DOUBLE_HEAD_DOVETAIL = true, -- flag abilitazione lavorazione mortase a coda di rondine in doppio
DOUBLE_HEAD_MORTISE = true, -- flag abilitazione lavorazione mortase in doppio
DOUBLE_HEAD_DRILLING = true, -- flag abilitazione forature in doppio
PRECUT_HEAD = true, -- flag abilitazione pretaglio grezzo a zero in testa
PRECUT_TAIL = true, -- flag abilitazione pretaglio grezzo a zero in coda
MIN_HEIGHT_ADDED_CUTS = 400, -- altezza minima pezzo per effettuare tagli orizzontali aggiuntivi in testa e coda
DOUBLE_HEAD_DRILLING = true -- flag abilitazione forature in doppio
}
---------------------------------------------------------------------
-- Aggiornamento con dati da TechnoEssetre7
local sTs3Data = EgtGetStringFromIni( 'Beam', 'DATA_DIR', "C:\\TechnoEssetre7\\EgtData", EgtGetIniFile()).."\\Essetre-PF1250MAX.data"
local sDataBeam = EgtGetCurrMachineDir().."\\Beam\\Ts3Data.lua"
local sTs3Data = EgtGetStringFromIni( 'Beam', 'DATA_DIR', "C:\\TechnoEssetre7\\EgtData", EgtGetIniFile()).."\\Essetre-PF1250.data"
local sDataBeam = EgtGetSourceDir().."\\Ts3Data.lua"
local sDataWall = EgtGetCurrMachineDir()..'\\Wall\\Ts3Data.lua'
if EgtExistsFile( sTs3Data) then
EgtCopyFile( sTs3Data, sDataBeam)
EgtCopyFile( sTs3Data, sDataWall)
local sTs3DataOld = sTs3Data..'.old'
EgtEraseFile( sTs3DataOld)
EgtRenameFile( sTs3Data, sTs3DataOld)
@@ -97,9 +94,6 @@ if EgtExistsFile( sDataBeam) then
if Machine.Offsets.DOUBLE_HEAD_DOVETAIL then BeamData.DOUBLE_HEAD_DOVETAIL = ( Machine.Offsets.DOUBLE_HEAD_DOVETAIL == 1) end
if Machine.Offsets.DOUBLE_HEAD_POCKET then BeamData.DOUBLE_HEAD_MORTISE = ( Machine.Offsets.DOUBLE_HEAD_POCKET == 1) end
if Machine.Offsets.DOUBLE_HEAD_DRILLING then BeamData.DOUBLE_HEAD_DRILLING = ( Machine.Offsets.DOUBLE_HEAD_DRILLING == 1) end
if Machine.Offsets.PRECUT_HEAD_DISABLE then BeamData.PRECUT_HEAD = ( Machine.Offsets.PRECUT_HEAD_DISABLE == 0) end
if Machine.Offsets.PRECUT_TAIL_DISABLE then BeamData.PRECUT_TAIL = ( Machine.Offsets.PRECUT_TAIL_DISABLE == 0) end
if Machine.Offsets.MIN_HEIGHT_ADDED_CUTS then BeamData.MIN_HEIGHT_ADDED_CUTS = min( Machine.Offsets.MIN_HEIGHT_ADDED_CUTS, BeamData.MIN_HEIGHT_ADDED_CUTS) end
BeamData.MINRAW_S = max( BeamData.MINRAW_S, Machine.Offsets.MINRAW_S or BeamData.MINRAW_S)
BeamData.MINRAW_L = max( BeamData.MINRAW_L, Machine.Offsets.MINRAW_L or BeamData.MINRAW_L)
BeamData.CUT_EXTRA = Machine.Offsets.CUT_EXTRA or BeamData.CUT_EXTRA
@@ -107,16 +101,6 @@ if EgtExistsFile( sDataBeam) then
BeamData.DIM_STRIP_SMALL = Machine.Offsets.DIM_STRIP_SMALL or BeamData.DIM_STRIP_SMALL
BeamData.DIM_TO_CENTER_STRIP = Machine.Offsets.DIM_TO_CENTER_STRIP or BeamData.DIM_TO_CENTER_STRIP
BeamData.MAXDIAM_POCK_CORNER = Machine.Offsets.MAXDIAM_POCK_CORNER or BeamData.MAXDIAM_POCK_CORNER
BeamData.LONGCUT_ENDLEN = Machine.Offsets.LONGCUT_ENDLEN or BeamData.LONGCUT_ENDLEN
BeamData.LONGCUT_MAXLEN = Machine.Offsets.LONGCUT_MAXLEN or BeamData.LONGCUT_MAXLEN
BeamData.ADVANCE_TAIL_OFFS = Machine.Offsets.ADVANCE_TAIL_OFFS or BeamData.ADVANCE_TAIL_OFFS
BeamData.LEN_VERY_SHORT_PART = Machine.Offsets.LEN_VERY_SHORT_PART or BeamData.LEN_VERY_SHORT_PART
BeamData.LEN_SHORT_PART = Machine.Offsets.LEN_SHORT_PART or BeamData.LEN_SHORT_PART
BeamData.OVM_MID = Machine.Offsets.OVM_MID or BeamData.OVM_MID
if Machine.Offsets.MAX_ANGLE_DRILL_CUT then BeamData.MAX_ANGLE_DRILL_CUT = EgtClamp( Machine.Offsets.MAX_ANGLE_DRILL_CUT, 1, 89) end
if Machine.Offsets.CUT_SIC then BeamData.CUT_SIC = EgtClamp( Machine.Offsets.CUT_SIC, 15, 50) end
if Machine.Offsets.MIN_JOIN_S then BeamData.MIN_JOIN_S = EgtClamp( Machine.Offsets.MIN_JOIN_S, 80, 150) end
if Machine.Offsets.MIN_JOIN_L then BeamData.MIN_JOIN_L = EgtClamp( Machine.Offsets.MIN_JOIN_L, 300, 450) end
end
if Machine.Trave then
BeamData.MIN_WIDTH = Machine.Trave.XMIN or BeamData.MIN_WIDTH
@@ -194,105 +178,15 @@ end
BeamData.GetMinUnloadableRaw = GetMinUnloadableRaw
---------------------------------------------------------------------
local function GetBlockedAxis( sHead, nToolType, sBlockedAxis)
-- lama
if nToolType == MCH_TY.SAW_STD or nToolType == MCH_TY.SAW_FLAT then
if sHead == 'H22' then
if sBlockedAxis == 'parallel' then
return 'A2=0'
elseif sBlockedAxis == 'perpendicular' then
return 'A2=90'
end
else
return ''
end
-- sega a catena
elseif nToolType == MCH_TY.MORTISE_STD then
if sHead == 'H13' then
if sBlockedAxis == 'parallel' then
return 'A1=0'
elseif sBlockedAxis == 'perpendicular' then
return 'A1=90'
end
else
return ''
end
-- fresa
elseif nToolType == MCH_TY.MILL_STD or nToolType == MCH_TY.MILL_NOTIP then
return ''
-- punta
elseif nToolType == MCH_TY.DRILL_STD or nToolType == MCH_TY.DRILL_LONG then
return ''
local function GetChainSawBlockedAxis( nInd)
if nInd == 1 then
return 'A1=90'
else
return ''
return 'A1=0'
end
end
BeamData.GetBlockedAxis = GetBlockedAxis
BeamData.GetChainSawBlockedAxis = GetChainSawBlockedAxis
---------------------------------------------------------------------
local function GetMinNzTopBladeDownUp( b3Raw, vtNFace, vtToolDirection)
return -0.484
end
---------------------------------------------------------------------
local function GetSetupInfo( sHead)
local SetupInfo = {}
-- dati comuni
SetupInfo.bIsCSymmetrical = true
SetupInfo.dCAxisEncumbrance = 180
SetupInfo.bToolOnAggregate = false
-- testa 5 assi da sopra
if sHead == 'H11' then
SetupInfo.HeadType = { bTop = true, bBottom = false}
SetupInfo.PreferredSide = {}
SetupInfo.GetMinNz = function() return sin( -35) end
-- lama su aggregato testa 5 assi da sopra
elseif sHead == 'H12' then
SetupInfo.HeadType = { bTop = true, bBottom = false}
SetupInfo.PreferredSide = {}
SetupInfo.GetMinNz = function() return sin( -35) end
-- se con aggregato si considera non simmetrico
SetupInfo.bIsCSymmetrical = false
-- riduzione massimo materiale se usato in tagli orizzontali con affondamento verticale
SetupInfo.dMaxMatDecrease = 25
SetupInfo.GetMinNzDownUp = GetMinNzTopBladeDownUp
-- seconda lama su aggregato testa 5 assi da sopra
elseif sHead == 'H16' then
SetupInfo.HeadType = { bTop = true, bBottom = false}
SetupInfo.PreferredSide = {}
SetupInfo.GetMinNz = function() return sin( -35) end
-- se con aggregato si considera non simmetrico
SetupInfo.bIsCSymmetrical = false
-- riduzione massimo materiale se usato in tagli orizzontali con affondamento verticale
SetupInfo.dMaxMatDecrease = 25
SetupInfo.GetMinNzDownUp = GetMinNzTopBladeDownUp
-- motosega
elseif sHead == 'H13' then
SetupInfo.HeadType = { bTop = true, bBottom = false}
SetupInfo.PreferredSide = {}
SetupInfo.GetMinNz = function() return 0 end
SetupInfo.dZSafeDelta = 60
-- testa 5 assi da sotto
elseif sHead == 'H21' then
SetupInfo.HeadType = { bTop = false, bBottom = true}
SetupInfo.PreferredSide = {}
SetupInfo.GetMaxNz = function() return sin( 25) end
-- lama su aggregato testa 5 assi da sotto
elseif sHead == 'H22' then
SetupInfo.HeadType = { bTop = false, bBottom = true}
SetupInfo.PreferredSide = {}
SetupInfo.GetMaxNz = function() return sin( 25) end
-- se con aggregato si considera non simmetrico
SetupInfo.bIsCSymmetrical = false
-- riduzione massimo materiale se usato in tagli orizzontali con affondamento verticale
SetupInfo.dMaxMatDecrease = 25
end
return SetupInfo
end
BeamData.GetSetupInfo = GetSetupInfo
---------------------------------------------------------------------
return BeamData
-5
View File
@@ -10,10 +10,6 @@
2=Drill_H2
3=Pocket
4=Pocket_H2
5=Predrill
6=Predrill_H2
7=AngleDrill
8=AngleDrill_H2
[Milling]
1=Prof
@@ -51,7 +47,6 @@
33=AntiSplintMillCut_H2
34=SideMillAsBlade
35=SideMillAsBlade_H2
36=Prof_end
[Pocketing]
1=Pocket
-3
View File
@@ -1,3 +0,0 @@
[BEAM]
StartOffset=0
Offset=0
-36
View File
@@ -1,36 +0,0 @@
REM Compilazione degli script macchina Egaltech 2024.02.22
REM Per togliere info di debug aggiungere flag -s prima del nome del file di input
REM Compilazione 32 bit e copia file da non compilare
@echo off
REM chiedo all'utente la versione da assegnare alla macchina da compilare
set /p "machineVersion=Inserisci versione: "
REM variabili per costruire i percorsi delle cartelle
set "machineName=Essetre-PF1250MAX"
set "deployFolder=C:\MachinesDeploy"
set "machinePath=%deployFolder%\%machineName%\"
set "fullPathSource=%deployFolder%\%machineName%\%machineVersion%\%machineName%"
set "fullPathZip=%deployFolder%\%machineName%\%machineVersion%"
REM elimino eventuale cartella esistente
rmdir /s /Q %fullPathZip%
REM copio i sorgenti nel percorso di destinazione
ROBOCOPY . %fullPathSource%\ /E /XF "Compile.bat" /XF ".gitignore" /XD ".git" /XF "UpdateLog.txt"
REM copio i sorgenti nel percorso temporaneo per i compilati
ROBOCOPY . %fullPathSource%\bin\%machineName%\ /E /XF "Compile.bat" /XF ".gitignore" /XD ".git" /XF "UpdateLog.txt" /XD ".vscode"
REM copio i file compilati nel percorso temporaneo per i compilati
\EgtProg\Dll32\luac54 -o %fullPathSource%\bin\%machineName%\Common_PF1250.mlpe -s Common_PF1250.mlpe
\EgtProg\Dll32\luac54 -o %fullPathSource%\bin\%machineName%\Common_PF1250.mlse -s Common_PF1250.mlse
\EgtProg\Dll32\luac54 -o %fullPathSource%\bin\%machineName%\Common_PF1250.TPA.mlpe -s Common_PF1250.TPA.mlpe
REM comprimo i file compilati in uno zip pronto per essere distribuito
tar.exe acvf %fullPathZip%\%machineName%.zip -C %fullPathSource%\bin\ %machineName%\*.*
REM elimino il percorso temporaneo
rmdir /s /Q %fullPathSource%\bin\
File diff suppressed because it is too large Load Diff
File diff suppressed because it is too large Load Diff
+92 -282
View File
@@ -1,71 +1,12 @@
-- Special Operations macchina Essetre-PF1250 by Egalware s.r.l. 2024/04/09
-- Special Operations macchina Essetre-PF1250 by EgalTech s.r.l. 2023/11/21
-- Intestazioni
require( 'EmtGenerator')
EgtEnableDebug( false)
-- Carico libreria
local BD = require( 'BeamData')
---------------------------------------------------------------------
-- *** Generic Machinings ***
---------------------------------------------------------------------
require( 'EmtGenMachining')
---------------------------------------------------------------------
-- *** Special GetPrevMachiningOffset ***
---------------------------------------------------------------------
-----------------------------------------------------------------------------------------
function OnSpecialGetPrevMachiningOffset()
-- Aggiorno posizione della testa della trave a seguito di movimenti delle pinze non previsti tra le fasi
local function TPosUpdate()
local nClId = EgtGetFirstNameInGroup( EMC.CURRMCHID, 'CL') -- recupero Id del gruppo CL della lavorazione corrente
local nPathId = EgtGetFirstInGroup( nClId or GDB_ID.NULL) -- Id del primo gruppo nella lavorazione (P1)
if not nPathId then
EMC.ERR = 12
EMC.MSG = ' Error : CL group path not found'
return
end
local dAuxMoveCount = EgtGetInfo( nPathId, 'AS#', 'd') or 0 -- numero di movimenti ausiliari
local dTRepos = nil
-- controlla ogni gruppo di movimenti ausiliari
for i = 1, dAuxMoveCount do
local aAuxMove = EgtGetInfo( nPathId, 'AS' .. tostring( i), 'vs') or {} -- array contenete i parametri di ogni gruppo
-- controlla solo i movimenti della testa trave e salva l'ultimo
if aAuxMove[1] == '2' or aAuxMove[1] == '3' then
for j = 2, #aAuxMove do
if aAuxMove[j] == 'T' then
dTRepos = aAuxMove[j+1]
break
end
end
end
end
return dTRepos
end
-- default
EMC.ERR = 0
EMC.PREVOFFSX = 0
-- se c'è cambio di fase tra le lavorazioni (quindi la precedente è l'ultima della sua fase e la corrente la prima)
if EMC.PREVPHASE ~= EMC.CURRPHASE then
-- se la fase corrente è di inizio lavorazione di nuova trave
if IsStartOrRestPhase( EMC.CURRPHASE) then
-- recupero la posizione finale della lavorazione precedente
local vPrevAx = EmtGetFinalAxesPos( EMC.PREVMCHID)
-- ricava se e quanto la trave viene spostata tra le due fasi dai movimenti ausiliari e corregge l'offset di fine fase
local dNewTPos = TPosUpdate()
-- se ci sono dei movimenti della testa trave tra le due fasi ricava il delta tra la vecchia e la nuova posizione
if dNewTPos then
EMC.PREVOFFSX = dNewTPos - vPrevAx[1]
-- oppure la X (L1) di questa corrisponde alla posizione iniziale della nuova trave, se ne deduce l'offset
else
EMC.PREVOFFSX = ParkV1 - vPrevAx[1]
end
end
end
end
-- Carico i dati globali
local sBaseDir = EgtGetSourceDir()
local BD = dofile( sBaseDir .. 'Beam\\BeamData.lua')
---------------------------------------------------------------------
-- *** Special Z moves ***
@@ -103,20 +44,15 @@ function OnSpecialGetMaxZ()
-- Sistemazione dati di input
local vtTp = Vector3d( EMC.TDIRp)
local bFromZmax = false
-- recupero il gruppo
local nSetHead = GetHeadSet( EMC.HEAD)
if vtTp:isSmall() then
vtTp = X_AX()
bFromZmax = true
if nSetHead == 1 then
if EMC.HEAD == 'H11' or EMC.HEAD == 'H14' or EMC.HEAD == 'H12' or EMC.HEAD == 'H16' then
EMC.R1p = ParkC1
EMC.R2p = ParkB1
elseif nSetHead == 2 then
elseif EMC.HEAD == 'H21' then
EMC.R1p = ParkC2
EMC.R2p = ParkB2
elseif nSetHead == 3 then
EMC.R1p = ParkC3
EMC.R2p = ParkB3
end
end
local vtT = Vector3d( EMC.TDIR)
@@ -124,7 +60,7 @@ function OnSpecialGetMaxZ()
local bBSameSign = (( EMC.R2p < 10 and EMC.R2 < 10) or ( EMC.R2p > -10 and EMC.R2 > -10))
-- Calcolo in funzione della testa e dei parametri
if EMC.HEAD == 'H11' then
if EMC.HEAD == 'H11' or EMC.HEAD == 'H14' then
if bBSameSign and vtTp:getX() > -0.1 and vtT:getX() > -0.1 then
EMC.MAXZ = MaxZ1
else
@@ -134,41 +70,37 @@ function OnSpecialGetMaxZ()
elseif EMC.HEAD == 'H12' then
if vtTp:getX() > 0.3 and vtT:getX() > 0.3 then
if bBSameSign and abs( EMC.R1 - EMC.R1p) < 165 then
EMC.MAXZ = MaxZ1Blade - EgtIf( abs( EMC.R2) < 90.1 and abs( EMC.R2p) < 90.1, 0, 130)
EMC.MAXZ = MaxZ1 - EgtIf( abs( EMC.R2) < 90.1 and abs( EMC.R2p) < 90.1, 0, 130)
elseif vtTp:getZ() > 0.707 or vtT:getZ() > 0.707 then
EMC.MAXZ = ParkZ1 + 200
elseif vtTp:getZ() > 0.5 or vtT:getZ() > 0.5 then
EMC.MAXZ = ParkZ1 + 100
else
EMC.MAXZ = ParkZ1 + 1
end
elseif bBSameSign and EMC.R1p > 29.9 and EMC.R1p < 180.1 and EMC.R1 > 29.9 and EMC.R1 < 180.1 and EMC.R2p > -10 and EMC.R2 > -10 then
EMC.MAXZ = MaxZ1Blade - EgtIf( abs( EMC.R2) < 90.1 and abs( EMC.R2p) < 90.1, 0, 130)
EMC.MAXZ = MaxZ1 - EgtIf( abs( EMC.R2) < 90.1 and abs( EMC.R2p) < 90.1, 0, 130)
elseif bBSameSign and EMC.R1p > -0.1 and EMC.R1p < 180.1 and EMC.R1 > -0.1 and EMC.R1 < 180.1 and EMC.R2p > -10 and EMC.R2 > -10 then
local vMZ = {{ Tz=0.85, Ez=440}, { Tz=0.5, Ez=200}, { Tz=-0.01, Ez=5}, { Tz=-0.5, Ez=1}}
EMC.MAXZ = ParkZ1 + CalcExtraZ( vtTpZm, vtT, vMZ)
else
local vMZ = {{ Tz=0.85, Ez=400}, { Tz=0.7, Ez=300}, { Tz=0.5, Ez=195}, { Tz=0.15, Ez=60}, { Tz=-0.01, Ez=5}, { Tz=-0.5, Ez=1}}
local vMZ = {{ Tz=0.85, Ez=400}, { Tz=0.7, Ez=300}, { Tz=0.5, Ez=195}, { Tz=0.15, Ez=70}, { Tz=-0.01, Ez=5}, { Tz=-0.5, Ez=1}}
EMC.MAXZ = ParkZ1 + CalcExtraZ( vtTpZm, vtT, vMZ)
end
elseif EMC.HEAD == 'H16' then
if vtTp:getX() > 0.3 and vtT:getX() > 0.3 then
if bBSameSign and abs( EMC.R1 - EMC.R1p) < 165 then
EMC.MAXZ = MaxZ1Blade - EgtIf( abs( EMC.R2) < 90.1 and abs( EMC.R2p) < 90.1, 0, 130)
EMC.MAXZ = MaxZ1 - EgtIf( abs( EMC.R2) < 90.1 and abs( EMC.R2p) < 90.1, 0, 130)
elseif vtTp:getZ() > 0.707 or vtT:getZ() > 0.707 then
EMC.MAXZ = ParkZ1 + 200
elseif vtTp:getZ() > 0.5 or vtT:getZ() > 0.5 then
EMC.MAXZ = ParkZ1 + 100
else
EMC.MAXZ = ParkZ1 + 1
end
elseif bBSameSign and EMC.R1p > 29.9 and EMC.R1p < 180.1 and EMC.R1 > 29.9 and EMC.R1 < 180.1 and EMC.R2p > -10 and EMC.R2 > -10 then
EMC.MAXZ = MaxZ1Blade - EgtIf( abs( EMC.R2) < 90.1 and abs( EMC.R2p) < 90.1, 0, 130)
EMC.MAXZ = MaxZ1 - EgtIf( abs( EMC.R2) < 90.1 and abs( EMC.R2p) < 90.1, 0, 130)
elseif bBSameSign and EMC.R1p > -0.1 and EMC.R1p < 180.1 and EMC.R1 > -0.1 and EMC.R1 < 180.1 and EMC.R2p > -10 and EMC.R2 > -10 then
local vMZ = {{ Tz=0.85, Ez=440}, { Tz=0.5, Ez=200}, { Tz=-0.01, Ez=5}, { Tz=-0.5, Ez=1}}
EMC.MAXZ = ParkZ1 + CalcExtraZ( vtTpZm, vtT, vMZ)
else
local vMZ = {{ Tz=0.85, Ez=400}, { Tz=0.7, Ez=300}, { Tz=0.5, Ez=195}, { Tz=0.15, Ez=60}, { Tz=-0.01, Ez=5}, { Tz=-0.5, Ez=1}}
local vMZ = {{ Tz=0.85, Ez=400}, { Tz=0.7, Ez=300}, { Tz=0.5, Ez=195}, { Tz=0.15, Ez=70}, { Tz=-0.01, Ez=5}, { Tz=-0.5, Ez=1}}
EMC.MAXZ = ParkZ1 + CalcExtraZ( vtTpZm, vtT, vMZ)
end
elseif EMC.HEAD == 'H21' then
@@ -178,8 +110,6 @@ function OnSpecialGetMaxZ()
local vMZ = {{ Tz=0.85, Ez=390}, { Tz=0.5, Ez=280}, { Tz=-0.01, Ez=160}}
EMC.MAXZ = ParkZ2 + CalcExtraZ( vtTpZm, vtT, vMZ)
end
elseif EMC.HEAD == 'H38' then
EMC.MAXZ = SafeZ3RotAxis
end
end
@@ -200,11 +130,11 @@ function OnSpecialMoveZup()
local dZmax = EgtGetAxisHomePos( EgtIf( nHeadSet ~= 2, 'Z1', 'Z2'))
-- se fresa su testa1 o testa 2
if EMC.HEAD == 'H11' or EMC.HEAD == 'H21' or EMC.HEAD == 'H22' then
-- se fresa su testa1 o su testa 2
if EMC.HEAD == 'H11' or EMC.HEAD == 'H14' or EMC.HEAD == 'H21' then
;
-- se lama
elseif EMC.HEAD == 'H12' or EMC.HEAD == 'H16' then
-- se lama su testa1
elseif EMC.HEAD == 'H12' then
-- riporto i valori tra -179 e + 180
local dCheckAxR1 = EMC.R1
if dCheckAxR1 < -180 then
@@ -212,49 +142,41 @@ function OnSpecialMoveZup()
elseif dCheckAxR1 > 180 then
dCheckAxR1 = dCheckAxR1 - 360
end
-- se lama su testa1
if EMC.HEAD == 'H12' then
-- se inclinata oltre 90 gradi e interferisce con la trave
if ( EMC.R2 > 87.9 and ( dCheckAxR1 < 15.0 or dCheckAxR1 > 180.0)) or ( EMC.R2 < -87.9 and ( dCheckAxR1 > -15.0 and dCheckAxR1 < 180.0)) then
local dZref = dZmax + min( 330 * vtT:getZ(), 0) + 260 * ( 1 - sqrt( 1- vtT:getZ() * vtT:getZ()))
-- se troppo in alto
if EMC.L3 > dZref + 1 then
---- sistemo asse rotante
--EMC.R2 = EgtIf( ( EMC.R2 > 0), 90, -90)
---- ricalcolo versore utensile
--EMC.TDIR = EgtGetCalcToolDirFromAngles( EMC.R1, EMC.R2)
---- porto alla giusta quota
--EMC.L3 = dZmax
EMC.L3 = dZref
-- dichiaro modificato
EMC.MODIF = true
end
end
-- se seconda lama su testa1
elseif EMC.HEAD == 'H16' then
-- se inclinata oltre 90 gradi e interferisce con la trave
if ( EMC.R2 > 87.9 and ( dCheckAxR1 < 15.0 or dCheckAxR1 > 180.0)) or ( EMC.R2 < -87.9 and ( dCheckAxR1 > -15.0 and dCheckAxR1< 180.0)) then
local dZref = dZmax + min( 330 * vtT:getZ(), 0) + 260 * ( 1 - sqrt( 1- vtT:getZ() * vtT:getZ()))
-- se troppo in alto
if EMC.L3 > dZref + 1 then
---- sistemo asse rotante
--EMC.R2 = EgtIf( ( EMC.R2 > 0), 90, -90)
---- ricalcolo versore utensile
--EMC.TDIR = EgtGetCalcToolDirFromAngles( EMC.R1, EMC.R2)
---- porto alla giusta quota
--EMC.L3 = dZmax
EMC.L3 = dZref
-- dichiaro modificato
EMC.MODIF = true
end
-- se inclinata oltre 90 gradi e interferisce con la trave
if ( EMC.R2 > 87.9 and ( dCheckAxR1 < 15.0 or dCheckAxR1 > 180.0)) or ( EMC.R2 < -87.9 and ( dCheckAxR1 > -15.0 and dCheckAxR1 < 180.0)) then
local dZref = dZmax + min( 330 * vtT:getZ(), 0) + 260 * ( 1 - sqrt( 1- vtT:getZ() * vtT:getZ()))
-- se troppo in alto
if EMC.L3 > dZref + 1 then
---- sistemo asse rotante
--EMC.R2 = EgtIf( ( EMC.R2 > 0), 90, -90)
---- ricalcolo versore utensile
--EMC.TDIR = EgtGetCalcToolDirFromAngles( EMC.R1, EMC.R2)
---- porto alla giusta quota
--EMC.L3 = dZmax
EMC.L3 = dZref
-- dichiaro modificato
EMC.MODIF = true
end
end
-- se seconda lama su testa1
elseif EMC.HEAD == 'H16' then
-- se inclinata oltre 90 gradi e interferisce con la trave
if ( EMC.R2 > 87.9 and ( dCheckAxR1 < 15.0 or dCheckAxR1 > 180.0)) or ( EMC.R2 < -87.9 and ( dCheckAxR1 > -15.0 and dCheckAxR1< 180.0)) then
local dZref = dZmax + min( 330 * vtT:getZ(), 0) + 260 * ( 1 - sqrt( 1- vtT:getZ() * vtT:getZ()))
-- se troppo in alto
if EMC.L3 > dZref + 1 then
---- sistemo asse rotante
--EMC.R2 = EgtIf( ( EMC.R2 > 0), 90, -90)
---- ricalcolo versore utensile
--EMC.TDIR = EgtGetCalcToolDirFromAngles( EMC.R1, EMC.R2)
---- porto alla giusta quota
--EMC.L3 = dZmax
EMC.L3 = dZref
-- dichiaro modificato
EMC.MODIF = true
end
end
elseif EMC.HEAD == 'H38' then
EMC.L3 = SafeZ3RotAxis
-- dichiaro modificato
EMC.MODIF = true
else
; -- non si fa nulla
end
end
@@ -269,7 +191,7 @@ local SIC_V = 50 -- sicurezza da testa
local MIN_ENG_V = 115 -- ingombro asse Z
local MIN_ENG_RACK_V = 161 -- ingombro asse Z con cremagliera
local MIN_ENG_XZ2_V = 180 -- ingombro assi XZ sotto
local MIN_Z2_FOR_ENG_XZ2_V = 250 -- quota Z2 da cui considerare ingombro assi XZ sotto
local MIN_Z2_FOR_ENG_XZ2_V = 270 -- quota Z2 da cui considerare ingombro assi XZ sotto
local AGG_V = MinDeltaYV -- ingombro rulli pressori + sicurezza
local MaxLenSmT = 1500 -- massima lunghezza pezzo scaricato con nastri verdi
local DIST_Y1MAX_LOAD = 100 -- distanza carrello Y1 da massimo asse al carico
@@ -327,22 +249,6 @@ local function GetNextStartOrRestPhase( nPhase)
return nNextPhase
end
---------------------------------------------------------------------
local function IsFirstMachiningOfStart( nMchId)
-- se non è fase inizio di pezzo, ritorno risultato negativo
if not IsStartOrRestPhase( EMC.PHASE) then
return false
end
-- recupero la precedente operazione attiva
local nPrevOperId = EgtGetPrevActiveOperation( nMchId)
-- se non esiste o non è una disposizione, ritorno risultato negativo
if not nPrevOperId or EgtGetOperationType( nPrevOperId) ~= MCH_OY.DISP then
return false
end
-- è la prima
return true
end
---------------------------------------------------------------------
local function UpdateMinJoin()
MinJoin = BD.GetMinJoin( EMC.SB, EMC.HB, EMC.LB)
@@ -577,26 +483,8 @@ end
---------------------------------------------------------------------
function OnPostApplyMachining()
-- Inizializzo codice di errore
EMC.ERR = 0
-- Verifico se ultima lavorazione della fase
local nNextOpeId = EgtGetNextActiveOperation( EMC.MCHID)
local bMchLast = ( not nNextOpeId or EgtGetOperationPhase( nNextOpeId) ~= EMC.PHASE) -- Agisco sui diversi percorsi della lavorazione
local nPathId = EgtGetFirstInGroup( EgtGetFirstNameInGroup( EMC.MCHID, 'CL') or GDB_ID.NULL)
while nPathId do
-- recupero id del successivo
nPathId = EgtGetNext( nPathId)
-- verifico se ultimo percorso di ultima lavorazione della fase
local bLast = ( bMchLast and ( not nPathId))
-- se ultimo, elimino ritorno in home
if bLast then EgtRemoveOperationHome( EMC.MCHID) end
end
end
---------------------------------------------------------------------
function OnSpecialApplyMachining()
EgtOutLog( ' Lavorazione : ' .. EgtGetName( EMC.MCHID) .. ' (' .. tostring( EMC.MCHID) .. ')')
EgtOutLog( ' Lavorazione : ' .. EgtGetName( EMC.MCHID), 1)
-- Inizializzo codice di errore
EMC.ERR = 0
@@ -667,11 +555,7 @@ function OnSpecialApplyMachining()
-- Verifico flag di separazione e fase di scarico
local sNotes = EgtGetMachiningParam( MCH_MP.USERNOTES)
-- bPreSplit sempre a falso per obbligare a pinzare il pezzo con 1 morsa anche se iniziato il taglio che dividerà grezzo e finito (in genere per sezioni grandi con 2 tagli di lama)
-- Tra un taglio e l'altro infatti c'e' inversione del braccio e quindi un'apertura delle rulliere. Se pinzano entrambe le pinze, potrebbero esserci problemi di collisone rulli-morse
local bPreSplit = false --( sNotes:find( 'Presplit', 1, true) ~= nil)
local bPreSplit = ( false and sNotes:find( 'Presplit', 1, true) ~= nil)
local bSplitting = ( sNotes:find( 'Split', 1, true) ~= nil)
local bPreCut = ( sNotes:find( 'Precut', 1, true) ~= nil)
local bCutting = ( sNotes:find( 'Cut', 1, true) ~= nil)
@@ -687,7 +571,7 @@ function OnSpecialApplyMachining()
-- verifico se ultimo percorso di ultima lavorazione della fase
local bLast = ( bMchLast and ( not nPathId))
-- se ultimo, elimino ritorno in home
-- if bLast then EgtRemoveOperationHome( EMC.MCHID) end
if bLast then EgtRemoveOperationHome( EMC.MCHID) end
-- salvo lo stato dei carrelli
local OriTPos = EMC.TPOS
local OriY1Delta = EMC.Y1DELTA
@@ -752,14 +636,6 @@ function SpecApplyPath( bPreSplit, bSplitting, bPreCut, bCutting, bUnload)
-- Verifico se lavorazione pareti
local bWall = ( EgtGetInfo( EgtGetCurrMachGroup() or GDB_ID.NULL, 'Wall', 'd') == 1)
-- mi salvo info lavorazione su una lista
local AuxInfoMach = {}
AuxInfoMach.bPreSplit = bPreSplit
AuxInfoMach.bSplitting = bSplitting
AuxInfoMach.bPreCut = bPreCut
AuxInfoMach.bCutting = bCutting
AuxInfoMach.bUnload = bUnload
-- Assegno flag di pezzo separato dal resto del grezzo
SPLIT = IsEndPhase( EMC.PHASE)
@@ -789,7 +665,6 @@ function SpecApplyPath( bPreSplit, bSplitting, bPreCut, bCutting, bUnload)
EMC.SB = b3Tot:getDimY()
EMC.HB = b3Tot:getDimZ()
EMC.LT = b3Raw:getDimX()
EgtOutLog( ' BarLen='..EgtNumToString( EMC.LB, 1), 3)
-- Aggiorno limiti di presa
UpdateMinJoin()
@@ -846,7 +721,7 @@ function SpecApplyPath( bPreSplit, bSplitting, bPreCut, bCutting, bUnload)
local dPosT = LoadT
local vCmd = SpecCalcLoad( dPosT, dDistFront, max( dDistBack, MinJoin, EMC.LB - ( MaxY1 - MinY1) + 6))
EMC.LOAD = true
local vCmd2 = SpecCalcCarriages( dDistFront, dDistBack, dRollFront, dRollBack, dY1DeltaMaxSP, dY2DeltaMinUL, nChar, AuxInfoMach)
local vCmd2 = SpecCalcCarriages( dDistFront, dDistBack, dRollFront, dRollBack, dY1DeltaMaxSP, dY2DeltaMinUL, nChar)
EMC.LOAD = nil
if bSplitting and EMC.ERR == 18 then
table.insert( vCmd, { 22, dRollBack, -dRollFront})
@@ -859,7 +734,7 @@ function SpecApplyPath( bPreSplit, bSplitting, bPreCut, bCutting, bUnload)
-- Se altrimenti non eseguito SPLIT, eseguo calcoli per carrelli
elseif not SPLIT then
local vCmd = SpecCalcCarriages( dDistFront, dDistBack, dRollFront, dRollBack, dY1DeltaMaxSP, dY2DeltaMinUL, nChar, AuxInfoMach)
local vCmd = SpecCalcCarriages( dDistFront, dDistBack, dRollFront, dRollBack, dY1DeltaMaxSP, dY2DeltaMinUL, nChar)
-- Se non ci sono spostamenti, confermo i parametri di aggancio e di posizione roller
if SpecTestOnlyRemarkInCmds( vCmd) then
table.insert( vCmd, { 21, EgtIf( EMC.Y1DELTA, EMC.Y1DELTA, 0), EgtIf( EMC.Y2DELTA, EMC.Y2DELTA, 0)})
@@ -869,7 +744,6 @@ function SpecApplyPath( bPreSplit, bSplitting, bPreCut, bCutting, bUnload)
-- Altrimenti, non muovo i carrelli rispetto alla trave ma impongo la posizione dei rulli
else
SpecOutputCNT()
local vCmd = {}
table.insert( vCmd, { 21, EgtIf( EMC.Y1DELTA, EMC.Y1DELTA, 0), EgtIf( EMC.Y2DELTA, EMC.Y2DELTA, 0)})
table.insert( vCmd, { 22, dRollBack, -dRollFront})
@@ -886,12 +760,6 @@ function SpecApplyPath( bPreSplit, bSplitting, bPreCut, bCutting, bUnload)
if not EMC.Y2DELTA then
EgtOutLog( ' Warning SPLITTING -> separazione con caduta pezzo')
SpecOutputCNT()
-- non funziona ma servirebbe un controllo simile, di modo che non possa avvenire la presenza di un pezzo "FALL" più grande di LEN_VERY_SHORT_PART
--if EMC.LT > LEN_VERY_SHORT_PART then
-- EMC.ERR = 19
-- EMC.MSG = ' Error SPLIT : Y1 or Y2 not clamped'
-- return false
--end
if IsEndPhase( EMC.PHASE + 1) then
EgtSetInfo( NextDispId, 'SKIP', '1')
local NextOpeId = EgtGetNextOperation( NextDispId)
@@ -909,7 +777,7 @@ function SpecApplyPath( bPreSplit, bSplitting, bPreCut, bCutting, bUnload)
return false
end
-- eseguo la separazione
EgtOutLog( 'MaxLenLeft=' .. EgtNumToString( dMaxLenLeft, 1), 1)
EgtOutLog( 'MaxLenLeft=' .. EgtNumToString( dMaxLenLeft, 1))
vCmd = SpecCalcSplit( b3Raw:getDimX(), dMaxLenLeft)
end
-- Se taglio finale di grezzo a perdere
@@ -976,37 +844,24 @@ function SpecialCalcMachiningEncumbrance( nMchId, bPreCut)
for i = 1, #vAxMin do
vAxMid[i] = ( vAxMin[i] + vAxMax[i]) / 2
end
-- recupero il gruppo
local nSetHead = GetHeadSet( sHead)
-- Calcolo dell'ingombro della testa rispetto allo Zero Macchina (assi rotanti fissi, C=4, B=5, A=6)
local b3Enc
if nSetHead == 1 then
if sHead ~= 'H21' then
EgtSetAxisPos( 'C1', vAxMid[4])
EgtSetAxisPos( 'B1', vAxMid[5])
if sHead == 'H13' then
EgtSetAxisPos( 'A1', vAxMid[6])
end
b3Enc = EgtGetBBoxGlob( EgtGetAxisId( 'C1'), GDB_BB.ONLY_VISIBLE)
elseif nSetHead == 2 then
else
EgtSetAxisPos( 'C2', vAxMid[4])
EgtSetAxisPos( 'B2', vAxMid[5])
if sHead == 'H22' then
EgtSetAxisPos( 'A2', vAxMid[6])
end
b3Enc = EgtGetBBoxGlob( EgtGetAxisId( 'C2'), GDB_BB.ONLY_VISIBLE)
else -- testa 3
EgtSetAxisPos( 'C3', vAxMid[4])
EgtSetAxisPos( 'B3', vAxMid[5])
b3Enc = EgtGetBBoxGlob( EgtGetAxisId( 'C3'), GDB_BB.ONLY_VISIBLE)
end
-- Forzo la distanza di sicurezza da utensile
local nSecRollerDist = EgtGetValInNotes( EgtTdbGetCurrToolParam( MCH_TP.USERNOTES), 'SECDIST', 'i') or SIC_V
local dMinFrontEng = EgtIf( nSetHead ~= 2, MIN_ENG_RACK_V, EgtIf( vAxMax[3] < MIN_Z2_FOR_ENG_XZ2_V, MIN_ENG_V, MIN_ENG_XZ2_V))
local dRollFront = max( b3Enc:getMax():getX(), dMinFrontEng) + nSecRollerDist
local dMinBackEng = EgtIf( nSetHead ~= 2, MIN_ENG_V, EgtIf( vAxMax[3] < MIN_Z2_FOR_ENG_XZ2_V, MIN_ENG_V, MIN_ENG_XZ2_V))
local dRollBack = max( -b3Enc:getMin():getX(), dMinBackEng) + nSecRollerDist
local dMinFrontEng = EgtIf( sHead ~= 'H21', MIN_ENG_RACK_V, EgtIf( vAxMax[3] < MIN_Z2_FOR_ENG_XZ2_V, MIN_ENG_V, MIN_ENG_XZ2_V))
local dRollFront = max( b3Enc:getMax():getX(), dMinFrontEng) + SIC_V
local dMinBackEng = EgtIf( sHead ~= 'H21', MIN_ENG_V, EgtIf( vAxMax[3] < MIN_Z2_FOR_ENG_XZ2_V, MIN_ENG_V, MIN_ENG_XZ2_V))
local dRollBack = max( -b3Enc:getMin():getX(), dMinBackEng) + SIC_V
EgtOutLog( ' RollFront = ' .. EgtNumToString( dRollFront, 1) .. ' RollBack = ' .. EgtNumToString( dRollBack, 1), 3)
-- Calcolo della posizione della Punta Utensile rispetto allo Zero Macchina
local ptTip
@@ -1102,11 +957,7 @@ function SpecCalcLoad( dPosT, dDistFront, dDistBack)
local dNewY1min = max( EMC.LB - dDistBack, MinOther + AggLoad + EMC.HCING + EMC.HOVM)
local dNewY1max = min( ( MaxY1 - MinY1) - 5, EMC.LB - MinJoin)
if dNewY1min > dNewY1max then return nil end
-- minimo posizionamento pinza 1 per permettere scarico del restante
local dMinLengthRestToUnload = abs( MinY1) + abs( MinV1) + abs( MaxV2) + abs( MaxY2) + MinJoin + AggLoad + EMC.LT + 10
-- calcolo posizionamento con i coefficienti, ma verifico che sia tra il minimo e il massimo pinzabile
local dNewY1DeltaMax = EgtClamp( 0.25 * dNewY1min + 0.75 * dNewY1max, dMinLengthRestToUnload, dNewY1max)
local dNewY1Delta = EgtClamp( BD.CHAR_LOAD_DIST or 3000, 0.75 * dNewY1min + 0.25 * dNewY1max, dNewY1DeltaMax)
local dNewY1Delta = EgtClamp( BD.CHAR_LOAD_DIST or 3000, 0.75 * dNewY1min + 0.25 * dNewY1max, 0.25 * dNewY1min + 0.75 * dNewY1max)
local dNewY2Delta = nil
local dNewY1 = dPosT + dNewY1Delta
local vCmd = {}
@@ -1150,7 +1001,7 @@ function SpecCalcLoad( dPosT, dDistFront, dDistBack)
end -- SpecAdjustLoad [L]
---------------------------------------------------------------------
function SpecCalcCarriages( dDistFront, dDistBack, dRollFront, dRollBack, dY1DeltaMaxSP, dY2DeltaMinUL, nChar, AuxInfoMach)
function SpecCalcCarriages( dDistFront, dDistBack, dRollFront, dRollBack, dY1DeltaMaxSP, dY2DeltaMinUL, nChar)
local MinFrontJoin = MinJoin + EMC.HCING + EMC.HOVM
local MyMinOther = MinOther + EgtIf( EMC.CNT == 1, AggLoad, 0)
@@ -1184,19 +1035,11 @@ function SpecCalcCarriages( dDistFront, dDistBack, dRollFront, dRollBack, dY1Del
WorkTab.dY1DeltaMaxF = min( EMC.LB - MinJoin, MaxY1 + dDistFront + dRollFront + AGG_V)
WorkTab.dY2DeltaMinF = nil
WorkTab.dY2DeltaMaxF = nil
if dY1DeltaMaxSP then WorkTab.dY1DeltaMaxF = min( WorkTab.dY1DeltaMaxF, dY1DeltaMaxSP) end
WorkTab.dV1PosF = dRollBack
WorkTab.bV1CloseF = false
WorkTab.dV2PosF = -dRollFront
WorkTab.bV2CloseF = false
-- dopo che si è calcolato il minimo e massimo dell'intervallo, verifico che in testa rimanga almeno il minimo per poter fare passaggio pinze e scaricare
if AuxInfoMach and ( AuxInfoMach.bSplitting or AuxInfoMach.bCutting) then
if WorkTab.dY1DeltaMaxF - WorkTab.dY1DeltaMinF > 1.5 * BD.CHAR_EXTRA_DIST and WorkTab.dY1DeltaMaxF > EMC.LT + BD.MINRAW_S + BD.CHAR_EXTRA_DIST then
WorkTab.dY1DeltaMinF = max( min( EMC.LT + BD.MINRAW_S, WorkTab.dY1DeltaMaxF - 1), WorkTab.dY1DeltaMinF + EMC.LT)
end
end
-- verifico validità intervallo ammesso per Y1
if WorkTab.dY1DeltaMinF > WorkTab.dY1DeltaMaxF + 10 * GEO.EPS_SMALL then
EMC.ERR = 18
@@ -1204,8 +1047,8 @@ function SpecCalcCarriages( dDistFront, dDistBack, dRollFront, dRollBack, dY1Del
return {}
end
-- al carico o con prima lavorazione di un pezzo si deve ignorare l'ingombro delle lavorazioni di testa per il pinzaggio
if EMC.LOAD or IsFirstMachiningOfStart( EMC.MCHID) then EMC.HCING = 0 end
-- al carico si deve ignorare l'ingombro delle lavorazioni di testa per il pinzaggio
if EMC.LOAD then EMC.HCING = 0 end
return SpecAdjustCarriages( WorkTab)
@@ -1226,22 +1069,13 @@ function SpecCalcCarriages( dDistFront, dDistBack, dRollFront, dRollBack, dY1Del
WorkTab.dY1DeltaMaxF = min( EMC.LB - MinJoin, MaxY1 + dDistFront + dRollFront + AGG_V)
WorkTab.dY2DeltaMinF = max( MinJoin + EMC.HCING + EMC.HOVM, EMC.LB + MinY2 - dMyDistBack - AGG_V - dRollBack)
WorkTab.dY2DeltaMaxF = min( dDistFront, EMC.LB - MyMinOther) -- - EMC.TCING
if dY1DeltaMaxSP and dY1DeltaMaxSP > WorkTab.dY1DeltaMinF then
WorkTab.dY1DeltaMaxF = min( WorkTab.dY1DeltaMaxF, dY1DeltaMaxSP)
end
if dY1DeltaMaxSP then WorkTab.dY1DeltaMaxF = min( WorkTab.dY1DeltaMaxF, dY1DeltaMaxSP) end
if dY2DeltaMinUL then WorkTab.dY2DeltaMinF = max( WorkTab.dY2DeltaMinF, dY2DeltaMinUL) end
WorkTab.dV1PosF = dRollBack
WorkTab.bV1CloseF = false
WorkTab.dV2PosF = -dRollFront
WorkTab.bV2CloseF = false
-- dopo che si è calcolato il minimo e massimo dell'intervallo, verifico che in testa rimanga almeno il minimo per poter fare passaggio pinze e scaricare
if AuxInfoMach and ( AuxInfoMach.bSplitting or AuxInfoMach.bCutting) then
if WorkTab.dY1DeltaMaxF - WorkTab.dY1DeltaMinF > 1.5 * BD.CHAR_EXTRA_DIST and WorkTab.dY1DeltaMaxF > EMC.LT + BD.MINRAW_S + BD.CHAR_EXTRA_DIST then
WorkTab.dY1DeltaMinF = max( min( EMC.LT + BD.MINRAW_S, WorkTab.dY1DeltaMaxF - 1), WorkTab.dY1DeltaMinF)
end
end
-- verifico validità intervallo ammesso per Y1
if WorkTab.dY1DeltaMinF > WorkTab.dY1DeltaMaxF + 10 * GEO.EPS_SMALL then
EMC.ERR = 18
@@ -1387,11 +1221,8 @@ function SpecCalcUnload()
EgtOutLog( ' *[U1]', 1)
end
local vCmd = {}
-- Tipo di scarico
local bStdUl = ( not MaxUnloadLen or MaxUnloadLen < 1 or EMC.LB - EMC.HOVM < MaxUnloadLen + 1)
-- Commento
table.insert( vCmd, { 0, 'Unloading', EgtIf( bStdUl, 'Unloading', 'Manual Unloading')})
table.insert( vCmd, { 0, 'Unloading'})
-- posizionamento sicuro teste e rulli (non serve ?)
--table.insert( vCmd, { 4, 0})
-- Se pinza Y chiusa, la apro
@@ -1399,15 +1230,11 @@ function SpecCalcUnload()
table.insert( vCmd, { 11, 0})
EMC.CNT = nil
end
-- Se non supero la lunghezza massima di scarico, sposto il pezzo in posizione di scarico
if bStdUl then
local dFinT = EgtIf( EMC.LB < MaxLenSmT, UnloadSmT, UnloadT) - EMC.LB
local dFinY2 = dFinT + EMC.Y2DELTA
table.insert( vCmd, { 2, 'T', dFinT, 'Y2', dFinY2})
EgtOutLog( ' Y2PosF=' .. EgtNumToString( dFinY2), 1)
else
table.insert( vCmd, { 1, 'Y2', MaxY2, 'Manual Unloading'})
end
-- Sposto il pezzo in posizione di scarico
local dFinT = EgtIf( EMC.LB < MaxLenSmT, UnloadSmT, UnloadT) - EMC.LB
local dFinY2 = dFinT + EMC.Y2DELTA
table.insert( vCmd, { 2, 'T', dFinT, 'Y2', dFinY2})
EgtOutLog( ' Y2PosF=' .. EgtNumToString( dFinY2), 1)
-- apro la morsa
table.insert( vCmd, { 12, 0})
-- riporto il carrello in home
@@ -1423,30 +1250,21 @@ end
---------------------------------------------------------------------
local function ChangedTool( nMchId)
local nChanged = 0
local bChanged = false
-- Salvo lavorazione e utensile correnti, per ripristinarli alla fine
local nOrigMchId = EgtGetCurrMachining()
local sOrigTool = EgtTdbGetCurrToolParam( MCH_TP.NAME)
local sOrigBlockedAx = EgtGetMachiningParam( MCH_MP.BLOCKEDAXIS)
-- Recupero l'utensile della lavorazione precedente
local nPrevMchId = EgtGetPrevActiveOperation( nMchId or GDB_ID.NULL)
if nPrevMchId and EgtGetOperationType( nPrevMchId) ~= MCH_OY.DISP then
EgtSetCurrMachining( nPrevMchId)
local sTool = EgtGetMachiningParam( MCH_MP.TOOL)
nChanged = EgtIf( sTool ~= sOrigTool, 1 , 0)
local sBlockedAx = EgtGetMachiningParam( MCH_MP.BLOCKEDAXIS)
-- se stesso utensile, ma modo caricamento diverso, è come se fosse un cambio utensile. Vale solo se aggregato su lama da sotto.
if sTool == sOrigTool then
local sHead = EgtTdbGetCurrToolParam( MCH_TP.HEAD)
if sHead == 'H22' and sOrigBlockedAx ~= sBlockedAx then
nChanged = 2
end
end
bChanged = ( sTool ~= sOrigTool)
end
-- Ripristino lavorazione e utensile correnti
if nOrigMchId then EgtSetCurrMachining( nOrigMchId) end
if sOrigTool then EgtTdbSetCurrTool( sOrigTool) end
return nChanged
return bChanged
end
--------------------------------------------------------------------------------------------------------
@@ -1455,9 +1273,9 @@ end
function SpecAdjustCarriages( WorkTab)
--EgtOutLog( ' --->>> CNT=' .. EgtIf( EMC.CNT, '1', '_'))
local bChangedTool = ChangedTool( EMC.MCHID)
-- Aggiorno la posizione dei rulli per eventuale cambio utensile
if bChangedTool ~= 0 then
if ChangedTool( EMC.MCHID) then
WorkTab.dV1PosI = ParkV1
WorkTab.dV2PosI = ParkV2
end
@@ -1466,24 +1284,15 @@ function SpecAdjustCarriages( WorkTab)
if WorkTab.dY1DeltaI then
local dY1DeltaLim = MinJoin + WorkTab.dV1PosI - WorkTab.dV2PosI + 2 * AGG_V + EMC.HCING + EMC.HOVM + EgtIf( EMC.CNT == 1, AggLoad, 0)
if WorkTab.dY1DeltaI <= dY1DeltaLim or ( WorkTab.dY1DeltaMaxF and WorkTab.dY1DeltaMaxF <= dY1DeltaLim) then
bCloseV = true
bCloseV = true
end
end
if WorkTab.dY2DeltaI then
local dY2DeltaLim = MinJoin + WorkTab.dV1PosI - WorkTab.dV2PosI + 2 * AGG_V
if EMC.LB - WorkTab.dY2DeltaI <= dY2DeltaLim or ( WorkTab.dY2DeltaMinF and EMC.LB - WorkTab.dY2DeltaMinF <= dY2DeltaLim) then
bCloseV = true
bCloseV = true
end
end
-- se ho cambiato modo di prendere utensile, forzo chiusura
if bChangedTool == 2 then
bCloseV = true
end
-- se i pezzi del cliente sono molto storti, si forza la chiusura per evitare che vada a sbattere. Se parametro non presente, si chiude solo se necessario
if ForceToCloseRollersGate then
bCloseV = true
end
WorkTab.bCloseV = bCloseV
-- |POSIZIONO Y1| **[A]**
@@ -1800,7 +1609,7 @@ local function PosY1FromY2B( TabI, vCmd)
end
-- questo movimento serve solo a gestire (in modo complesso) il caso [ri]
MaxDispl( TabI, vCmd, 'M4')
else
else
-- **[rp]** = raggiungo il punto medio Y1New dell'intervallo
EmitComment( vCmd, '[Y1B-rp] ')
if not SpecTestSomeMoveInCmds( vCmd) and not EMC.Y2DELTA then
@@ -1901,7 +1710,7 @@ local function PosY1Y2A( TabI, vCmd)
PosY1FromY2A( TabI, vCmd)
bXW = false
end
else
else
-- in **accentramento**
-- sempre se intervallo per Y2 raggiungibile in una sola fase
if ( TabI.dTPosI + TabI.dY2DeltaMinF) - TabI.MaxY2V2 < TabI.dY1PosI - TabI.MyMinY1V1 then
@@ -1996,7 +1805,7 @@ local function PosY1Y2B( TabI, vCmd)
end
end
nCnt = nCnt + 1
if nCnt > 10 then return end
if nCnt > 5 then return end
until ( not bXW)
-- chiusura/parcheggio dei trascinatori in funzioni chiamanti
local dY1Delta = TabI.dY1PosI - TabI.dTPosI
@@ -2060,6 +1869,7 @@ local function PosY2Y1A( TabI, vCmd)
MaxDispl( TabI, vCmd, 'M1')
end
end
until ( not bXW)
-- chiusura/parcheggio dei trascinatori in funzioni chiamanti
local dY1Delta = TabI.dY1PosI - TabI.dTPosI
@@ -2127,14 +1937,14 @@ local function PosY2Y1B( TabI, vCmd)
if TabI.dY2PosI > MinY2 and
TabI.dY2PosI > TabI.dTPosI + MinJoin + EMC.HOVM + EMC.HCING - 10 * GEO.EPS_SMALL then
-- allontanamento morse, trascinamento trave con Y2
MaxDispl( TabI, vCmd, 'M2')
MaxDispl( TabI, vCmd, 'M2')
else
-- accentramento morse, trascinamento trave con Y1
MaxDispl( TabI, vCmd, 'M3')
end
end
nCnt = nCnt + 1
if nCnt > 10 then return end
if nCnt > 5 then return end
until ( not bXW)
-- la chiusura delle morse è fatta sopra
local dY1Delta = TabI.dY1PosI - TabI.dTPosI
@@ -2302,8 +2112,8 @@ function SpecAdjustCarrB1( WorkTab)
if not SpecTestSomeMoveInCmds( vCmd) then
table.insert( vCmd, { 3, 'Y1', dY1PosI, 'Y2', dY2PosI, 'T', WorkTab.dTPosI, EMC.CNT})
end
table.insert( vCmd, { 12, 1}) -- Chiudo Y2
table.insert( vCmd, { 11, 1}) -- chiudo Y1
table.insert( vCmd, { 12, 1}) -- Chiudo Y2
-- imposto i nuovi parametri di aggancio
table.insert( vCmd, { 21, dY1DeltaF, dY2DeltaF})
EgtOutLog( ' Y1DeltaF=' .. EgtNumToString( dY1DeltaF) .. ' Y2DeltaF=' .. EgtNumToString( dY2DeltaF), 1)
@@ -2374,8 +2184,8 @@ function SpecAdjustCarrB2( WorkTab)
if not SpecTestSomeMoveInCmds( vCmd) then
table.insert( vCmd, { 3, 'Y1', dY1PosI, 'Y2', dY2PosI, 'T', WorkTab.dTPosI, EMC.CNT})
end
table.insert( vCmd, { 12, 1}) -- Chiudo Y2
table.insert( vCmd, { 11, 1}) -- chiudo Y1
table.insert( vCmd, { 12, 1}) -- Chiudo Y2
-- imposto i nuovi parametri di aggancio
table.insert( vCmd, { 21, dY1DeltaF, dY2DeltaF})
EgtOutLog( ' Y1DeltaF=' .. EgtNumToString( dY1DeltaF) .. ' Y2DeltaF=' .. EgtNumToString( dY2DeltaF), 1)
@@ -2435,7 +2245,7 @@ function SpecAdjustCarrC( WorkTab)
WorkTab.dY1DeltaMaxF = EMC.LB - ( MinJoin + MyTCING)
-- se Y1 deve accentrarsi
if WorkTab.dY1DeltaI > WorkTab.dY1DeltaMaxF then
WorkTab.dY1DeltaMinF = EMC.LB - 2 * MinJoin - MyTCING
WorkTab.dY1DeltaMinF = EMC.LB - 2 * MinJoin + MyTCING
end
end
-- posizioni obiettivo dei carrelli al centro dei rispettivi intervalli di validità
@@ -2536,11 +2346,11 @@ function SpecOutputCmds( vCmd, bEnd)
EgtSetInfo( EMC.PATHID, sKey, sInfo)
-- movimento di 1 asse
elseif Cmd[1] == 1 then
local sInfo = '1,'..Cmd[2]..','..EgtNumToString( Cmd[3],3)..EgtIf( Cmd[4], ','..tostring(Cmd[4]), '')
local sInfo = '1,'..Cmd[2]..','..EgtNumToString( Cmd[3],3)..EgtIf( Cmd[4], ',*', '')
EgtSetInfo( EMC.PATHID, sKey, sInfo)
-- movimento di 2 assi
elseif Cmd[1] == 2 then
local sInfo = '2,'..Cmd[2]..','..EgtNumToString( Cmd[3],3)..','..Cmd[4]..','..EgtNumToString( Cmd[5],3)..EgtIf( Cmd[6], ','..tostring(Cmd[6]), '')
local sInfo = '2,'..Cmd[2]..','..EgtNumToString( Cmd[3],3)..','..Cmd[4]..','..EgtNumToString( Cmd[5],3)..EgtIf( Cmd[6], ',*', '')
EgtSetInfo( EMC.PATHID, sKey, sInfo)
-- movimento di 3 assi
elseif Cmd[1] == 3 then
Binary file not shown.
+4
View File
@@ -20,6 +20,8 @@ H11.1=Standard.nge
H11.1:MILL_NOTIP=MillNoTip.nge
H12.1=Saw.nge
H13.1=ChainSaw.nge
H14.1=Standard.nge
H14.1:MILL_NOTIP=MillNoTip.nge
H16.1=Saw.nge
H21.1=Standard.nge
H21.1:MILL_NOTIP=MillNoTip.nge
@@ -51,6 +53,8 @@ H11=6608
H12=6615
; Chainsaw
H13=6616
; 5 axis head
H14=6608
; 5 axis second saw
H16=6623
; Second 5 axis bottom head
+95 -309
View File
@@ -1,31 +1,16 @@
-- Descrizione macchina Essetre-PF1250MAX by EgalWare s.r.l. 2024/03/28
-- Descrizione macchina Essetre-PF1250MAX by EgalWare s.r.l. 2023/12/07
-- 2023/12/07 ver 2.5l1 Prima versione. Derivata da PF1250 ver 2.5l4
-------------------------------------
-- NOTE VERSIONI SUCCESSIVE IN GIT --
-------------------------------------
-- 2023/12/15 ver 2.5l2 Corretti vari offset in simulazione
-- Intestazioni
require( 'EmtGenerator')
EgtEnableDebug( false)
PP_VER = '3.1e1'
PP_NVER = '3.1.5.1'
MIN_MACH_VER = '2.7d2'
MACH_NAME = EgtGetCurrMachineName()
PP_VER = '2.5l2'
MIN_MACH_VER = '2.5k1'
-- Carico i dati globali
local sMachDir = EgtGetCurrMachineDir()
-- Elimino direttori altre macchine e imposto direttorio macchina corrente per ricerca librerie
EgtRemoveBaseMachineDirFromPackagePath()
EgtAddToPackagePath( sMachDir .. '\\Beam\\?.lua')
EgtAddToPackagePath( sMachDir .. '\\?.lua')
INFO_STD_PP = require( 'Version')
-- prendo la versione kernel minima necessaria piu' nuova tra macchina e script comuni
if INFO_STD_PP.MIN_MACH_VER_PP_COMMON > MIN_MACH_VER then
MIN_MACH_VER = INFO_STD_PP.MIN_MACH_VER_PP_COMMON
end
EgtOutLog ( '** ' .. MACH_NAME..' '..PP_VER..' ** ( '..INFO_STD_PP.NAME..': '..INFO_STD_PP.VERSION..' - MinMach: '.. MIN_MACH_VER ..') **', 1)
EgtOutLog ( '** Essetre-PF1500rl '..PP_VER..' (MinMach '.. MIN_MACH_VER ..') **', 1)
-- Parametri macchina
NumericalControl = 'TPA' -- NUM o TPA
@@ -79,8 +64,7 @@ SawB2Offs = 0
MinX1 = 0
MaxX1 = 3300
MinZ1 = -1850
MaxZ1 = 0
MaxZ1Blade = -100
MaxZ1 = -100
MinC1 = -275
MaxC1 = 275
MinB1 = -127
@@ -88,30 +72,24 @@ MaxB1 = 127
MinB1b = -119
MaxB1b = 119
ParkX1 = 250
ParkTc1X1 = 250
ParkTc2X1 = 3100
ParkZ1 = -525
ParkZ1 = -535
ParkC1 = -90
ParkB1 = -90
ParkCSawX1 = 1700
ParkCSawZ1 = -100
ParkCSawX1 = 1500
ParkCSawZ1 = -200
ParkCSaw0Z1 = -400
ParkCSawC1 = -90
ParkCSaw0C1 = 0
ParkCSawB1 = 0
MinLengthLongCSaw = 580 -- gestione speciale per motosega molto lunga. Lunghezza al di sopra della quale è considerata motosega lunga
ParkLongCSawZ1 = -50 -- gestione speciale per motosega molto lunga. Parcheggio asse Z
ParkLongCSawC1 = 0 -- gestione speciale per motosega molto lunga. Parcheggio asse C
ParkLongCSawB1 = -90 -- gestione speciale per motosega molto lunga. Parcheggio asse B
LongTool = 390
LongTool = 400
ParkLongTc1C1 = 0
ParkLongTc2C1 = -180
ParkLongB1 = 0
MinZ1ToChangeH2 = -1400
MinX2 = -2760
MaxX2 = 0
MinZ2 = 0
MaxZ2 = 1450
MaxZ2 = 795
MinC2 = -275
MaxC2 = 275
MinB2 = -127
@@ -119,16 +97,15 @@ MaxB2 = 127
MinB2b = -119
MaxB2b = 119
ParkX2 = -100
SafeX2 = -200
SafeX2RotAxis = -1000
SafeX2 = -400
ParkZ2 = 0
ParkC2 = -90
ParkB2 = -90
ParkSawX2 = MinX2
ParkSawX2 = 1000
ParkSawZ2 = 0
ParkSaw0Z2 = 0
ParkSawC2 = -90
ParkSaw0C2 = -90
ParkSaw0C2 = 0
ParkSawB2 = 0
MinDistToolX1X2 = 40
TurnerOffs = 120.0
@@ -137,34 +114,24 @@ DeltaTabY = 2550
DeltaTabZ = -1428 + MillOffs -- per TPA : -1128.0 + MillOffs -- per NUM : -1258
DeltaRulliTraveZ = -1203
DimTabY = 1400
DimTabX = 34000
DimTabX = 24000
Delta2TabY = -1185.9
Delta2TabZ = 693 - Mill2Offs -- per TPA : 378.0 - Mill2Offs -- per NUM : 223
Delta2TabZ = 393 - Mill2Offs -- per TPA : 378.0 - Mill2Offs -- per NUM : 223
Head2X = 0
Head2Y = DeltaTabY - Delta2TabY
Head2Z = DeltaTabZ - Delta2TabZ
DefTcPos1 = 'T1'
DefTcPos2 = 'T220'
DefTcPos2 = 'T300'
CoeffVM = 0.5
MinForzaPinze = 400 -- [Kgf]
MaxForzaPinze = 1000 -- [Kgf]
Tc2Active = true -- magazzino prima sega a catena
SecondSaw = true -- seconda lama su aggregato su TC3 presente
SecondChain = true -- magazzino seconda sega a catena
TcSpecialTools = true -- magazzino per utensili speciali. In genere truciolatore
TcAggreBladeUnder = true -- lama su aggregato per testa da sotto
EmitAccClamps = true
WriteAllCoordsOnFirstM101 = true
ForceToCloseRollersGate = false
Motors23KW = false
EstimationRapidMultiplier = 1
DistZClampToTable = 5 -- distanza tra la tavola e il punto più basso della morsa
ClampingCoeffMin = nil -- coefficiente di fissaggio, se 0 o nil non fa controllo, per il momento da inizializzare da Ts3Data
TcSpecialTools = true -- magarzzino per utensili speciali. In genere truciolatore
-- Aggiornamento con dati da TechnoEssetre7
local sTs3Data = EgtGetStringFromIni( 'Beam', 'DATA_DIR', "C:\\TechnoEssetre7\\EgtData", EgtGetIniFile()).."\\Essetre-PF1250MAX.data"
local sDataBeam = sMachDir.."\\Beam\\Ts3Data.lua"
local sDataWall = sMachDir.."\\Wall\\Ts3Data.lua"
local sTs3Data = EgtGetStringFromIni( 'Beam', 'DATA_DIR', "C:\\TechnoEssetre7\\EgtData", EgtGetIniFile()).."\\Essetre-PF1250.data"
local sDataBeam = EgtGetSourceDir().."\\Beam\\Ts3Data.lua"
local sDataWall = EgtGetSourceDir().."\\Wall\\Ts3Data.lua"
if EgtExistsFile( sTs3Data) then
EgtCopyFile( sTs3Data, sDataBeam)
EgtCopyFile( sTs3Data, sDataWall)
@@ -179,10 +146,8 @@ if EgtExistsFile( sDataBeam) then
--NumericalControl = EgtIf( Machine.Offsets.TIPO_CN == 0, 'NUM', 'TPA')
if Machine.Offsets.X1_POS then MinX1 = -Machine.Offsets.X1_POS end
if Machine.Offsets.X1_NEG then MaxX1 = -Machine.Offsets.X1_NEG end
if Machine.Offsets.PARK_X1 then ParkX1 = Machine.Offsets.PARK_X1 end
if Machine.Offsets.Z1_NEG then MinZ1 = Machine.Offsets.Z1_NEG end
if Machine.Offsets.Z1_POS then MaxZ1 = min( MaxZ1, Machine.Offsets.Z1_POS) end
if Machine.Offsets.Z1_POS_LAMA then MaxZ1Blade = min( MaxZ1Blade, Machine.Offsets.Z1_POS_LAMA) end
if Machine.Offsets.PARK_Z1 then ParkZ1 = Machine.Offsets.PARK_Z1 end
if Machine.Offsets.C1_NEG then MinC1 = Machine.Offsets.C1_NEG end
if Machine.Offsets.C1_POS then MaxC1 = Machine.Offsets.C1_POS end
@@ -192,17 +157,13 @@ if EgtExistsFile( sDataBeam) then
if Machine.Offsets.B1_POS1 then MaxB1b = Machine.Offsets.B1_POS1 end
if Machine.Offsets.X2_NEG then MinX2 = Machine.Offsets.X2_NEG end
if Machine.Offsets.X2_POS then MaxX2 = Machine.Offsets.X2_POS end
if Machine.Offsets.PARK_X2 then ParkX2 = Machine.Offsets.PARK_X2 end
if Machine.Offsets.Z2_POS then MinZ2 = -Machine.Offsets.Z2_POS end
if Machine.Offsets.Z2_NEG then MaxZ2 = -Machine.Offsets.Z2_NEG end
if Machine.Offsets.PARK_Z2 then ParkZ2 = -Machine.Offsets.PARK_Z2 end
if Machine.Offsets.PARK_Z2_INLAV then ParkInLavZ2 = -Machine.Offsets.PARK_Z2_INLAV end
if Machine.Offsets.C2_NEG then MinC2 = Machine.Offsets.C2_NEG end
if Machine.Offsets.C2_POS then MaxC2 = Machine.Offsets.C2_POS end
if Machine.Offsets.B2_NEG then MinB2 = Machine.Offsets.B2_NEG end
if Machine.Offsets.B2_POS then MaxB2 = Machine.Offsets.B2_POS end
if Machine.Offsets.B2_NEG1 then MinB2b = Machine.Offsets.B2_NEG1 end
if Machine.Offsets.B2_POS1 then MaxB2b = Machine.Offsets.B2_POS1 end
if Machine.Offsets.MIN_Y1 then MinMchY1 = Machine.Offsets.MIN_Y1 end
if Machine.Offsets.MAX_Y1 then MaxMchY1 = Machine.Offsets.MAX_Y1 end
if Machine.Offsets.PARK_Y1 then ParkMchY1 = Machine.Offsets.PARK_Y1 end
@@ -219,12 +180,10 @@ if EgtExistsFile( sDataBeam) then
if Machine.Offsets.DIST_UNLOAD then UnloadT = Machine.Offsets.DIST_UNLOAD end
if Machine.Offsets.PIVOT_T1 then MillOffs = Machine.Offsets.PIVOT_T1 end
if Machine.Offsets.PIVOT_T2 then Mill2Offs = Machine.Offsets.PIVOT_T2 end
if Machine.Offsets.OFFSETCLAMAT1 then SawC1Offs= Machine.Offsets.OFFSETCLAMAT1 end
if Machine.Offsets.OFFSETBLAMAT1 then SawB1Offs= Machine.Offsets.OFFSETBLAMAT1 end
if Machine.Offsets.OFFSETCLAMAT2 then Saw2C1Offs= Machine.Offsets.OFFSETCLAMAT2 end
if Machine.Offsets.OFFSETBLAMAT2 then Saw2B1Offs= Machine.Offsets.OFFSETBLAMAT2 end
if Machine.Offsets.OFFSETCLAMAUNDER then SawUnderC2Offs= Machine.Offsets.OFFSETCLAMAUNDER end
if Machine.Offsets.OFFSETBLAMAUNDER then SawUnderB2Offs= Machine.Offsets.OFFSETBLAMAUNDER end
if Machine.Offsets.OFFSETCLAMAT1 then SawC1Offs = Machine.Offsets.OFFSETCLAMAT1 end
if Machine.Offsets.OFFSETBLAMAT1 then SawB1Offs = Machine.Offsets.OFFSETBLAMAT1 end
if Machine.Offsets.OFFSETCLAMAT2 then Saw2C1Offs = Machine.Offsets.OFFSETCLAMAT2 end
if Machine.Offsets.OFFSETBLAMAT2 then Saw2B1Offs = Machine.Offsets.OFFSETBLAMAT2 end
if Machine.Offsets.OFFSETXT1 then DeltaTabY = -Machine.Offsets.OFFSETXT1 end
if Machine.Offsets.OFFSETZT1 then DeltaTabZ = Machine.Offsets.OFFSETZT1 + MillOffs end
if Machine.Offsets.OFFSETXT2 then Delta2TabY = Machine.Offsets.OFFSETXT2 end
@@ -235,22 +194,8 @@ if EgtExistsFile( sDataBeam) then
if Machine.Offsets.SAWOFFSZ then SawOffsZ = Machine.Offsets.SAWOFFSZ end
if Machine.Offsets.SAW2OFFSX then Saw2OffsX = Machine.Offsets.SAW2OFFSX end
if Machine.Offsets.SAW2OFFSZ then Saw2OffsZ = Machine.Offsets.SAW2OFFSZ end
if Machine.Offsets.SAWUNDEROFFSY then SawUnderOffsY = Machine.Offsets.SAWUNDEROFFSY end
if Machine.Offsets.SAWUNDEROFFSZ then SawUnderOffsZ = Machine.Offsets.SAWUNDEROFFSZ end
if Machine.Offsets.DEFTCPOS1 then DefTcPos1 = ( 'T' .. Machine.Offsets.DEFTCPOS1) end
if Machine.Offsets.DEFTCPOS2 then DefTcPos2 = ( 'T' .. Machine.Offsets.DEFTCPOS2) end
if Machine.Offsets.MINPRESS then MinForzaPinze = Machine.Offsets.MINPRESS end
if Machine.Offsets.MAXPRESS then MaxForzaPinze = Machine.Offsets.MAXPRESS end
if Machine.Offsets.NOULOAD then MaxUnloadLen = Machine.Offsets.NOULOAD end
if Machine.Offsets.MAXFEEDPINZE then MaxFeedPinze = Machine.Offsets.MAXFEEDPINZE end
if Machine.Offsets.MAXACC then MaxAcc = Machine.Offsets.MAXACC end
if Machine.Offsets.MINACC then MinAcc = Machine.Offsets.MINACC end
if Machine.Offsets.COEFF_STIMATEMPI and Machine.Offsets.COEFF_STIMATEMPI > 0 then EstimationRapidMultiplier = Machine.Offsets.COEFF_STIMATEMPI end
if Machine.Offsets.CHIUDI_PINZE_2_3_SCAMBIO then ForceToCloseRollersGate = Machine.Offsets.CHIUDI_PINZE_2_3_SCAMBIO == 1 end
if Machine.Offsets.WOOD_DENSITY then WoodDensity = Machine.Offsets.WOOD_DENSITY end
if Machine.Offsets.MOTORS23KW then Motors23KW = Machine.Offsets.MOTORS23KW == 1 end
if Machine.Offsets.COEFF_CLAMP_CHECK then ClampingCoeffMin = Machine.Offsets.COEFF_CLAMP_CHECK end
-- aggiustamenti
MinY1 = MinV1 + MinDeltaYV
MaxY1 = MaxMchY1
@@ -261,7 +206,6 @@ if EgtExistsFile( sDataBeam) then
ParkV2 = MinV2
ParkY2 = ParkV2 - MinDeltaYV
UnloadSmT = UnloadT - 300
MaxZ1Blade = min( MaxZ1Blade, -100)
Head2Y = DeltaTabY - Delta2TabY
Head2Z = DeltaTabZ - Delta2TabZ
ParkCSawZ1 = min( ParkCSawZ1, MaxZ1)
@@ -269,7 +213,6 @@ if EgtExistsFile( sDataBeam) then
end
end
SecondSaw = ( SecondSaw and Tc2Active)
local vtOffset23KW = Vector3d( 0, 0, EgtIf( Motors23KW, 37, 0))
EmtGeneral {
File='Essetre-PF1250.nge',
@@ -279,16 +222,13 @@ EmtGeneral {
ExitMaxAdjust = 300,
ExitMaxRotAdj = 0.5,
AngDeltaMinForHome = 80,
LinkAxesMoveOrder = MCH_LKAMO.HEAD_BEFORE_IF_SAME_ANG,
Special = 'Common_PF1250.mlse',
Processor = 'Common_PF1250.mlpe'}
-- in base alla corsa macchina, si carica la rulliera di carico/scarico appropriata
local sGeomConvoyer = EgtIf( MaxY1 > 6500, '_8M', '_5M')
local sBaseAux = {'BASE/SOLID', 'BASE/CONVOYER'..sGeomConvoyer, 'BASE/COLLISION', 'BASE/TC1', 'BASE/TCR', 'BASE/TC3'}
Special = 'Essetre-PF1250.mlse',
Processor = 'Essetre-PF1250.mlpe'}
local sBaseAux = {'BASE/SOLID', 'BASE/CONVOYER', 'BASE/COLLISION', 'BASE/TC1', 'BASE/TCR', 'BASE/TC3'}
if Tc2Active then table.insert( sBaseAux, 5, 'BASE/TC2') end
if TcSpecialTools then table.insert( sBaseAux, 'BASE/TC4') end
if SecondChain then table.insert( sBaseAux, 'BASE/TC5') end
if TcAggreBladeUnder then table.insert( sBaseAux, 'BASE/TCS') end
local BaseId = EmtBase {
Name = 'Base',
Geo = 'BASE/GEO',
@@ -304,9 +244,9 @@ local X1Id = EmtAxis {
Home = ParkX1,
Invert = true,
Geo = 'X1_AXIS/GEO',
Aux = {'X1_AXIS/SOLID', 'X1_AXIS/COLLISION'}}
Aux = 'X1_AXIS/SOLID'}
-- *** Testa 1 ***
local Z1Id = EmtAxis {
EmtAxis {
Name = 'Z1',
Parent = 'X1',
Token = 'Z',
@@ -326,8 +266,8 @@ EmtAxis {
Pos = Point3d(0.0,0.0,503.0),
Stroke = {MinC1, MaxC1},
Home = ParkC1,
Geo = EgtIf( Motors23KW, 'C1_AXIS_23KW/GEO', 'C1_AXIS/GEO'),
Aux = {EgtIf( Motors23KW, 'C1_AXIS_23KW/SOLID', 'C1_AXIS/SOLID'), EgtIf( Motors23KW, 'C1_AXIS_23KW/COLLISION', 'C1_AXIS/COLLISION')}}
Geo = 'C1_AXIS/GEO',
Aux = {'C1_AXIS/SOLID', 'C1_AXIS/COLLISION'}}
EmtAxis {
Name = 'B1',
Parent = 'C1',
@@ -337,8 +277,8 @@ EmtAxis {
Pos = Point3d(-108.4,0.0,MillOffs),
Stroke = {MinB1, MaxB1},
Home = ParkB1,
Geo = EgtIf( Motors23KW, 'B1_AXIS_23KW/GEO', 'B1_AXIS/GEO'),
Aux = {EgtIf( Motors23KW, 'B1_AXIS_23KW/SOLID', 'B1_AXIS/SOLID'), EgtIf( Motors23KW, 'B1_AXIS_23KW/COLLISION', 'B1_AXIS/COLLISION')}}
Geo = 'B1_AXIS/GEO',
Aux = {'B1_AXIS/SOLID', 'B1_AXIS/COLLISION'}}
-- Frese
local H11Id = EmtHead {
Name = 'H11',
@@ -368,6 +308,23 @@ local H12Id = EmtHead {
Geo = 'H12_HEAD/GEO'}
EgtSetInfo( H12Id, 'ZEXTRA', '160,60')
EgtSetInfo( H12Id, 'ZMAXONROT', '1,190')
-- Utensili speciali
if TcSpecialTools then
local H14Id = EmtHead {
Name = 'H14',
Parent = 'B1',
HSet = 'H11',
Type = MCH_HT.STD,
Pos = Point3d(0,0,0),
TDir = Z_AX(),
ADir = -Y_AX(),
Rot1W = 0.2,
Rot2Stroke = { MinB1, MaxB1},
OthColl = {'B1/SOLID', 'C1/SOLID'},
Geo = 'H14_HEAD/GEO'}
EgtSetInfo( H14Id, 'ZEXTRA', '160,60')
EgtSetInfo( H14Id, 'ZMAXONROT', '1,190')
end
-- Lama 2
if SecondSaw then
local H16Id = EmtHead {
@@ -445,8 +402,8 @@ local C2Id = EmtAxis {
Pos = Point3d( Head2X, Head2Y, Head2Z-485),
Stroke = {MinC2, MaxC2},
Home = ParkC2,
Geo = EgtIf( Motors23KW, 'C2_AXIS_23KW/GEO', 'C2_AXIS/GEO'),
Aux = {EgtIf( Motors23KW, 'C2_AXIS_23KW/SOLID', 'C2_AXIS/SOLID'), EgtIf( Motors23KW, 'C2_AXIS_23KW/COLLISION', 'C2_AXIS/COLLISION')}}
Geo = 'C2_AXIS/GEO',
Aux = {'C2_AXIS/SOLID', 'C2_AXIS/COLLISION'}}
local B2Id = EmtAxis {
Name = 'B2',
Parent = 'C2',
@@ -456,8 +413,8 @@ local B2Id = EmtAxis {
Pos = Point3d( Head2X, Head2Y, Head2Z-Mill2Offs),
Stroke = {MinB2, MaxB2},
Home = ParkB2,
Geo = EgtIf( Motors23KW, 'B2_AXIS_23KW/GEO', 'B2_AXIS/GEO'),
Aux = {EgtIf( Motors23KW, 'B2_AXIS_23KW/SOLID', 'B2_AXIS/SOLID'), EgtIf( Motors23KW, 'B2_AXIS_23KW/COLLISION', 'B2_AXIS/COLLISION')}}
Geo = 'B2_AXIS/GEO',
Aux = {'B2_AXIS/SOLID', 'B2_AXIS/COLLISION'}}
EmtAxis {
Name = 'A2',
Parent = 'B2',
@@ -469,12 +426,12 @@ EmtAxis {
Home = 0,
Geo = 'A2_AXIS/GEO'}
local vtMoveZ2 = Vector3d( 0, 0, Head2Z + 1781.0)
EgtMove( EgtGetFirstNameInGroup( Z2Id, 'SOLID'), vtMoveZ2 - vtOffset23KW, GDB_RT.GLOB)
EgtMove( EgtGetFirstNameInGroup( Z2Id, 'COLLISION'), vtMoveZ2 - vtOffset23KW, GDB_RT.GLOB)
local vtMoveX2 = Vector3d( 0, Head2Y - 3735.9, Head2Z + 1781.0)
EgtMove( EgtGetFirstNameInGroup( X2Id, 'SOLID'), vtMoveX2 - vtOffset23KW, GDB_RT.GLOB)
EgtMove( EgtGetFirstNameInGroup( X2Id, 'COLLISION'), vtMoveX2 - vtOffset23KW, GDB_RT.GLOB)
local vtMoveZ2 = Vector3d( 0, 0, Head2Z + 1481.0)
EgtMove( EgtGetFirstNameInGroup( Z2Id, 'SOLID'), vtMoveZ2, GDB_RT.GLOB)
EgtMove( EgtGetFirstNameInGroup( Z2Id, 'COLLISION'), vtMoveZ2, GDB_RT.GLOB)
local vtMoveX2 = Vector3d( 0, Head2Y - 3735.9, Head2Z + 1481.0)
EgtMove( EgtGetFirstNameInGroup( X2Id, 'SOLID'), vtMoveX2, GDB_RT.GLOB)
EgtMove( EgtGetFirstNameInGroup( X2Id, 'COLLISION'), vtMoveX2, GDB_RT.GLOB)
EgtMove( EgtGetFirstNameInGroup( C2Id, 'SOLID'), vtMoveX2, GDB_RT.GLOB)
EgtMove( EgtGetFirstNameInGroup( C2Id, 'COLLISION'), vtMoveX2, GDB_RT.GLOB)
EgtMove( EgtGetFirstNameInGroup( B2Id, 'SOLID'), vtMoveX2, GDB_RT.GLOB)
@@ -493,23 +450,6 @@ local H21Id = EmtHead {
Geo = 'H21_HEAD/GEO'}
EgtSetInfo( H21Id, 'ABOVE', '0')
EgtSetInfo( H21Id, 'ZHOMEDOWN', '1')
-- Lama
if TcAggreBladeUnder then
local H22Id = EmtHead {
Name = 'H22',
Parent = 'A2',
HSet = 'H21',
Type = MCH_HT.STD,
Pos = Point3d( SawUnderOffsX+Head2X, SawUnderOffsY+Head2Y, SawUnderOffsZ+Head2Z),
TDir = Vector3d( 0, sin( SawUnderB2Offs), -cos( SawUnderB2Offs)),
ADir = Y_AX(),
Rot1W = 0.5,
Rot2Stroke = { MinB2b, MaxB2b},
OthColl = {'B2/SOLID', 'C2/SOLID'},
Geo = 'H22_HEAD/GEO'}
EgtSetInfo( H22Id, 'ABOVE', '0')
EgtSetInfo( H22Id, 'ZHOMEDOWN', '1')
end
-- *** Carrelli ***
-- Morse
local Y1Id = EmtAxis {
@@ -531,7 +471,7 @@ local PY1Id = EmtAxis {
Stroke = {0, MaxHoOpen},
Home = MaxHoOpen,
Geo = 'PY1_AXIS/GEO',
Aux = {'PY1_AXIS/SOLID', 'PY1_AXIS/CLAMP_CHECK'}}
Aux = 'PY1_AXIS/SOLID'}
local Y2Id = EmtAxis {
Name = 'Y2',
Parent = 'Base',
@@ -551,7 +491,7 @@ local PY2Id = EmtAxis {
Stroke = {0, MaxHoOpen},
Home = MaxHoOpen,
Geo = 'PY2_AXIS/GEO',
Aux = {'PY2_AXIS/SOLID', 'PY2_AXIS/CLAMP_CHECK'}}
Aux = 'PY2_AXIS/SOLID'}
-- Rulli
local V1Id = EmtAxis {
Name = 'V1',
@@ -621,7 +561,7 @@ EmtAxis {
Type = MCH_AT.LINEAR,
Dir = - X_AX(),
Pos = Point3d(0.0,2450.0,-958.0),
Stroke = {-30000, 30000},
Stroke = {-20000, 20000},
Home = LoadT,
Geo = 'T_AXIS/GEO'}
EmtTable {
@@ -800,7 +740,7 @@ if Tc2Active then
ADir = X_AX(),
Geo = 'BASE/T30'}
end
local ptTc3 = Point3d( 600, 529, -200.8 + ( DeltaTabZ - DeltaRulliTraveZ + 55))
local ptTc3 = Point3d( 480, 529, -200.8 + ( DeltaTabZ - DeltaRulliTraveZ + 55))
EmtTcPos {
Name = 'T101',
Parent = 'Base',
@@ -808,30 +748,22 @@ EmtTcPos {
TDir = -X_AX(),
ADir = Z_AX(),
Geo = 'BASE/T101'}
local ptTc4 = Point3d( 750, 909, -200.8 + ( DeltaTabZ - DeltaRulliTraveZ + 55))
EmtTcPos {
Name = 'T111',
Parent = 'Base',
Pos = ptTc4,
TDir = -X_AX(),
ADir = Z_AX(),
Geo = 'BASE/T111'}
local ptTc5 = Point3d( 750, 1309, -115 + ( DeltaTabZ - DeltaRulliTraveZ + 55))
local ptTc4 = Point3d( 450, 909, -115 + ( DeltaTabZ - DeltaRulliTraveZ + 55))
EmtTcPos {
Name = 'T121',
Parent = 'Base',
Pos = ptTc5,
Pos = ptTc4,
TDir = Z_AX(),
ADir = X_AX(),
Geo = 'BASE/T121'}
local ptTcS = Point3d( -1, -22.3, -1723 + ( DeltaTabZ - DeltaRulliTraveZ + 55))
local ptTc5 = Point3d( 450, 1249, -200.8 + ( DeltaTabZ - DeltaRulliTraveZ + 55))
EmtTcPos {
Name = 'T201',
Parent = 'Base',
Pos = ptTcS + EgtIf( TcAggreBladeUnder, Vector3d( 0, SawUnderOffsY, SawUnderOffsZ), V_NULL()),
TDir = -Z_AX(),
ADir = Y_AX(),
Geo = 'BASE/T201'}
Name = 'T111',
Parent = 'Base',
Pos = ptTc5,
TDir = -X_AX(),
ADir = Z_AX(),
Geo = 'BASE/T111'}
local ptTcR = Point3d( -0.5, 4115, -1871.15 + ( DeltaTabZ - DeltaRulliTraveZ + 55))
EmtTcPos {
Name = 'T220',
@@ -919,22 +851,16 @@ EgtMove( EgtGetFirstNameInGroup( BaseId, 'SIGN') or GDB_ID.NULL, vtMovB, GDB_RT.
EgtMove( EgtGetFirstNameInGroup( BaseId, 'TC1') or GDB_ID.NULL, vtMovB, GDB_RT.GLOB)
EgtMove( EgtGetFirstNameInGroup( BaseId, 'TC2') or GDB_ID.NULL, vtMovB, GDB_RT.GLOB)
EgtMove( EgtGetFirstNameInGroup( BaseId, 'TC3') or GDB_ID.NULL, vtMovB, GDB_RT.GLOB)
if TcSpecialTools then EgtMove( EgtGetFirstNameInGroup( BaseId, 'TC4') or GDB_ID.NULL, vtMovB, GDB_RT.GLOB) end
if SecondChain then EgtMove( EgtGetFirstNameInGroup( BaseId, 'TC5') or GDB_ID.NULL, vtMovB, GDB_RT.GLOB) end
EgtMove( EgtGetFirstNameInGroup( BaseId, 'TC4') or GDB_ID.NULL, vtMovB, GDB_RT.GLOB)
EgtMove( EgtGetFirstNameInGroup( BaseId, 'TC5') or GDB_ID.NULL, vtMovB, GDB_RT.GLOB)
EgtMove( EgtGetFirstNameInGroup( BaseId, 'TCR') or GDB_ID.NULL, vtMovB, GDB_RT.GLOB)
if TcSpecialTools then EgtMove( EgtGetFirstNameInGroup( BaseId, 'TCS') or GDB_ID.NULL, vtMovB, GDB_RT.GLOB) end
EgtMove( EgtGetFirstNameInGroup( X1Id, 'SOLID'), vtMovB, GDB_RT.GLOB)
EgtMove( EgtGetFirstNameInGroup( X1Id, 'COLLISION'), vtMovB, GDB_RT.GLOB)
EgtMove( EgtGetFirstNameInGroup( Z1Id, 'SOLID'), vtOffset23KW, GDB_RT.GLOB)
EgtMove( EgtGetFirstNameInGroup( Z1Id, 'COLLISION'), vtOffset23KW, GDB_RT.GLOB)
local vtMove = Vector3d( 0, ( DeltaTabY - 2550.0), ( DeltaTabZ + 1258.0))
EgtMove( EgtGetFirstNameInGroup( BaseId, 'CONVOYER'..sGeomConvoyer), vtMove, GDB_RT.GLOB)
EgtMove( EgtGetFirstNameInGroup( BaseId, 'CONVOYER'), vtMove, GDB_RT.GLOB)
EgtMove( EgtGetFirstNameInGroup( Y1Id, 'SOLID'), vtMove, GDB_RT.GLOB)
EgtMove( EgtGetFirstNameInGroup( PY1Id, 'SOLID'), vtMove, GDB_RT.GLOB)
EgtMove( EgtGetFirstNameInGroup( PY1Id, 'CLAMP_CHECK'), vtMove + Vector3d(0,0,DistZClampToTable), GDB_RT.GLOB)
EgtMove( EgtGetFirstNameInGroup( Y2Id, 'SOLID'), vtMove, GDB_RT.GLOB)
EgtMove( EgtGetFirstNameInGroup( PY2Id, 'SOLID'), vtMove, GDB_RT.GLOB)
EgtMove( EgtGetFirstNameInGroup( PY2Id, 'CLAMP_CHECK'), vtMove + Vector3d(0,0,DistZClampToTable), GDB_RT.GLOB)
EgtMove( EgtGetFirstNameInGroup( V1Id, 'SOLID'), vtMove, GDB_RT.GLOB)
EgtMove( EgtGetFirstNameInGroup( V1Id, 'COLLISION'), vtMove, GDB_RT.GLOB)
EgtMove( EgtGetFirstNameInGroup( PV1Id, 'SOLID'), vtMove, GDB_RT.GLOB)
@@ -943,8 +869,6 @@ EgtMove( EgtGetFirstNameInGroup( V2Id, 'SOLID'), vtMove, GDB_RT.GLOB)
EgtMove( EgtGetFirstNameInGroup( V2Id, 'COLLISION'), vtMove, GDB_RT.GLOB)
EgtMove( EgtGetFirstNameInGroup( PV2Id, 'SOLID'), vtMove, GDB_RT.GLOB)
EgtMove( EgtGetFirstNameInGroup( QV2Id, 'SOLID'), vtMove, GDB_RT.GLOB)
local vtMoveColl = Vector3d( 0, 0, MaxZ1Blade)
EgtMove( EgtGetFirstNameInGroup( EgtGetFirstNameInGroup( BaseId, 'COLLISION'), 'CEIL'), vtMoveColl, GDB_RT.GLOB)
-- Assegno identificativi alle spie delle morse
PY1LightId = EgtGetFirstNameInGroup( EgtGetFirstNameInGroup( Y1Id, 'SOLID') or GDB_ID.NULL, 'Light')
@@ -958,14 +882,13 @@ PY2LightId = EgtGetFirstNameInGroup( EgtGetFirstNameInGroup( Y2Id, 'SOLID') or G
---------------------------------------------------------------------
function OnSetHead()
-- se testa H11 (fresa)
if EMC.HEAD == 'H11' then
if EMC.HEAD == 'H11' or EMC.HEAD == 'H14' then
local nTc = GetTcForTopHeadTool( EMC.TCPOS)
if nTc ~= 2 then
EmtModifyAxisHome( 'X1', ParkX1)
else
EmtModifyAxisHome( 'X1', ParkTc2X1)
end
EmtModifyAxisStroke( 'Z1', {MinZ1, MaxZ1})
if EMC.TOTLEN < LongTool then
EmtModifyAxisHome( 'Z1', ParkZ1)
EmtModifyAxisStroke( 'C1', {MinC1, MaxC1})
@@ -980,14 +903,13 @@ function OnSetHead()
EmtModifyAxisStroke( 'C1', { ParkLongTc2C1 - 20, ParkLongTc2C1 + 20})
EmtModifyAxisHome( 'C1', ParkLongTc2C1)
end
EmtModifyAxisHome( 'B1', ParkLongB1)
EmtModifyAxisHome( 'B1', ParkB1)
end
EmtModifyAxisDirection( 'B1', X_AX())
-- se testa H12 (lama)
elseif EMC.HEAD == 'H12' then
EmtModifyAxisHome( 'X1', ParkX1)
EmtModifyAxisHome( 'Z1', ParkZ1)
EmtModifyAxisStroke( 'Z1', {MinZ1, MaxZ1Blade})
EmtModifyAxisStroke( 'C1', {MinC1, MaxC1})
EmtModifyAxisHome( 'C1', ParkC1)
EmtModifyAxisHome( 'B1', ParkB1)
@@ -996,12 +918,15 @@ function OnSetHead()
elseif EMC.HEAD == 'H13' then
-- aggiustamenti per distanza
local dDist = EgtIf( EMC.DIST and abs( EMC.DIST) > 1, EMC.DIST, ChSawLen)
EmtModifyExitPosition( EMC.HEAD, EMC.EXIT or 1, Point3d( 0, 0, -dDist))
-- recupero il valore dell'asse virtuale bloccato A
local CSawPosA = GetCurrChainSawingVirtualAxis()
EmtModifyExitPosition( EMC.HEAD, EMC.EXIT, Point3d( 0, 0, -dDist))
local vtMove = Point3d( 0, 0, -dDist) - Point3d( EMC.EXITPOS)
local ExitId = EgtGetFirstNameInGroup( EgtGetHeadId( EMC.HEAD), 'T'..tostring( EMC.EXIT))
EgtMove( ExitId, vtMove)
-- recupero valore asse A bloccato
local sVal = EgtGetMachiningParam( MCH_MP.BLOCKEDAXIS)
CSawPosA = tonumber( sVal:sub( 4) or '')
EmtModifyAxisHome( 'X1', ParkCSawX1)
EmtModifyAxisHome( 'Z1', GetChainSawZHomeFromVirtualAxis( CSawPosA))
EmtModifyAxisStroke( 'Z1', {MinZ1, MaxZ1})
EmtModifyAxisStroke( 'C1', {MinC1, MaxC1})
EmtModifyAxisHome( 'C1', GetChainSawCHomeFromVirtualAxis( CSawPosA))
EmtModifyAxisHome( 'B1', ParkCSawB1)
@@ -1010,27 +935,10 @@ function OnSetHead()
elseif EMC.HEAD == 'H16' then
EmtModifyAxisHome( 'X1', ParkTc2X1)
EmtModifyAxisHome( 'Z1', ParkZ1)
EmtModifyAxisStroke( 'Z1', {MinZ1, MaxZ1Blade})
EmtModifyAxisStroke( 'C1', {MinC1, MaxC1})
EmtModifyAxisHome( 'C1', ParkC1)
EmtModifyAxisHome( 'B1', ParkB1)
EmtModifyAxisDirection( 'B1', Vector3d( cos( Saw2C1Offs), sin( Saw2C1Offs), 0))
-- se testa H21 (fresa sotto)
elseif EMC.HEAD == 'H21' then
if not EMC.TOTDIAM or EMC.TOTDIAM > 300 then
EmtModifyAxisStroke( 'B2', {MinB2b, MaxB2b})
else
EmtModifyAxisStroke( 'B2', {MinB2, MaxB2})
end
EmtModifyAxisHome( 'C2', ParkC2)
EmtModifyAxisDirection( 'B2', X_AX())
-- se testa H22 (lama su aggregato sotto)
elseif EMC.HEAD == 'H22' then
-- recupero valore asse A2 bloccato
local sVal = EgtGetMachiningParam( MCH_MP.BLOCKEDAXIS) or 'A2=0'
local SawUnderPosA2 = tonumber( sVal:sub( 4) or '') or 0
EmtModifyAxisHome( 'C2', GetSawCHomeFromVirtualAxis( SawUnderPosA2))
EmtModifyAxisDirection( 'B2', Vector3d( cos( SawUnderC2Offs), -sin( SawUnderC2Offs), 0))
end
end
@@ -1050,86 +958,6 @@ function GetTcForTopHeadTool( sTcPos)
end
end
---------------------------------------------------------------------
function GetHeadSet( sHead)
if sHead == 'H11' or sHead == 'H12' or sHead == 'H13' or sHead == 'H16' then
return 1
elseif sHead == 'H21' or sHead == 'H22' then
return 2
else
return 0
end
end
---------------------------------------------------------------------
function GetHeadSetFromTcPos( sTcPos)
local TCPOS_1A = { 'T1', 'T3', 'T4', 'T5', 'T6', 'T7', 'T8', 'T9', 'T10', 'T11', 'T12', 'T13'} -- CU montante DX
local TCPOS_1B = { 'T101', 'T121', 'T111'} -- CU sotto traversa
local TCPOS_1C = { 'T21', 'T22', 'T23', 'T24', 'T25', 'T26', 'T27', 'T28', 'T29', 'T30'} -- CU montante sinistro
local TCPOS_2A = { 'T220', 'T221', 'T222', 'T223', 'T224', 'T225', 'T226', 'T227', 'T228', 'T229', 'T230'} -- CU margherita testa 2
local TCPOS_2B = { 'T201'} -- CU lama su aggregato testa 2
for _, sVal in ipairs( TCPOS_1A) do
if sVal == sTcPos then return 1, 1 end
end
for _, sVal in ipairs( TCPOS_1B) do
if sVal == sTcPos then return 1, 2 end
end
for _, sVal in ipairs( TCPOS_1C) do
if sVal == sTcPos then return 1, 3 end
end
for _, sVal in ipairs( TCPOS_2A) do
if sVal == sTcPos then return 2, 1 end
end
for _, sVal in ipairs( TCPOS_2B) do
if sVal == sTcPos then return 2, 2 end
end
return 0, 0
end
---------------------------------------------------------------------
-- Funzione che ritorna bool per dire se esiste o meno al testa richiesta
function IsHeadExisting( nHeadSet)
if nHeadSet == 1 then
return H11Id ~= nil
elseif nHeadSet == 2 then
return H21Id ~= nil
elseif nHeadSet == 3 then
return H31Id ~= nil
else
return ''
end
end
---------------------------------------------------------------------
-- Funzione che ritorna il nome della testa in base alla posizione utensile (ATT: deve rispecchiare il setup)
function GetAdjHeadFromTcPos( nHeadSet, sTcPos)
if nHeadSet == 1 then
-- seconda lama
if SecondSaw and sTcPos == 'T21' then
return 'H16'
-- utensili speciali
elseif TcSpecialTools and sTcPos == 'T121' then
return 'H11'
-- motoseghe
elseif sTcPos == 'T101' or sTcPos == 'T111' then
return 'H13'
-- utensili standard o prima lama
else
return EgtIf( sTcPos == 'T1', 'H12', 'H11')
end
elseif nHeadSet == 2 then
-- lama su aggregato da sotto
if TcAggreBladeUnder and sTcPos == 'T201' then
return 'H22'
-- utensili standard da sotto
else
return 'H21'
end
else
return ''
end
end
---------------------------------------------------------------------
---------------------------------------------------------------------
-- Funzione che riconosce testa per sega a catena
function HeadIsChainSaw( sHead)
@@ -1139,10 +967,10 @@ end
---------------------------------------------------------------------
-- Funzione che calcola la posizione Home di Z per la sega a catena dal valore dell'asse virtuale
function GetChainSawZHomeFromVirtualAxis( dPosA)
-- se A1=0 -> T101 -> HomeZ = -400
-- se A=0 -> T101 -> HomeZ = -400
if abs( dPosA) < 0.1 then
return ParkCSaw0Z1
-- altrimenti A1=-90 -> T102 o A=90 -> T104 -> HomeZ = -100
-- altrimenti A=-90 -> T102 o A=90 -> T104 -> HomeZ = -100
else
return ParkCSawZ1
end
@@ -1151,10 +979,10 @@ end
---------------------------------------------------------------------
-- Funzione che calcola l'angolo Home di C per la sega a catena dal valore dell'asse virtuale
function GetChainSawCHomeFromVirtualAxis( dPosA)
-- se A1=0 -> T101 -> HomeC = 0
-- se A=0 -> T101 -> HomeC = 0
if abs( dPosA) < 0.1 then
return ParkCSaw0C1
-- altrimenti A1=90 -> T104 -> HomeC = -90
-- altrimenti A=90 -> T104 -> HomeC = -90
else
return ParkCSawC1
end
@@ -1163,10 +991,10 @@ end
---------------------------------------------------------------------
-- Funzione che calcola l'angolo Home di C per la lama su aggregato dal valore dell'asse virtuale
function GetSawCHomeFromVirtualAxis( dPosA)
-- se A2=0 -> 201 -> HomeC = -90
-- se A1=0 -> 201 -> HomeC = 0
if abs( dPosA) < 0.1 then
return ParkSaw0C2
-- altrimenti A2=90 -> T204 -> HomeC = -90
-- altrimenti A1=90 -> T204 -> HomeC = -90
else
return ParkSawC2
end
@@ -1176,7 +1004,7 @@ function GetSawCHomeFromVirtualAxis( dPosA)
-- Funzione che ritorna ZExtra partendo dalla testa e dall'angolo verticale
function GetZExtra( sHead, dAngV)
-- se testa standard
if sHead == 'H11' then
if sHead == 'H11' or sHead == 'H14' then
if abs( dAngV) < 30.1 then
return 400
elseif abs( dAngV) < 45.1 then
@@ -1242,45 +1070,6 @@ function GetPY2Light()
return ( EgtGetInfo( PY2LightId, 'On') == '1')
end
---------------------------------------------------------------------
function GetCurrChainSawingVirtualAxis()
-- recupero il valore dell'asse virtuale bloccato A
local sVal = EgtGetMachiningParam( MCH_MP.BLOCKEDAXIS) or 'A1=0'
local dPosA = tonumber( sVal:sub( 4)) or 0
return dPosA
end
---------------------------------------------------------------------
-- Funzione per impostare la posizione del rinvio flottante
function SetFloatPos( sHead, dPos)
-- recupero Id testa
local nHeadId = EgtGetHeadId( sHead)
if not nHeadId then return false end
-- se ci sono entità flottanti nel ToolHolder
local nRefId = EgtGetFirstNameInGroup( nHeadId, '_T1')
local vtTool = EgtFR( nRefId, GDB_ID.ROOT):getVersZ()
local nObjId = EgtGetFirstGroupInGroup( EgtGetFirstNameInGroup( nHeadId, 'T1'))
local FloatEntities = EgtGetInfoInGroup( nObjId, 'Float')
if FloatEntities and #FloatEntities > 0 then
-- il porta-utensile flottante non può comprimersi più di 10mm
if dPos > 10 then
local sErr = 'Floating Ring compressed more than 10mm'
EmtSetLastError( 1222, sErr)
EgtOutLog( 'Error : ' .. sErr, 1)
end
local dFloat = EgtGetInfo( FloatEntities[1], 'Float', 'd')
if abs( dPos - dFloat) > 10 * GEO.EPS_SMALL then
local vtMove = ( dPos - dFloat) * vtTool
-- sposto tutte le entità flottanti
for i = 1, #FloatEntities do
EgtMove( FloatEntities[i], vtMove, GDB_RT.GLOB)
EgtSetInfo( FloatEntities[i], 'Float', dPos)
end
end
return true
end
return false
end
---------------------------------------------------------------------
-- Funzione per resettare tutte le attivazioni della macchina
@@ -1289,9 +1078,6 @@ function OnResetMachine()
EmtUnlinkAllFixturesFromGroups()
SetPY1Light( false)
SetPY2Light( false)
--resetto eventuale flottante
SetFloatPos( 'H11', 0)
SetFloatPos( 'H21', 0)
-- nascondo Vmill
local nRawId = EgtGetFirstRawPart()
while nRawId do
-59
View File
@@ -1,59 +0,0 @@
; Commento per evitare BOM con UTF-8
;Index = Type, Description, Default Value
; Type : b=boolean, d=double, l=lenght, s=string
[Drilling]
[Sawing]
[Milling]
0=l,MaxElev,0
1=d,OutRaw,0
2=l,SideElev,0
3=d,TrimExt,0
4=s,VtFaceUse,0,0,0
5=s,EdgesFaceUse,0
[Pocketing]
0=l,MaxElev,0
1=b,Open,0
2=d,OpenMinSafe,0
3=d,OpenOutRaw,0
4=l,MaxOptSize,0
5=b,AdjustFeed,1
[Mortising]
0=d,MaxElev,0
[Chiseling]
[SawRoughing]
[SawFinishing]
[GenMachining]
[SurfRoughing]
0=l,MaxElev,1000
1=b,PlaneZ,0
[SurfFinishing]
0=b,SkipMaxDown,1
[5AxMilling]
0=l,LinTol,0.01
1=l,MaxLen,10
2=s,Type,ZigZag
3=d,SideAng,90
4=l,Step,10
5=d,AngIni,-90
6=d,AngFin,90
7=l,LiTang,0
8=l,LiOrth,0
9=l,LiElev,0
10=l,LoTang,0
11=l,LoOrth,0
12=l,LoElev,0
13=b,DirFromGuide,0
14=b,SurfAvoid,0
+92
View File
@@ -0,0 +1,92 @@
# Essetre-PF1250MAX
## Getting started
To make it easy for you to get started with GitLab, here's a list of recommended next steps.
Already a pro? Just edit this README.md and make it your own. Want to make it easy? [Use the template at the bottom](#editing-this-readme)!
## Add your files
- [ ] [Create](https://docs.gitlab.com/ee/user/project/repository/web_editor.html#create-a-file) or [upload](https://docs.gitlab.com/ee/user/project/repository/web_editor.html#upload-a-file) files
- [ ] [Add files using the command line](https://docs.gitlab.com/ee/gitlab-basics/add-file.html#add-a-file-using-the-command-line) or push an existing Git repository with the following command:
```
cd existing_repo
git remote add origin https://gitlab.steamware.net/egalware-machines/essetre/Essetre-PF1250MAX.git
git branch -M main
git push -uf origin main
```
## Integrate with your tools
- [ ] [Set up project integrations](https://gitlab.steamware.net/egalware-machines/essetre/Essetre-PF1250MAX/-/settings/integrations)
## Collaborate with your team
- [ ] [Invite team members and collaborators](https://docs.gitlab.com/ee/user/project/members/)
- [ ] [Create a new merge request](https://docs.gitlab.com/ee/user/project/merge_requests/creating_merge_requests.html)
- [ ] [Automatically close issues from merge requests](https://docs.gitlab.com/ee/user/project/issues/managing_issues.html#closing-issues-automatically)
- [ ] [Enable merge request approvals](https://docs.gitlab.com/ee/user/project/merge_requests/approvals/)
- [ ] [Set auto-merge](https://docs.gitlab.com/ee/user/project/merge_requests/merge_when_pipeline_succeeds.html)
## Test and Deploy
Use the built-in continuous integration in GitLab.
- [ ] [Get started with GitLab CI/CD](https://docs.gitlab.com/ee/ci/quick_start/index.html)
- [ ] [Analyze your code for known vulnerabilities with Static Application Security Testing(SAST)](https://docs.gitlab.com/ee/user/application_security/sast/)
- [ ] [Deploy to Kubernetes, Amazon EC2, or Amazon ECS using Auto Deploy](https://docs.gitlab.com/ee/topics/autodevops/requirements.html)
- [ ] [Use pull-based deployments for improved Kubernetes management](https://docs.gitlab.com/ee/user/clusters/agent/)
- [ ] [Set up protected environments](https://docs.gitlab.com/ee/ci/environments/protected_environments.html)
***
# Editing this README
When you're ready to make this README your own, just edit this file and use the handy template below (or feel free to structure it however you want - this is just a starting point!). Thank you to [makeareadme.com](https://www.makeareadme.com/) for this template.
## Suggestions for a good README
Every project is different, so consider which of these sections apply to yours. The sections used in the template are suggestions for most open source projects. Also keep in mind that while a README can be too long and detailed, too long is better than too short. If you think your README is too long, consider utilizing another form of documentation rather than cutting out information.
## Name
Choose a self-explaining name for your project.
## Description
Let people know what your project can do specifically. Provide context and add a link to any reference visitors might be unfamiliar with. A list of Features or a Background subsection can also be added here. If there are alternatives to your project, this is a good place to list differentiating factors.
## Badges
On some READMEs, you may see small images that convey metadata, such as whether or not all the tests are passing for the project. You can use Shields to add some to your README. Many services also have instructions for adding a badge.
## Visuals
Depending on what you are making, it can be a good idea to include screenshots or even a video (you'll frequently see GIFs rather than actual videos). Tools like ttygif can help, but check out Asciinema for a more sophisticated method.
## Installation
Within a particular ecosystem, there may be a common way of installing things, such as using Yarn, NuGet, or Homebrew. However, consider the possibility that whoever is reading your README is a novice and would like more guidance. Listing specific steps helps remove ambiguity and gets people to using your project as quickly as possible. If it only runs in a specific context like a particular programming language version or operating system or has dependencies that have to be installed manually, also add a Requirements subsection.
## Usage
Use examples liberally, and show the expected output if you can. It's helpful to have inline the smallest example of usage that you can demonstrate, while providing links to more sophisticated examples if they are too long to reasonably include in the README.
## Support
Tell people where they can go to for help. It can be any combination of an issue tracker, a chat room, an email address, etc.
## Roadmap
If you have ideas for releases in the future, it is a good idea to list them in the README.
## Contributing
State if you are open to contributions and what your requirements are for accepting them.
For people who want to make changes to your project, it's helpful to have some documentation on how to get started. Perhaps there is a script that they should run or some environment variables that they need to set. Make these steps explicit. These instructions could also be useful to your future self.
You can also document commands to lint the code or run tests. These steps help to ensure high code quality and reduce the likelihood that the changes inadvertently break something. Having instructions for running tests is especially helpful if it requires external setup, such as starting a Selenium server for testing in a browser.
## Authors and acknowledgment
Show your appreciation to those who have contributed to the project.
## License
For open source projects, say how it is licensed.
## Project status
If you have run out of energy or time for your project, put a note at the top of the README saying that development has slowed down or stopped completely. Someone may choose to fork your project or volunteer to step in as a maintainer or owner, allowing your project to keep going. You can also make an explicit request for maintainers.
+15 -17
View File
@@ -31,11 +31,10 @@ local GS = {}
local PositionTable = {}
local bTc2Active = ( EgtGetFirstNameInGroup( EgtGetBaseId( 'Base'), 'TC2') ~= nil)
local SecondSaw = ( EgtGetHeadId( 'H16') ~= nil)
local SecondChain = ( EgtGetFirstNameInGroup( EgtGetBaseId( 'Base'), 'TC4') ~= nil)
local TcSpecialTools = ( EgtGetFirstNameInGroup( EgtGetBaseId( 'Base'), 'TC5') ~= nil)
local TcAggreBladeUnder = ( EgtGetFirstNameInGroup( EgtGetBaseId( 'Base'), 'TCS') ~= nil)
local SecondChain = ( EgtGetFirstNameInGroup( EgtGetBaseId( 'Base'), 'TC5') ~= nil)
local TcSpecialTools = ( EgtGetHeadId( 'H14') ~= nil)
local bFullOpt = bTc2Active and SecondSaw and SecondChain and TcSpecialTools and TcAggreBladeUnder -- se ha tutti gli optional attivati
local bFullOpt = bTc2Active and SecondSaw and SecondChain and TcSpecialTools -- se ha tutti gli optional attivati
if bFullOpt then
PositionTable = {{Pos = "Pos1", TcPos = "T1", Head = "H12", Group = "G1"}, -- TC 1
{Pos = "Pos2", TcPos = "T2", Head = "H11", Group = "G1"},
@@ -52,7 +51,7 @@ if bFullOpt then
{Pos = "Pos13", TcPos = "T13", Head = "H11", Group = "G1"},
{Pos = "Pos14", TcPos = "T101", Head = "H13", Group = "G2"}, -- motosega
{Pos = "Pos15", TcPos = "T111", Head = "H13", Group = "G2"}, -- motosega 2
{Pos = "Pos16", TcPos = "T121", Head = "H11", Group = "G2"}, -- utensile speciale
{Pos = "Pos16", TcPos = "T121", Head = "H14", Group = "G2"}, -- utensile speciale
{Pos = "Pos17", TcPos = "T21", Head = "H16", Group = "G3"}, -- TC 2
{Pos = "Pos18", TcPos = "T22", Head = "H11", Group = "G3"},
{Pos = "Pos19", TcPos = "T23", Head = "H11", Group = "G3"},
@@ -63,18 +62,17 @@ if bFullOpt then
{Pos = "Pos24", TcPos = "T28", Head = "H11", Group = "G3"},
{Pos = "Pos25", TcPos = "T29", Head = "H11", Group = "G3"},
{Pos = "Pos26", TcPos = "T30", Head = "H11", Group = "G3"},
{Pos = "Pos27", TcPos = "T201", Head = "H22", Group = "G4"}, -- lama con aggregatop da sotto
{Pos = "Pos28", TcPos = "T220", Head = "H21", Group = "G4"}, -- TC margherita
{Pos = "Pos29", TcPos = "T221", Head = "H21", Group = "G4"},
{Pos = "Pos30", TcPos = "T222", Head = "H21", Group = "G4"},
{Pos = "Pos31", TcPos = "T223", Head = "H21", Group = "G4"},
{Pos = "Pos32", TcPos = "T224", Head = "H21", Group = "G4"},
{Pos = "Pos33", TcPos = "T225", Head = "H21", Group = "G4"},
{Pos = "Pos34", TcPos = "T226", Head = "H21", Group = "G4"},
{Pos = "Pos35", TcPos = "T227", Head = "H21", Group = "G4"},
{Pos = "Pos36", TcPos = "T228", Head = "H21", Group = "G4"},
{Pos = "Pos37", TcPos = "T229", Head = "H21", Group = "G4"},
{Pos = "Pos38", TcPos = "T230", Head = "H21", Group = "G4"}}
{Pos = "Pos27", TcPos = "T220", Head = "H21", Group = "G4"}, -- TC margherita
{Pos = "Pos28", TcPos = "T221", Head = "H21", Group = "G4"},
{Pos = "Pos29", TcPos = "T222", Head = "H21", Group = "G4"},
{Pos = "Pos30", TcPos = "T223", Head = "H21", Group = "G4"},
{Pos = "Pos31", TcPos = "T224", Head = "H21", Group = "G4"},
{Pos = "Pos32", TcPos = "T225", Head = "H21", Group = "G4"},
{Pos = "Pos33", TcPos = "T226", Head = "H21", Group = "G4"},
{Pos = "Pos34", TcPos = "T227", Head = "H21", Group = "G4"},
{Pos = "Pos35", TcPos = "T228", Head = "H21", Group = "G4"},
{Pos = "Pos36", TcPos = "T229", Head = "H21", Group = "G4"},
{Pos = "Pos37", TcPos = "T230", Head = "H21", Group = "G4"}}
elseif bTc2Active then
PositionTable = {{Pos = "Pos1", TcPos = "T1", Head = "H12", Group = "G1"},
{Pos = "Pos2", TcPos = "T3", Head = "H11", Group = "G1"},
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.
-43
View File
@@ -1,43 +0,0 @@
; Commento per evitare BOM con UTF-8
; Index, Type, Description, Value
; Index = 0,1,..,n
; Type : d=double, l=lenght, s=string, b=boolean, dr=double recalc, sr= string recalc, lr=lenght recalc, br=boolean recalc, th=toolholder
; Description : STEP, SIDESTEP, ...
[DRILL_STD]
0=th,TH,
1=d,STEP
2=s,DOUBLE
[SAW_STD]
0=th,TH,
1=d,STEP
2=d,SIDESTEP
3=b,LONGCUT
[SAW_FLAT]
0=th,TH,
1=d,STEP
2=d,SIDESTEP
3=b,LONGCUT
[MILL_STD]
0=th,TH,
1=d,STEP
2=d,SIDESTEP
3=d,SIDEDEPTH
4=s,DOUBLE
5=dr,TOOL_OVERHANG
[MILL_NOTIP]
0=th,TH,
1=d,STEP
2=d,SIDESTEP
3=d,SIDEDEPTH
4=s,DOUBLE
5=dr,TOOL_OVERHANG
[MORTISE_STD]
0=b,MORTISE
1=d,STEP
2=d,SIDESTEP
-289
View File
@@ -1,289 +0,0 @@
==== Common_PF1250 Update Log ====
Versione 3.1e1 (12/05/2026)
- (SIM-GEN) Corretta SIM (muoveva Y2 a MaxY2 senza aprire pinza) e GEN (non chiudeva rulliere e dava extracorsa e non generava P7=-85) di pezzi lunghi che necessitano lo scarico manuale. Ticket#2971
Versione 3.1c1
- (SIM-GEN) Corretto calcolo rimanenza durante ParkRoller. Ticket#2832
- (SIM) Corretto caricamento geometrie di collisioni. Modificato indice di collisione per una migliore gestione. ATT: MIN_MACH -> 3.1b2
- (SIM-GEN) Aggiunta OnSpecialApplyMachining per calcolare i carrelli da subito
- Aggiungendo OnSpecialApplyMachining, ora la OnSpecialGetPrevMachiningOffset lavora correttamente. Ticket#2798
- (SIM-GEN) Solo se dY1DeltaMaxSP > WorkTab.dY1DeltaMinF lo prende in considerazione per il valore di WorkTab.dY1DeltaMaxF Ticket#2798
Versione 3.1b1 (17/02/2026)
- (GEN) Generazione non allineata a simulazione. Ticket#2819
Versione 3.1a2 (30/01/2026)
- (SIM) Allineato approccio simulazione a generazione in caso di lavorazione in doppio verticale. Ticket#2781
- (GEN) Simulazione non allineata a generazione. Mancava reset flag di pezzo a caduta. Ticket#2798
Versione 3.1a1 (16/01/2026)
- (SIM-GEN) Corretto movimento di approccio con sega a catena e allineati Simulazione e Generazione. Ticket#2771
Versione 2.7l1 (18/12/2025)
- (SIM-GEN) Aggiunto controllo post movimenti ausiliari dell' EMC.PREVOFFSX nella funzione OnSpecialGetPrevMachiningOffset() come su ONE-PF. Ticket#2727
- (SIM-GEN) Cambiato delta di correzione Z per lama con inclinazione >= 81° da 70 a 60 mm. Risoluzione Ticket#2210
- (SIM-GEN) Divisione movimento B in approccio se > 90°.
Versione 2.7k5 (26/11/2025)
- (SIM) Migliorata funzione CheckClamping, ora il controllo di warning si basa sulla somma delle lunghezze delle aree pinzate
Versione 2.7k4 (25/11/2025)
- (SIM) Migliorata funzione CheckClamping, ora la sezione rientra di 3 mm
Versione 2.7k3 (21/11/2025)
- (SIM-GEN) Corretto problema riposizionamento carrelli. Ticket#2704
- (SIM) Aggiornata risoluzione VMillTol in funzione dello spessore lama
Versione 2.7k2 (19/11/2025)
- (SIM-GEN) Con testa H38 si va in home quando testa viene comandata a Zmassima. Ticket#2703_b
Versione 2.7k1 (19/11/2025)
- (GEN) Preselzione testa 1 spostata prima della selezione testa 3. Ticket#2513
- (SIM-GEN) Corretto calcolo per decidere se serve aprire i rulli
- (SIM) Aggiunto controllo Extra-Corsa testa 2 in caso di lavorazione in doppio. Ticket#2201
- (SIM) Prima versione controllo pinzaggio su VMILL. Per attivarlo serve modifica della macchina a MLDE e NGE.
- (GEN) Simulazione non allineata a generazione. Se testa H38 e si chiudono i rulli, si deve andare in home. Ticket#2703
Versione 2.7i1 (08/09/2025)
- (GEN) Se fase start o restart, si aggiorna la posizione in X dell'asse per calcolare il link corretto. Serve CAM5 2.7h1 (facoltativo)
- (EST) La stima tempi considera ora le accelerazoni degli assi
- (SIM) Corretto controllo ultimo utensile utilizzato su testa 1, prima si controllava il precedente, ma poteva essere la testa 2
- (SIM-GEN) Se testa 3 deve salire a ZMAX, sale alla X dove si trova e non torna in home
Versione 2.7h2 (21/08/2025)
- (GEN) Se la testa rimane bassa, corretto caso di reset del piano generico a fine lavorazione
- (GEN) Corretto movimento in Z massima dopo scarico pezzo
Versione 2.7h1 (20/08/2025)
- (GEN) Per posizione T111 e T121, se non è presente asse rotante per presa aggregato (es. se si mette una fresa normale) viene settato a zero.
- (MLDE-SIM) Aggiunta variabile FACOLTATIVA 'EstimationRapidMultiplier' in mlde per regolare il tempo stimato di rapido su macchine vecchie. Se non presente default 1.
Versione 2.7g1 (01/07/2025)
- (GEN) Lettura parametri accelerazioni da TS3. Ticket#2052
- (SIM-GEN) Aggiunta gestione massima lunghezza scarico
Versione 2.7d2 (24/04/2025)
- (SIM) Modifica qualità VMILL. Da ora si può impostare da impostazioni CAM5
Versione 2.7d1 (01/04/2025)
- (GEN) Aggiunta commenti HEADER e FOOTER per comunicazione con linea o altre macchine, da parte di Essetre.
Versione 2.7b5 (26/02/2025)
- (MLDE-GEN) Gestione lettura feed massima pinze da Ts3.
Versione 2.7b4 (21/02/2025)
- (SIM-GEN) Ripristinato comportamento precedente calcolo posizione dei rulli di pinzaggio fatto con 2.7b2.
- (MLDE-SIM) Gestione aggregato flottante. Serve modifica MLDE. Ticket#2297
Versione 2.7b3 (06/02/2025)
- (SIM) Dopo aver scaricato utensile, si setta nota "HIDDEN" per dichiarare utensile non più sulla testa e non considerare le collisioni.
Versione 2.7b2 (04/02/2025)
- (SIM-GEN) Piccola modifica nel calcolo posizione dei rulli di pinzaggio.
Versione 2.7b1 (03/02/2025)
- (SIM) Corretta simulazione che non mandava testa in home in caso di utensile lungo. Generazione era già ok. Ticket#2280
Versione 2.7a2 (28/01/2025)
- (SIM-GEN) In MLSE aggiunta piccola correzione quota Z in caso di direzione Z tra 0.5 e 0.707.
Versione 2.7a1 (17/01/2025)
- (GEN) Piccola correzione posizione X in preselezione utensile
- (GEN) Corretto primo punto X preselezione utensile. Ticket#2183 e #2250
Versione 2.6l7 (19/12/2024)
- (SIM) HOTFIX : corretto posizione Z zero alla selezione dell'utensile in caso di motosega. Ticket#2235
Versione 2.6l6 (18/12/2024)
- (MLDE-SIM-GEN) Aggiunta variabile 'SafeX2RotAxis' in sostituzione della 'ParkMchY2' che era usata impropriamente
Versione 2.6l5 (17/12/2024)
- (SIM) Corretta posizione iniziale testa 2. Ticket#2228
Versione 2.6l4 (16/12/2024)
- (SIM-GEN) In MLSE ripristinati vecchi valori indici calcolo Z massima. In alcuni casi peggioravano la situazione.
Versione 2.6l3 (16/12/2024)
- (SIM) Corretto scarico utensile se aggregato. Se non presente utensile di default, non seleziona nulla.
- (SIM-GEN) In MLSE ritoccati indici calcolo Z massima. Ticket#2210
Versione 2.6l2 (13/12/2024)
- (SIM) Corretta chiamata calcolo asse virtuale
Versione 2.6l1 (13/12/2024)
- (SIM) Gestione caricamento utensili in caso di testa con uscita multipla.
- (SIM) Corretto errore di collisione per errata simulazione cambio utensile da lama a motosega.
- (SIM-GEN) Corretta gestione in caso di prima lavorazione con motosega.
- (GEN) Non si fa preselezione della testa 3
- (GEN) Corretta emissione coordinata rotazione testa 3 in zona sicura
- (SIM-GEN) A fine barra, testa 3 sempre in home
- (GEN) Controllo esistenza terzo asse ausiliario
- (GEN) Corretto primo movimento in X quando si parte con testa 3. Ticket#2216
- (GEN) Se su testa 1 c'è un aggregato e si utilizzerà la testa 3, si scarica aggregato e si prende utensile di default. Ticket#2222
- (GEN) Durante utilizzo della testa 3, non si preselezionano altre teste. Ticket#2220
- (SIM-GEN) Se lavorazione con testa dedicata lama e su testa 1 c'era aggregato, viene scaricato. Ticket#2216
Versione 2.6k3 (26/11/2024)
- (GEN) Corretta modifica fatta in versione 2.6k2. Ticket#2183
Versione 2.6k2 (25/11/2024)
- (GEN) Se si preseleziona su testa 1 un utensile lungo, non si va alla X successiva di lavoro ma si resta in home. Infatti potrebbe toccare le paratie in caso di scambio pezzo. Ticket#2183
Versione 2.6k1 (04/11/2024)
- (SIM-GEN) Gestione terza testa 5 assi dedicata lama (H38)
Versione 2.6j3 (25/10/2024)
- (GEN) Piccola correzione per capire se testa 3 presente
- (SIM-GEN) In caso di lavorazione successiva alla prima, rivisto primo posizionamento alla quota Z di lavoro se precedentemente spostati a quota rotazione assi rotanti.
Versione 2.6j2 (23/10/2024)
- (MLDE-SIM) Aggiunto parametro ParkTc1X1 in MLDE per simulazione quota parcheggio Testa 1 su TC1.
- (SIM-GEN) Per movimento a ZMAX si considera utensile attuale o precedente
- (SIM-GEN) Prima versione con gestione testa 3 dedicata lama
Versione 2.6j1 (01/10/2024)
- (GEN) Migliorato calcolo chiusura paratia rulli con aggiornamento lunghezza della barra in caso di ultimo taglio e grezzo residuo in coda. Ticket#2017
- (NGE-SIM) Aggiunta gestione solidi collisione per TC verticali e TC rotante sotto
- (GEN) Per lavorazione in doppio: messaggio bloccante in caso di extra-corsa durante un movimento standard su piano generico della lavorazione.
Versione 2.6i1 (10/09/2024)
- (GEN) Se diametro utensile più del truciolatore standard grande, non si preseleziona. Ticket#2028
Versione 2.6h2 (28/08/2024)
- (SIM-GEN) Quando si aprono i rulli, se la trave non può seguire i rulli perchè la pinza andrebbe in extra-corsa, si sposta comunque la pinza fino al massimo della sua corsa. Ticket#1949
- (GEN) La testa veniva spostata a quota X sicurezza rotazione assi rotanti prima di aprire le rulliere. Ticket#1991
Versione 2.6h1 (07/08/2024)
- (GEN) Gestione creazione piano generico in caso il primo movimento della lavorazione sia un arco. Ticket#1891
- (SIM-GEN) Migliorata gestione riposizionamenti fatta con la 2.6g1. Ticket#1836
- (MLDE-SIM-GEN) Rinominato file da "Common-" a "Common_" per uniformità con i file common delle altre macchine. Serve modifica a MLDE macchina.
Versione 2.6g5 (24/07/2024)
- (SIM) Per OnSetHead chiamata da simulazione, aggiunta lettura TOTDIAM. Serve per limitare corse assi testa sotto. Ticket#1946
Versione 2.6g4 (23/07/2024)
- (SIM) Corretta ultima modifica per controllo collisioni testa non utilizzata. Trovava collisioni in lavorazioni in doppio.
Versione 2.6g3 (22/07/2024)
- (SIM) Si aggiunge al controllo collisioni anche Tool e ToolHolder della testa non utilizzata. Ticket#1937
- (SIM-GEN) In caso di grezzo piuttosto piccolo, concesso pinzaggio fino al massimo possibile, oltre al calcolo con coefficienti. Ticket#1942
Versione 2.6g2 (12/07/2024)
- (SIM-GEN) Corretto movimento testa sotto che andava in collisione tra una lavorazione e la successiva se tra le due c'era un riposizionamento pinze. Ticket#1925
Versione 2.6g1 (08/07/2024)
- (SIM-GEN) Corretto movimento che pinzava nel vuoto durante riposizionamento. Ticket#1836
Versione 2.6f2 (06/06/2024)
- (GEN) Quando si va a ZMAX, si azzerano tutte le coordinate ".pp". Scriveva una Z bassa quando era a Z massima. Ticket#1839
Versione 2.6f1 (03/06/2024)
- (SIM-GEN) Migliorata gestione approccio al pezzo con lama aggregato da sotto. Va al minimo in X solo se necessario.
Versione 2.6e6 (28/05/2024)
- (GEN) Aggiunta possibilità di scrivere nome utensile doppio anche in lavorazione con parametro "TOOLDOUBLE". Note sulla lavorazione hanno precedenza su note utensile.
- (GEN) Ripristinato controllo extra-corsa per testa 2 in caso di lavorazioni in doppio in Y (si era perso in un vecchio commit)
- (SIM-GEN) Corretto movimento testa sotto su prima lavorazione. Ruotava a parcheggio invece di andare a quota sicurezza rotazione assi.
Versione 2.6e5 (23/05/2024)
- (GEN) Controllo extra-corsa per testa 2 in caso di lavorazioni in doppio in Y
- (GEN) Corretta lettura e salvataggio coordinala asse L2 con coordinate rispetto origine. Prima erano locali e sbagliava alcuni calcoli
- (SIM-GEN) Se lavorazione con testa 2 e stesso utensile, piccola correzione che manda a parcheggio se cambiano assi rotanti solo se si trova a ZMAX
Versione 2.6e4 (15/05/2024)
- (SIM-GEN) Miglioramento gestione lama su aggregato da sotto
Versione 2.6e3 (09/05/2024)
- (SIM) Corretto prelievo lama 2 (H16). Prima di visualizzare utensile, si sposta la Z alla quota massima. Prima trovava collisione in caso utensile precedente non lama (perchè era già oltre la quota massima).
Versione 2.6e2 (06/05/2024)
- (GEN) In parcheggio paratie/pinze, viene considerato sovramateriale di testa. Simulazione era corretta. Ticket#1789
Versione 2.6e1 (30/04/2024)
- (SIM-GEN) Per macchina a 3 teste, ripristinato posizionamento testa 2 tramite parametro ParkInLavZ2. La gestione era stata persa dal common.
- (MLDE-GEN) Gestione facoltativa parametro WOOD_DENSITY settabile in Ts3. In MLDE, mettere il valore di WOOD_DENSITY nella nostra variabile 'WoodDensity'.
Versione 2.6d2 (23/04/2024)
- (MLDE-GEN) Aggiunto parametro 'IS_TEST_MACHINE' FACOLTATIVO. Se non esiste o 'false' è macchina standard, se 'true' è una macchina utilizzata per i test Egalware interni
- (GEN) Chiamando la macchina con un nome che termini con '.TEST' si abilita come macchina per test interni, equivalente a settare 'IS_TEST_MACHINE' (che comunque rimane)
- (SIM-GEN) Modificato movimenti testa sotto. Prima si muove in quota 'ParkMchY2' e poi va alla coordinata di lavoro ruotando gli assi
- (SIM) Per lavorazioni in doppio, viene subito scritta la quota Z. La generazione era già corretta. Ticket#1377
- (GEN) Ripristinato movimento iniziale testa sopra assieme alle pinze. Spostato comando wait dopo primo movimento testa. Ticket#1730
- (MLDE-SIM-GEN) Aggiunto parametro MaxZ1Blade per differenziare Z massima aggregato lama e altri utensili.
- (SIM) Aggiunto controllo con solido di collisione per verificare di non salire oltre il massimo
- (SIM) Corretta simulazione scambio testa 3 -> testa 1
Versione 2.6d1 (09/04/2024)
- (GEN) Corretto impostazione piano G24 con testa da sotto con aggregato
- (SIM-GEN) Corretta posizione prelievo/parcheggio se lama su aggregato da sotto
- (MLDE-SIM-GEN) Aggiunta variabile FACOLTATIVA 'ForceToCloseRollersGate' ( che legge la variabile da TS3 'CHIUDI_PINZE_2_3_SCAMBIO') in mlde per forzare chiusura paratie rulli
durante scambio pinze per facilitare passaggio pezzi molto storti. Se non presente chiude solo se necessario.
- (GEN) Corretta scrittura lista utensili iniziale M992 per doppia motosega e aggregato lama sotto
- (SIM-GEN) Corretto movimento punte lunghe
- (GEN) Corretto adeguamento speed per aggregato lama da sotto con coefficiente moltiplicativo
- (SIM-GEN) Aumentato numero riposizionamenti possibili a 10 ( per pezzi molto lunghi non bastava il valore precedente: 5)
- (GEN) Corretto posizionamento assi in home se primo utensile punta lunga
Versione 2.6c5 (26/03/2024)
- (SIM) Corretto primo movimento in rapido della lavorazione per testa sotto. Ora allineata a generazione
- (SIM-GEN) Aggiunta gestione parametro "SECDIST". Distanza di sicurezza tra paratia con rulli e utensile/testa. Parametro da inserire nelle note utensile
- (MLDE-SIM) Modificate collisioni traversa. Ora non comprende carro X1, il quale ha il proprio oggetto di collisione
Versione 2.6c4 (14/03/2024)
- (SIM) Miglioramento visualizzazione spigoli VMILL alla fine della simulazione. Funzione: EgtVolZmapSetShowEdges. N.B.= serve CAM5 2.6c2 NON OBBLIGATORIO
- (GEN) Modifica controlli a preselezione utensile. Margine ridotto da 400m a 200mm.
- (GEN) Corretto controllo preselezione testa H1 quando H2 in lavoro
Versione 2.6c3 (12/03/2024)
- (SIM-GEN) Migliorata gestione movimenti con lama su aggregato su testa sotto
Versione 2.6c2 (04/03/2024)
- (GEN) I commenti iniziali si scrivono in modo standard, per poterli commentare nella macchina di test
- (MLDE-GEN) Aggiunta variabile 'MACH_NAME' in MLDE con nome macchina
Versione 2.6c1 (29/02/2024)
- (SIM) Gestione rimozione VMILL per tagli a cubetti Zig-Zag
Versione 2.6b4 (23/02/2024)
- (MLDE-SIM-GEN) EgtAddToPackagePath spostato in mlde
Versione 2.6b3 (20/02/2024)
- (SIM) Aggiunta funzioni "OnSimulInit" e "OnSimulExit" per orientare vista corretta in caso di macchina con carico destro. N.B.= serve CAM5 2.6b4 NON OBBLIGATORIO
- (SIM-GEN) "BeamData" caricato come libreria con 'require' anziché come file con 'dofile'
Versione 2.6b2 (15/02/2024)
- (SIM-GEN) Primo movimento in X per testa 2 a SafeX2 anziché a ParkX2
Versione 2.6b1 (07/02/2024)
- (MLDE-SIM-GEN) Inserito parametro 'MinLengthLongCSaw' per gestione motosega molto lunga
- (MLDE) funzione 'GetCurrChainSawingVirtualAxis' spostata in MLDE
Versione 2.6a5 (31/01/2024)
- (SIM) Migliorata simulazione apertura/chiusura morse in caso di separazione
- (SIM-GEN) Migliorata gestione movimenti con motosega e adeguato simulazione
- (GEN) Corretta scrittura assi in caso di 'WriteAllCoordsOnFirstM101' per testa 2
- (SIM-GEN) Caricamento BeamData come local
Versione 2.6a4 (25/01/2024)
- (SIM-GEN) Corretto movimento in caso di cambio assi rotanti tra due lavorazioni
- (GEN) Corretta emissione coordinate assi in caso di 'WriteAllCoordsOnFirstM101'
Versione 2.6a3 (22/01/2024)
- (SIM-GEN) Correzione gestione apertura/chiusura rulli sul fine barra (#1630) e in generale
- (GEN) Modificato flag 'EmitRapidInG0' in 'EmitRapidInG1' per decidere se scrivere G1 anziché G0. Se flag a nil, scrive i rapidi in G0
- (SIM) Correzione movimenti pinze prima di separazione
Versione 2.6a2 (19/01/2024)
- (GEN) Corretta inversione coordinata X per Lama su aggregato da sotto
- (SIM) Se modalità 'WriteAllCoordsOnFirstM101', oltre alla X si scive quota di parcheggio assi B2 e C2 come in generazione
- (SIM-GEN) Tolta gestione rotazione pezzo (di derivazione PF), in macchina non è previsto ribaltamento
- (GEN) Migliorata gestione preselezione utensile
- (MLDE-GEN) Aggiunto flag 'EmitRapidInG0' per decidere se scrivere G0 anziché G1. Se flag a nil, scrive i rapidi in G1
Versione 2.6a1 (09/01/2024)
- Prima versione post-proc comune tra macchine PF1250 e PF1500
- (SIM-GEN) Corretto movimento testa 2 in ToolDesel e movimento controllo collisione
- (GEN) Tolta testa H14 per utensili speciali. Si utilizza H11 per frese standard
- (MLDE-GEN) Costanti 'MinForzaPinze' e 'MaxForzaPinze' portati in mlde/Ts3data (erano hardcoded)
- (MLDE-SIM-GEN) Aggiunto parametro 'WriteAllCoordsOnFirstM101' per decidere se stampare tutti gli assi sulla prima M101
-10
View File
@@ -1,10 +0,0 @@
-- Version.lua by EgalWare s.r.l. 2024/01/22
-- Gestione della versione dei file comuni post-processori macchine PF1250 e PF1500 di Essetre
local InfoCommon_STD_PP = {
NAME = 'Common_PF1250', -- nome script PP standard
VERSION = '3.1e1', -- versione script
MIN_MACH_VER_PP_COMMON = '3.1b2' -- versione minima kernel
}
return InfoCommon_STD_PP
-3
View File
@@ -1,3 +0,0 @@
[WALL]
Kerf=10
Offset=25
+1 -1
View File
@@ -37,7 +37,7 @@ local WallData = {
-- Aggiornamento con dati da TechnoEssetre7
local sTs3Data = EgtGetStringFromIni( 'Wall', 'DATA_DIR', "C:\\TechnoEssetre7\\EgtData", EgtGetIniFile()).."\\Essetre-PF1250.data"
local sData = EgtGetCurrMachineDir().."\\Wall\\Ts3Data.lua"
local sData = EgtGetSourceDir().."\\Ts3Data.lua"
if EgtExistsFile( sTs3Data) then
EgtCopyFile( sTs3Data, sData)
local sTs3DataOld = sTs3Data..'.old'