- Reworked the connection object and the IO system

- Reworked the support for TRICS
- Added a second generation motor
This commit is contained in:
koennecke
2009-02-03 08:05:39 +00:00
parent f6d595665e
commit 361ee9ebea
119 changed files with 16455 additions and 3674 deletions

View File

@@ -167,6 +167,30 @@ int GetDrivablePosition(void *pObject, SConnection *pCon, float *fPos)
{
return (pICountable)FindInterface(pObject,COUNTID);
}
/*--------------------------------------------------------------------------*/
int GetCountLock(pICountable self, SConnection *pCon)
{
if(self->running == 1)
{
SCWrite(pCon,"ERROR: someone else is already counting!", eError);
return 0;
}
else
{
self->running = 1;
return 1;
}
}
/*--------------------------------------------------------------------------*/
void ReleaseCountLock(pICountable self)
{
self->running = 0;
}
/*--------------------------------------------------------------------------*/
int isRunning(pICountable self)
{
return self->running;
}
/*--------------------------------------------------------------------------*/
pICallBack GetCallbackInterface(void *pObject)
{