OmagCUT 2.1k2 :
- si salvano in memoria i dati dell'ultimo taglio diretto Singolo per riproporli al successivo - anche sui tagli diretti si lancia lo script di macchina SentProg.lua (se presente) - in Split corretta gestione tagli inclinati con Waterjet - gli angoli di fianco vengono ora indicati sui disegni con due decimali (se necessario).
This commit is contained in:
@@ -206,5 +206,13 @@ Module ConstIni
|
||||
Public Const K_FG_TOTSLAB As String = "TotSlab"
|
||||
Public Const K_FG_PIECETYPE As String = "PieceType"
|
||||
|
||||
Public Const S_DIRECTCUTS As String = "DirectCuts"
|
||||
Public Const K_DC_SING_DEPTH As String = "SingDepth"
|
||||
Public Const K_DC_SING_LENGTH As String = "SingLength"
|
||||
Public Const K_DC_SING_ANGH As String = "SingAngH"
|
||||
Public Const K_DC_SING_ANGV As String = "SingAngV"
|
||||
Public Const K_DC_SING_OFFSET As String = "SingOffset"
|
||||
Public Const K_DC_SING_POSX As String = "SingPosX"
|
||||
Public Const K_DC_SING_POSY As String = "SingPosY"
|
||||
|
||||
End Module
|
||||
|
||||
@@ -548,6 +548,8 @@ Public Class FlatteningCut
|
||||
' copio il progetto corrente come progetto in lavorazione
|
||||
Dim sWrkPath As String = m_MainWindow.GetTempDir() & "\" & "WorkProj.nge"
|
||||
My.Computer.FileSystem.CopyFile(sMchPath, sWrkPath, True)
|
||||
' lancio eventuale lua post-trasmissione
|
||||
m_MainWindow.m_CadCutPageUC.m_ProjectMgr.ExecSentProgScript()
|
||||
End If
|
||||
#End If
|
||||
End Sub
|
||||
|
||||
@@ -474,6 +474,8 @@ Public Class GridCut
|
||||
' copio il progetto corrente come progetto in lavorazione
|
||||
Dim sWrkPath As String = m_MainWindow.GetTempDir() & "\" & "WorkProj.nge"
|
||||
My.Computer.FileSystem.CopyFile(sMchPath, sWrkPath, True)
|
||||
' lancio eventuale lua post-trasmissione
|
||||
m_MainWindow.m_CadCutPageUC.m_ProjectMgr.ExecSentProgScript()
|
||||
End If
|
||||
#End If
|
||||
End Sub
|
||||
|
||||
@@ -501,6 +501,8 @@ Public Class MultipleCut
|
||||
' copio il progetto corrente come progetto in lavorazione
|
||||
Dim sWrkPath As String = m_MainWindow.GetTempDir() & "\" & "WorkProj.nge"
|
||||
My.Computer.FileSystem.CopyFile(sMchPath, sWrkPath, True)
|
||||
' lancio eventuale lua post-trasmissione
|
||||
m_MainWindow.m_CadCutPageUC.m_ProjectMgr.ExecSentProgScript()
|
||||
End If
|
||||
#End If
|
||||
End Sub
|
||||
|
||||
@@ -62,5 +62,5 @@ Imports System.Windows
|
||||
' by using the '*' as shown below:
|
||||
' <Assembly: AssemblyVersion("1.0.*")>
|
||||
|
||||
<Assembly: AssemblyVersion("2.1.11.1")>
|
||||
<Assembly: AssemblyFileVersion("2.1.11.1")>
|
||||
<Assembly: AssemblyVersion("2.1.11.2")>
|
||||
<Assembly: AssemblyFileVersion("2.1.11.2")>
|
||||
|
||||
@@ -624,7 +624,7 @@ Public Class ProjectMgrUC
|
||||
m_CurrProjPage.ClearMessage()
|
||||
End Sub
|
||||
|
||||
Private Function ExecSentProgScript() As Boolean
|
||||
Friend Function ExecSentProgScript() As Boolean
|
||||
' Verifico esistenza script
|
||||
Dim sLuaPath As String = m_MainWindow.m_CurrentMachine.sMachDir() & "\Scripts\SentProg.lua"
|
||||
If Not My.Computer.FileSystem.FileExists(sLuaPath) Then Return True
|
||||
|
||||
@@ -423,6 +423,8 @@ Public Class SawTestUC
|
||||
' copio il progetto corrente come progetto in lavorazione
|
||||
Dim sWrkPath As String = m_MainWindow.GetTempDir() & "\" & "WorkProj.nge"
|
||||
My.Computer.FileSystem.CopyFile(sMchPath, sWrkPath, True)
|
||||
' lancio eventuale lua post-trasmissione
|
||||
m_MainWindow.m_CadCutPageUC.m_ProjectMgr.ExecSentProgScript()
|
||||
End If
|
||||
#End If
|
||||
End Sub
|
||||
|
||||
+4
-4
@@ -147,19 +147,19 @@ Module SideAngle
|
||||
Dim bSH As Boolean = EgtGetInfo(LineId, INFO_HEEL, dSideHeel)
|
||||
If Math.Abs(dSideAngle) > EPS_ANG_SMALL Or ( bSA2 And Not bSH) Then
|
||||
' Creo testo con angolo di inclinazione
|
||||
Dim sText As String = DoubleToString(dSideAngle, 1) & "°"
|
||||
Dim sText As String = DoubleToString(dSideAngle, 2) & "°"
|
||||
' Se presente tallone, lo indico
|
||||
If bSH then
|
||||
If dSideHeel > 10 * EPS_SMALL Then
|
||||
If dSideAngle > 0 Then
|
||||
sText = sText & "; " & LenToString(dSideHeel, 1)
|
||||
sText = sText & "; " & LenToString(dSideHeel, 2)
|
||||
Else
|
||||
sText = LenToString(dSideHeel, 1) & "; " & sText
|
||||
sText = LenToString(dSideHeel, 2) & "; " & sText
|
||||
End If
|
||||
End If
|
||||
' se altrimenti presente secondo angolo, lo indico
|
||||
ElseIf bSA2 then
|
||||
sText = DoubleToString(dSideAngle2, 1) & "°" & "; " & sText
|
||||
sText = DoubleToString(dSideAngle2, 2) & "°" & "; " & sText
|
||||
End If
|
||||
AddTextToLine(sText, TextLayId, LineId, 15, dBBoxRad, False, True)
|
||||
End If
|
||||
|
||||
+5
-5
@@ -424,8 +424,8 @@ Public Class SideAngleUC
|
||||
If m_Mode = ModeOpt.SIDEANGLE Then
|
||||
' Per ogni entità, creo testo con nome e angolo di inclinazione
|
||||
For Each Entity In m_SideAngleEntityList
|
||||
Dim sText As String = Entity.sEntityName & " = " & DoubleToString(Entity.dSideAngle, 1) & "°"
|
||||
If Entity.dSideHeel > 10 * EPS_SMALL Then sText += "; " & LenToString(Entity.dSideHeel, 1)
|
||||
Dim sText As String = Entity.sEntityName & " = " & DoubleToString(Entity.dSideAngle, 2) & "°"
|
||||
If Entity.dSideHeel > 10 * EPS_SMALL Then sText += "; " & LenToString(Entity.dSideHeel, 2)
|
||||
SideAngle.AddTextToLine(sText, Entity.nTextId, Entity.nGeomId, 20, dBBoxRad, True)
|
||||
Next
|
||||
' Altrimenti modalità gocciolatoio
|
||||
@@ -486,8 +486,8 @@ Public Class SideAngleUC
|
||||
EgtGetName(CurrLine, sEntityName)
|
||||
m_SideAngleEntityList.Add(New SideAngleEntity(CurrLine, sEntityName, TextLayer, dSideAngleVal, dSideHeelVal))
|
||||
' Creo testo con angolo di inclinazione ed eventuale tallone
|
||||
Dim sText As String = sEntityName & " = " & DoubleToString(dSideAngleVal, 1) & "°"
|
||||
If dSideHeelVal > 10 * EPS_SMALL Then sText += "; " & LenToString(dSideHeelVal, 1)
|
||||
Dim sText As String = sEntityName & " = " & DoubleToString(dSideAngleVal, 2) & "°"
|
||||
If dSideHeelVal > 10 * EPS_SMALL Then sText += "; " & LenToString(dSideHeelVal, 2)
|
||||
SideAngle.AddTextToLine(sText, TextLayer, CurrLine, 20, dBBoxRad, True)
|
||||
End Sub
|
||||
|
||||
@@ -577,7 +577,7 @@ Public Class SideAngleUC
|
||||
' Assegno colore e attributi
|
||||
nCrvId = EgtGetFirstInGroup(DripLayer)
|
||||
While nCrvId <> GDB_ID.NULL
|
||||
EgtSetColor(nCrvId, New Color3d(255, 165, 0))
|
||||
EgtSetColor(nCrvId, COL_MCH_DRIPCUT())
|
||||
EgtSetInfo(nCrvId, INFO_DEPTH, m_dDripDepth)
|
||||
If m_dDripShort > EPS_SMALL Then EgtSetInfo(nCrvId, INFO_STRICT, "1")
|
||||
nCrvId = EgtGetNext(nCrvId)
|
||||
|
||||
+33
-10
@@ -55,7 +55,7 @@ Public Class SingleCutUC
|
||||
m_PointsModeArray(PT_MODE.DRAW) = EgtMsg(MSG_DIRECTCUTPAGEUC + 25)
|
||||
' la associo alla combobox
|
||||
PointModeCmBx.ItemsSource = m_PointsModeArray
|
||||
' assegno messaggi
|
||||
' Assegno messaggi
|
||||
Point1Btn.Content = EgtMsg(MSG_DIRECTCUTPAGEUC + 10)
|
||||
Point2Btn.Content = EgtMsg(MSG_DIRECTCUTPAGEUC + 11)
|
||||
DepthTxBl.Text = EgtMsg(MSG_DIRECTCUTPAGEUC + 13)
|
||||
@@ -65,6 +65,14 @@ Public Class SingleCutUC
|
||||
OffsetTxBl.Text = EgtMsg(MSG_DIRECTCUTPAGEUC + 28)
|
||||
SimulBtn.Content = EgtMsg(MSG_CADCUTPAGEUC + 1)
|
||||
OkBtn.Content = EgtMsg(MSG_DIRECTCUTPAGEUC + 30)
|
||||
' Carico i dati dell'ultimo taglio
|
||||
m_dDepth = GetPrivateProfileDouble( S_DIRECTCUTS, K_DC_SING_DEPTH, m_dDepth, m_MainWindow.GetIniFile())
|
||||
m_dLen = GetPrivateProfileDouble( S_DIRECTCUTS, K_DC_SING_LENGTH, m_dLen, m_MainWindow.GetIniFile())
|
||||
m_dAngO = GetPrivateProfileDouble( S_DIRECTCUTS, K_DC_SING_ANGH, m_dAngO, m_MainWindow.GetIniFile())
|
||||
m_dAngV = GetPrivateProfileDouble( S_DIRECTCUTS, K_DC_SING_ANGV, m_dAngV, m_MainWindow.GetIniFile())
|
||||
m_dOffset = GetPrivateProfileDouble( S_DIRECTCUTS, K_DC_SING_OFFSET, m_dOffset, m_MainWindow.GetIniFile())
|
||||
m_ptTipP1.x = GetPrivateProfileDouble( S_DIRECTCUTS, K_DC_SING_POSX, m_ptTipP1.x, m_MainWindow.GetIniFile())
|
||||
m_ptTipP1.y = GetPrivateProfileDouble( S_DIRECTCUTS, K_DC_SING_POSY, m_ptTipP1.y, m_MainWindow.GetIniFile())
|
||||
End Sub
|
||||
|
||||
Private Sub SingleCut_Loaded(sender As Object, e As RoutedEventArgs) Handles Me.Loaded
|
||||
@@ -83,6 +91,11 @@ Public Class SingleCutUC
|
||||
EgtDraw()
|
||||
Return
|
||||
End If
|
||||
' Disabilito registrazione progetto modificato
|
||||
EgtDisableModified()
|
||||
' Creo layer temporaneo per crocette
|
||||
m_nTempLay = EgtCreateGroup(GDB_ID.ROOT)
|
||||
EgtSetLevel(m_nTempLay, GDB_LV.TEMP)
|
||||
' Origine tavola
|
||||
m_bRawOk = True
|
||||
If Not EgtGetTableRef(1, m_ptTabOri) Then
|
||||
@@ -97,17 +110,19 @@ Public Class SingleCutUC
|
||||
' Reset punto acquisito
|
||||
m_bPointP1Ok = False
|
||||
m_bPointP2Ok = False
|
||||
' Inizializzo primo punto acquisito dal disegno come centro del grezzo
|
||||
GetRawCenter(m_ptPrev)
|
||||
' Inizializzo primo punto acquisito dal disegno
|
||||
m_ptPrev = m_ptTipP1 + ( m_ptTabOri - Point3d.ORIG())
|
||||
m_ptPrev.z = m_ptRawMax.z
|
||||
' Disegno crocetta che indica il punto acquisito
|
||||
CreateCross(m_nTempLay, m_ptPrev)
|
||||
' Imposto modalità di acquisizione punti
|
||||
PointModeCmBx.SelectedIndex = PT_MODE.DRAW
|
||||
SetCoordVisibility(True)
|
||||
ShowCoord()
|
||||
' Assegno parametri di lavorazione già definiti
|
||||
' Assegno parametri di lavorazione
|
||||
DepthTxBx.Text = LenToString(m_dDepth, 1)
|
||||
LenghtTxBx.Text = LenToString(m_dLen, 1)
|
||||
OffsetTxBx.Text = LenToString(m_dOffset, 1)
|
||||
' Inizializzo valori non ancora definiti
|
||||
DirectionTxBx.Text = DoubleToString(m_dAngO - m_MainWindow.m_CurrentMachine.dDeltaC, 2)
|
||||
SideAngleTxBx.Text = DoubleToString(m_dAngV, 2)
|
||||
' Reset taglio e disabilito bottone esecuzione
|
||||
@@ -117,14 +132,20 @@ Public Class SingleCutUC
|
||||
Point2Btn.IsEnabled = False
|
||||
' Deseleziono bottone primo punto
|
||||
Point1Btn.IsChecked = False
|
||||
' Disabilito registrazione progetto modificato
|
||||
EgtDisableModified()
|
||||
' Creo layer temporaneo per crocette
|
||||
m_nTempLay = EgtCreateGroup(GDB_ID.ROOT)
|
||||
EgtSetLevel(m_nTempLay, GDB_LV.TEMP)
|
||||
' Aggiorno visualizzazione
|
||||
EgtDraw()
|
||||
End Sub
|
||||
|
||||
Friend Sub SingleCut_Unloaded(sender As Object, e As RoutedEventArgs) Handles Me.Unloaded
|
||||
' Salvo i dati correnti
|
||||
WritePrivateProfileString( S_DIRECTCUTS, K_DC_SING_DEPTH, DoubleToString( m_dDepth, 2), m_MainWindow.GetIniFile())
|
||||
WritePrivateProfileString( S_DIRECTCUTS, K_DC_SING_LENGTH, DoubleToString( m_dLen, 2), m_MainWindow.GetIniFile())
|
||||
WritePrivateProfileString( S_DIRECTCUTS, K_DC_SING_ANGH, DoubleToString( m_dAngO, 2), m_MainWindow.GetIniFile())
|
||||
WritePrivateProfileString( S_DIRECTCUTS, K_DC_SING_ANGV, DoubleToString( m_dAngV, 2), m_MainWindow.GetIniFile())
|
||||
WritePrivateProfileString( S_DIRECTCUTS, K_DC_SING_OFFSET, DoubleToString( m_dOffset, 2), m_MainWindow.GetIniFile())
|
||||
WritePrivateProfileString( S_DIRECTCUTS, K_DC_SING_POSX, DoubleToString( m_ptTipP1.x, 2), m_MainWindow.GetIniFile())
|
||||
WritePrivateProfileString( S_DIRECTCUTS, K_DC_SING_POSY, DoubleToString( m_ptTipP1.y, 2), m_MainWindow.GetIniFile())
|
||||
' Se non vado in simulazione
|
||||
If Not m_bSimul Then
|
||||
' Dichiaro sottopagina da non riattivare
|
||||
m_MainWindow.m_DirectCutPageUC.m_ActiveDirectCutPage = DirectCutPageUC.DirectCutPages.DirectCut
|
||||
@@ -496,6 +517,8 @@ Public Class SingleCutUC
|
||||
' copio il progetto corrente come progetto in lavorazione
|
||||
Dim sWrkPath As String = m_MainWindow.GetTempDir() & "\" & "WorkProj.nge"
|
||||
My.Computer.FileSystem.CopyFile(sMchPath, sWrkPath, True)
|
||||
' lancio eventuale lua post-trasmissione
|
||||
m_MainWindow.m_CadCutPageUC.m_ProjectMgr.ExecSentProgScript()
|
||||
End If
|
||||
#End If
|
||||
End Sub
|
||||
|
||||
@@ -99,6 +99,15 @@ Public Module SplitAuto
|
||||
Mach.m_bStartAll = False
|
||||
Mach.m_bEndAll = False
|
||||
End If
|
||||
' Waterjet
|
||||
ElseIf Mach.m_nType = MCH_OY.WATERJETTING Then
|
||||
Mach.m_nInterf = FMI_TYPE.NONE
|
||||
' recupero l'angolo di fianco
|
||||
EgtGetMachiningParam(MCH_MP.SIDEANGLE, Mach.m_dSideAng)
|
||||
Mach.m_bCanStartAll = False
|
||||
Mach.m_bCanEndAll = False
|
||||
Mach.m_bStartAll = False
|
||||
Mach.m_bEndAll = False
|
||||
' Forature e fresature
|
||||
Else
|
||||
Mach.m_nInterf = FMI_TYPE.NONE
|
||||
|
||||
+1
-1
@@ -136,7 +136,7 @@ Public Class SplitPageUC
|
||||
If Math.Abs(Mach.m_dSideAng) < EPS_ANG_SMALL Then
|
||||
sText = EgtMsg(90791) & " " & i.ToString()
|
||||
Else
|
||||
sText = EgtMsg(90791) & " " & i.ToString() & " " & DoubleToString(Mach.m_dSideAng, 1) & "°"
|
||||
sText = EgtMsg(90791) & " " & i.ToString() & " " & DoubleToString(Mach.m_dSideAng, 2) & "°"
|
||||
End If
|
||||
If Mach.m_bPause Then AddPauseText(sText)
|
||||
m_ItemList.Add(New NameIdLsBxItem(sText, i - 1, Mach.m_bEnabled))
|
||||
|
||||
Reference in New Issue
Block a user