EgtMachKernel :

- aggiunta gestione attivazione e stato di visualizzazione di una operazione.
This commit is contained in:
Dario Sassi
2015-12-17 10:44:39 +00:00
parent cc2a72d5af
commit dd591f1853
6 changed files with 123 additions and 12 deletions
+4 -4
View File
@@ -65,13 +65,13 @@ Simulator::Start( void)
if ( nMachGrp == GDB_ID_NULL)
return false ;
// verifico la disposizione iniziale della macchinata
int nOpId = m_pMchMgr->GetFirstOperation() ;
int nOpId = m_pMchMgr->GetFirstActiveOperation() ;
if ( m_pMchMgr->GetOperationType( nOpId) != OPER_DISP)
return false ;
// cerco la prima lavorazione
nOpId = m_pMchMgr->GetNextOperation( nOpId) ;
nOpId = m_pMchMgr->GetNextActiveOperation( nOpId) ;
while ( nOpId != GDB_ID_NULL && ! IsValidMachiningType( m_pMchMgr->GetOperationType( nOpId)))
nOpId = m_pMchMgr->GetNextOperation( nOpId) ;
nOpId = m_pMchMgr->GetNextActiveOperation( nOpId) ;
if ( nOpId == GDB_ID_NULL)
return false ;
m_nOpId = nOpId ;
@@ -118,7 +118,7 @@ Simulator::Move( int& nStatus)
}
// Se arrivato alla fine di una lavorazione, recupero la successiva
while ( m_nCLPathId == GDB_ID_NULL) {
m_nOpId = m_pMchMgr->GetNextOperation( m_nOpId) ;
m_nOpId = m_pMchMgr->GetNextActiveOperation( m_nOpId) ;
// se non ce ne sono altre, sono alla fine
if ( m_nOpId == GDB_ID_NULL) {
nStatus = MCH_SIM_END ;