git-svn-id: svn://db.shs.com.ru/pip@561 12ceb7fc-bf1f-11e4-8940-5bc7170c53b5

This commit is contained in:
2017-11-27 08:49:22 +00:00
parent 1e1f0e9778
commit 6cd7c12d66
3 changed files with 6 additions and 6 deletions

View File

@@ -1,7 +1,7 @@
#include "pip.h"
class Client: public PIObject {
PIOBJECT(Client);
PIOBJECT(Client)
public:
Client(PIEthernet * eth_) {
eth = eth_;
@@ -12,7 +12,7 @@ public:
}
~Client() {}
EVENT_HANDLER2(void, readed, uchar * , data, int, size) {
PIByteArray ba(data, size)
PIByteArray ba(data, size);
piCoutObj << uint(eth) << "readed" << size << "bytes" << Hex << ba;
eth->write(ba);
}
@@ -32,7 +32,7 @@ public:
};
class Server: public PIObject {
PIOBJECT(Server);
PIOBJECT(Server)
public:
Server(int port) {
eth = new PIEthernet(PIEthernet::TCP_Server);