EgtMachKernel :

- correzione molto importante a Start simulazione.
This commit is contained in:
Dario Sassi
2017-04-21 14:37:32 +00:00
parent d640e85550
commit d75a5fdde8
2 changed files with 8 additions and 5 deletions
+7 -4
View File
@@ -101,7 +101,7 @@ Simulator::Start( bool bFirst)
// Arrivo alla preparazione per la prima lavorazione
int nStatus ;
return FindAndManageOperationStart( bFirst, nStatus) ;
return FindAndManageOperationStart( true, bFirst, nStatus) ;
}
//----------------------------------------------------------------------------
@@ -141,7 +141,7 @@ Simulator::Move( int& nStatus)
if ( ! ManageOperationEnd( nStatus))
return false ;
// ricerca e gestione nuova operazione
if ( ! FindAndManageOperationStart( false, nStatus))
if ( ! FindAndManageOperationStart( false, false, nStatus))
return false ;
// se non ce ne sono altre, sono alla fine
if ( m_nOpId == GDB_ID_NULL) {
@@ -433,10 +433,13 @@ Simulator::ResetAuxAxes( void)
//----------------------------------------------------------------------------
bool
Simulator::FindAndManageOperationStart( bool bFirst, int& nStatus)
Simulator::FindAndManageOperationStart( bool bStart, bool bFirst, int& nStatus)
{
// verifico parametri
if ( ! bStart)
bFirst = false ;
// recupero la nuova operazione
if ( bFirst) {
if ( bStart) {
m_nOpId = m_pMchMgr->GetFirstActiveOperation() ;
m_nOpInd = 0 ;
}