EgtMachKernel 2.3b5 :

- aggiunto Flag2 a CamData per secondo flag dei movimenti
- nei movimenti Genera e Simula ora definito EMT.FLAG2
- in Simula possibilità di visualizzare quote assi principali anche se disabilitati come movimento EMT.ShowAxes.
This commit is contained in:
Dario Sassi
2021-02-25 14:45:25 +00:00
parent eddf28b0c4
commit cb77d0c2aa
12 changed files with 115 additions and 22 deletions
+12 -6
View File
@@ -449,13 +449,13 @@ Processor::ProcessClEnt( int nEntId, int nEntInd, int nClPathId, int nClPathInd,
case 0 : // rapido
if ( ! OnRapid( nMove, AxesEnd, pCamData->GetAxesMask(),
pCamData->GetToolDir(), pCamData->GetCorrDir(), pCamData->GetBackAuxDir(),
pCamData->GetFlag(), pCamData->GetIndex()))
pCamData->GetFlag(), pCamData->GetFlag2(), pCamData->GetIndex()))
return false ;
break ;
case 1 : // linea
if ( ! OnLinear( nMove, AxesEnd,
pCamData->GetToolDir(), pCamData->GetCorrDir(), pCamData->GetBackAuxDir(),
pCamData->GetFeed(), pCamData->GetFlag(), pCamData->GetIndex()))
pCamData->GetFeed(), pCamData->GetFlag(), pCamData->GetFlag2(), pCamData->GetIndex()))
return false ;
break ;
case 2 : // arco CW
@@ -464,7 +464,7 @@ Processor::ProcessClEnt( int nEntId, int nEntInd, int nClPathId, int nClPathInd,
ptMid.Rotate( pCamData->GetAxesCen(), pCamData->GetAxesNormDir(), - pCamData->GetAxesAngCen() / 2) ;
if ( ! OnArc( nMove, AxesEnd, pCamData->GetAxesCen(), ptMid, pCamData->GetAxesRad(), pCamData->GetAxesAngCen(),
pCamData->GetToolDir(), pCamData->GetCorrDir(), pCamData->GetBackAuxDir(),
pCamData->GetFeed(), pCamData->GetFlag(), pCamData->GetIndex()))
pCamData->GetFeed(), pCamData->GetFlag(), pCamData->GetFlag2(), pCamData->GetIndex()))
return false ;
break ;
}
@@ -959,7 +959,7 @@ Processor::OnPathEndAux( int nInd, const string& sAE)
bool
Processor::OnRapid( int nMove, const DBLVECTOR& AxesEnd, int nAxesMask,
const Vector3d& vtTool, const Vector3d& vtCorr, const Vector3d& vtAux,
int nFlag, int nIndex)
int nFlag, int nFlag2, int nIndex)
{
// cancello variabili estranee
ResetArcData() ;
@@ -983,6 +983,8 @@ Processor::OnRapid( int nMove, const DBLVECTOR& AxesEnd, int nAxesMask,
bOk = bOk && m_pMachine->LuaSetGlobVar( GLOB_VAR + GVAR_ADIR, vtAux) ;
// assegno il valore del flag
bOk = bOk && m_pMachine->LuaSetGlobVar( GLOB_VAR + GVAR_FLAG, nFlag) ;
// assegno il valore del secondo flag
bOk = bOk && m_pMachine->LuaSetGlobVar( GLOB_VAR + GVAR_FLAG2, nFlag2) ;
// assegno il valore dell'indice
bOk = bOk && m_pMachine->LuaSetGlobVar( GLOB_VAR + GVAR_INDEX, nIndex) ;
// chiamo la funzione di movimento in rapido
@@ -994,7 +996,7 @@ Processor::OnRapid( int nMove, const DBLVECTOR& AxesEnd, int nAxesMask,
bool
Processor::OnLinear( int nMove, const DBLVECTOR& AxesEnd,
const Vector3d& vtTool, const Vector3d& vtCorr, const Vector3d& vtAux,
double dFeed, int nFlag, int nIndex)
double dFeed, int nFlag, int nFlag2, int nIndex)
{
// cancello variabili estranee
ResetArcData() ;
@@ -1018,6 +1020,8 @@ Processor::OnLinear( int nMove, const DBLVECTOR& AxesEnd,
bOk = bOk && m_pMachine->LuaSetGlobVar( GLOB_VAR + GVAR_F, dFeed) ;
// assegno il valore del flag
bOk = bOk && m_pMachine->LuaSetGlobVar( GLOB_VAR + GVAR_FLAG, nFlag) ;
// assegno il valore del secondo flag
bOk = bOk && m_pMachine->LuaSetGlobVar( GLOB_VAR + GVAR_FLAG2, nFlag2) ;
// assegno il valore dell'indice
bOk = bOk && m_pMachine->LuaSetGlobVar( GLOB_VAR + GVAR_INDEX, nIndex) ;
// chiamo la funzione di movimento in rapido
@@ -1029,7 +1033,7 @@ Processor::OnLinear( int nMove, const DBLVECTOR& AxesEnd,
bool
Processor::OnArc( int nMove, const DBLVECTOR& AxesEnd, const Point3d& ptCen, const Point3d& ptMid, double dRad, double dAngCen,
const Vector3d& vtTool, const Vector3d& vtCorr, const Vector3d& vtAux,
double dFeed, int nFlag, int nIndex)
double dFeed, int nFlag, int nFlag2, int nIndex)
{
// assegno il tipo di movimento
bool bOk = m_pMachine->LuaSetGlobVar( GLOB_VAR + GVAR_MOVE, nMove) ;
@@ -1063,6 +1067,8 @@ Processor::OnArc( int nMove, const DBLVECTOR& AxesEnd, const Point3d& ptCen, con
bOk = bOk && m_pMachine->LuaSetGlobVar( GLOB_VAR + GVAR_F, dFeed) ;
// assegno il valore del flag
bOk = bOk && m_pMachine->LuaSetGlobVar( GLOB_VAR + GVAR_FLAG, nFlag) ;
// assegno il valore del secondo flag
bOk = bOk && m_pMachine->LuaSetGlobVar( GLOB_VAR + GVAR_FLAG2, nFlag2) ;
// assegno il valore dell'indice
bOk = bOk && m_pMachine->LuaSetGlobVar( GLOB_VAR + GVAR_INDEX, nIndex) ;
// chiamo la funzione di movimento in rapido