EgtMachKernel :
- piccole modifiche per gestione movimenti teste in Disposizione.
This commit is contained in:
+1
-1
@@ -1098,7 +1098,7 @@ Disposition::SpecialApply( bool bRecalc)
|
||||
bool
|
||||
Disposition::GetToolData( string& sName, string& sHead, int& nExit, string& sTcPos) const
|
||||
{
|
||||
sName = "*" + m_sHead ;
|
||||
sName = "" ;
|
||||
sHead = m_sHead ;
|
||||
nExit = m_nExit ;
|
||||
sTcPos = m_sTcPos ;
|
||||
|
||||
+5
-5
@@ -174,7 +174,7 @@ Generator::ProcessDisposition( int nOpId, int nOpInd)
|
||||
string sTool ; string sHead ; int nExit ; string sTcPos ;
|
||||
if ( ! pDisp->GetToolData( sTool, sHead, nExit, sTcPos))
|
||||
return false ;
|
||||
// Se utensile cambierà
|
||||
// Se esiste utensile corrente e cambierà, lo scarico
|
||||
if ( ! m_sTool.empty() && m_sTool != sTool) {
|
||||
// emetto deselezione vecchio utensile
|
||||
if ( ! OnToolDeselect( sTool, sHead, nExit, sTcPos))
|
||||
@@ -183,8 +183,8 @@ Generator::ProcessDisposition( int nOpId, int nOpInd)
|
||||
// Aggiorno utensile e assi macchina
|
||||
if ( ! UpdateDispTool( sTool, sHead, nExit) || ! UpdateAxes())
|
||||
return false ;
|
||||
// Se utensile cambiato, emetto selezione nuovo utensile
|
||||
if ( m_sTool != m_sPrevTool) {
|
||||
// Se utensile non definito o cambiato, emetto selezione nuovo utensile
|
||||
if ( m_sTool.empty() || m_sTool != m_sPrevTool) {
|
||||
if ( ! OnToolSelect( sTool, sHead, nExit, sTcPos))
|
||||
return false ;
|
||||
}
|
||||
@@ -462,8 +462,8 @@ Generator::UpdateDispTool( const string& sTool, const string& sHead, int nExit)
|
||||
{
|
||||
// Salvo l'utensile attuale come precedente
|
||||
m_sPrevTool = m_sTool ;
|
||||
// Se cambiato ...
|
||||
if ( sTool != m_sTool) {
|
||||
// Se non definito o cambiato ...
|
||||
if ( sTool.empty() || sTool != m_sTool) {
|
||||
// lo carico in macchina
|
||||
if ( ! m_pMchMgr->SetCalcTool( sTool, sHead, nExit))
|
||||
return false ;
|
||||
|
||||
+1
-1
@@ -210,7 +210,7 @@ Machine::SetCurrTool( const string& sTool, const string& sHead, int nExit)
|
||||
double dTOvLen = 0 ;
|
||||
double dTOvDiam = 0 ;
|
||||
// se definito
|
||||
if ( ! sTool.empty() && sTool.front() != '*') {
|
||||
if ( ! sTool.empty()) {
|
||||
if ( ! LoadTool( sHead, nExit, sTool)) {
|
||||
string sOut = "Missing tool " + sTool ;
|
||||
LOG_INFO( GetEMkLogger(), sOut.c_str())
|
||||
|
||||
+2
-2
@@ -344,8 +344,8 @@ Simulator::UpdateTool( bool bForced)
|
||||
// recupero i dati
|
||||
string sTool ; string sHead ; int nExit ; string sTcPos ;
|
||||
pDisp->GetToolData( sTool, sHead, nExit, sTcPos) ;
|
||||
// se cambierà ed esiste il corrente, lo scarico
|
||||
if ( sTool != m_sTool && ! m_sTool.empty()) {
|
||||
// se esiste utensile corrente e cambierà, lo scarico
|
||||
if ( ! m_sTool.empty() && sTool != m_sTool) {
|
||||
// eventuale lancio script per scarico utensile
|
||||
if ( ! OnToolDeselect( sTool, sHead, nExit, sTcPos))
|
||||
return false ;
|
||||
|
||||
Reference in New Issue
Block a user