Commit 06c7c27c authored by Pavel Vainerman's avatar Pavel Vainerman

new version

parent 5955d512
......@@ -31,6 +31,7 @@ static const int NoSafety = -1;
f_median(false),
ignore(false),
invert(false),
noprecision(false),
jar_state(false),
ondelay_state(false),
offdelay_state(false),
......@@ -62,6 +63,7 @@ static const int NoSafety = -1;
bool ignore; /*!< */
bool invert; /*!< */
bool noprecision;
PassiveTimer ptJar; /*!< */
PassiveTimer ptOnDelay; /*!< */
......@@ -76,6 +78,8 @@ static const int NoSafety = -1;
bool ondelay_state; /*!< */
bool offdelay_state; /*!< */
//
UniSetTypes::ObjectId t_ai; /*!< ,
,
......
......@@ -143,6 +143,10 @@ void IOBase::processingAsAI( IOBase* it, long val, SMInterface* shm, bool force
}
}
if( !it->noprecision && it->cal.precision > 0 )
val *= lround(pow10(it->cal.precision));
// "",
//
{
......@@ -150,9 +154,6 @@ void IOBase::processingAsAI( IOBase* it, long val, SMInterface* shm, bool force
if( it->value == ChannelBreakValue )
shm->localSetUndefinedState(it->ait,false,it->si.id);
if( it->cal.precision > 0 )
val *= lround(pow10(it->cal.precision));
if( force || it->value != val )
{
if( it->stype == UniversalIO::AnalogInput )
......@@ -417,6 +418,7 @@ bool IOBase::initItem( IOBase* b, UniXML_iterator& it, SMInterface* shm,
b->ignore = atoi( it.getProp("ioignore").c_str() );
b->invert = atoi( it.getProp("ioinvert").c_str() );
b->defval = atoi( it.getProp("default").c_str() );
b->noprecision = atoi( it.getProp("noprecision").c_str() );
b->value = b->defval;
b->breaklim = atoi( it.getProp("breaklim").c_str() );
......
......@@ -616,12 +616,12 @@ namespace ModbusRTU
{
ModbusData start; /*!< */
ModbusData quant; /*!< */
ModbusCRC crc;
// ------- from slave -------
ForceCoilsRetMessage( ModbusMessage& m );
ForceCoilsRetMessage& operator=( ModbusMessage& m );
void init( ModbusMessage& m );
ModbusCRC crc;
// ------- to master -------
/*!
......
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