Commit bf8ca4b1 authored by Pavel Vainerman's avatar Pavel Vainerman

(UDPNet): увеличил разрешённое количество датчиков передаваемых по сети (600…

(UDPNet): увеличил разрешённое количество датчиков передаваемых по сети (600 аналоговых и 600 дискретных). И сделал "вылет" процесса, если количество оказывается больше..
parent 1fca344a
...@@ -3,7 +3,7 @@ ...@@ -3,7 +3,7 @@
Name: libuniset Name: libuniset
Version: 1.4 Version: 1.4
Release: alt9 Release: alt10
Summary: UniSet - library for building distributed industrial control systems Summary: UniSet - library for building distributed industrial control systems
License: GPL License: GPL
Group: Development/C++ Group: Development/C++
...@@ -211,6 +211,9 @@ rm -f %buildroot%_libdir/*.la ...@@ -211,6 +211,9 @@ rm -f %buildroot%_libdir/*.la
%exclude %_pkgconfigdir/libUniSet.pc %exclude %_pkgconfigdir/libUniSet.pc
%changelog %changelog
* Wed Aug 29 2012 Pavel Vainerman <pv@altlinux.ru> 1.4-alt10
- (UDPNet): increase the resolution of the sensors over the network (600 analog, 600 digital)
* Mon Aug 20 2012 Pavel Vainerman <pv@altlinux.ru> 1.4-alt9 * Mon Aug 20 2012 Pavel Vainerman <pv@altlinux.ru> 1.4-alt9
- fixed bug in previous commit (bug in UniXML::iterator::find) - fixed bug in previous commit (bug in UniXML::iterator::find)
......
...@@ -41,8 +41,8 @@ namespace UniSetUDP ...@@ -41,8 +41,8 @@ namespace UniSetUDP
friend std::ostream& operator<<( std::ostream& os, UDPAData& p ); friend std::ostream& operator<<( std::ostream& os, UDPAData& p );
}__attribute__((packed)); }__attribute__((packed));
static const size_t MaxACount = 200; static const size_t MaxACount = 600;
static const size_t MaxDCount = 400; static const size_t MaxDCount = 600;
static const size_t MaxDDataCount = MaxDCount / sizeof(unsigned char); static const size_t MaxDDataCount = MaxDCount / sizeof(unsigned char);
struct UDPPacket struct UDPPacket
......
...@@ -292,6 +292,8 @@ bool UNetSender::initItem( UniXML_iterator& it ) ...@@ -292,6 +292,8 @@ bool UNetSender::initItem( UniXML_iterator& it )
dlog[Debug::CRIT] << myname dlog[Debug::CRIT] << myname
<< "(readItem): OVERFLOW! MAX UDP DIGITAL DATA LIMIT! max=" << "(readItem): OVERFLOW! MAX UDP DIGITAL DATA LIMIT! max="
<< UniSetUDP::MaxDCount << endl; << UniSetUDP::MaxDCount << endl;
raise(SIGTERM);
return false; return false;
} }
} }
...@@ -303,6 +305,7 @@ bool UNetSender::initItem( UniXML_iterator& it ) ...@@ -303,6 +305,7 @@ bool UNetSender::initItem( UniXML_iterator& it )
dlog[Debug::CRIT] << myname dlog[Debug::CRIT] << myname
<< "(readItem): OVERFLOW! MAX UDP ANALOG DATA LIMIT! max=" << "(readItem): OVERFLOW! MAX UDP ANALOG DATA LIMIT! max="
<< UniSetUDP::MaxACount << endl; << UniSetUDP::MaxACount << endl;
raise(SIGTERM);
return false; return false;
} }
} }
......
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