Commit da164e8b authored by Pavel Vainerman's avatar Pavel Vainerman

Сделал чтобы getState искал в списке аналоговых датчиков, если не нашёл

в списке дискретных.. (аналогично getValue).
parent e6d3b605
......@@ -114,7 +114,15 @@ void IOController::sensorsUnregistration()
CORBA::Boolean IOController::getState( const IOController_i::SensorInfo& si )
{
DIOStateList::iterator li(dioList.end());
return localGetState(li,si);
try
{
return localGetState(li,si);
} // getValue if not found...
catch( IOController_i::NameNotFound )
{
AIOStateList::iterator a(aioList.end());
return (localGetValue(a,si) ? true : false);
}
}
// ------------------------------------------------------------------------------------------
......@@ -127,8 +135,8 @@ CORBA::Long IOController::getValue( const IOController_i::SensorInfo& si )
} // getState if not found...
catch( IOController_i::NameNotFound )
{
DIOStateList::iterator li(dioList.end());
return (localGetState(li,si) ? 1 : 0);
DIOStateList::iterator d(dioList.end());
return (localGetState(d,si) ? 1 : 0);
}
}
// ------------------------------------------------------------------------------------------
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment