EgtMachKernel 1.6k6 :
- aggiunta a simulazione funzione per info e posizione assi.
This commit is contained in:
+18
-1
@@ -70,7 +70,7 @@ Simulator::Start( void)
|
||||
return false ;
|
||||
// cerco la prima lavorazione
|
||||
nOpId = m_pMchMgr->GetNextOperation( nOpId) ;
|
||||
while ( nOpId != GDB_ID_NULL && ( m_pMchMgr->GetOperationType( nOpId) & OPER_MACH) == 0)
|
||||
while ( nOpId != GDB_ID_NULL && ! IsValidMachiningType( m_pMchMgr->GetOperationType( nOpId)))
|
||||
nOpId = m_pMchMgr->GetNextOperation( nOpId) ;
|
||||
if ( nOpId == GDB_ID_NULL)
|
||||
return false ;
|
||||
@@ -97,6 +97,9 @@ Simulator::Start( void)
|
||||
bool
|
||||
Simulator::Move( void)
|
||||
{
|
||||
// Verifiche
|
||||
if ( m_pMchMgr == nullptr || m_pGeomDB == nullptr)
|
||||
return false ;
|
||||
// Se arrivato alla fine dell'interpolazione, recupero una nuova entità
|
||||
if ( m_dCoeff > 0.999) {
|
||||
m_nEntId = m_pGeomDB->GetNext( m_nEntId) ;
|
||||
@@ -152,6 +155,20 @@ Simulator::Move( void)
|
||||
return true ;
|
||||
}
|
||||
|
||||
//----------------------------------------------------------------------------
|
||||
bool
|
||||
Simulator::GetAxisInfoPos( int nI, string& sName, double& dVal)
|
||||
{
|
||||
// Verifiche
|
||||
if ( m_pMchMgr == nullptr || m_pGeomDB == nullptr)
|
||||
return false ;
|
||||
// recupero i dati dell'asse
|
||||
if ( nI < 0 || nI >= int( m_AxesName.size()))
|
||||
return false ;
|
||||
sName = m_AxesName[nI] ;
|
||||
return m_pMchMgr->GetAxisPos( sName, dVal) ;
|
||||
}
|
||||
|
||||
//----------------------------------------------------------------------------
|
||||
bool
|
||||
Simulator::SetStep( double dStep)
|
||||
|
||||
Reference in New Issue
Block a user