20.10.2013 - Modified PIObject - virtual debugName() for macro piCoutObj, improved timer measurements and timers on Windows
This commit is contained in:
12
main.cpp
12
main.cpp
@@ -125,13 +125,13 @@ public:
|
||||
bool d;
|
||||
};
|
||||
|
||||
/*
|
||||
PIDiagnostics diag;
|
||||
bool corr = true;
|
||||
void te(void * , int) {
|
||||
diag.received(256, corr);
|
||||
diag.sended(512);
|
||||
}
|
||||
|
||||
}*/
|
||||
|
||||
class ObjectA: public PIObject {
|
||||
PIOBJECT(ObjectA)
|
||||
@@ -212,10 +212,10 @@ public:
|
||||
EVENT_HANDLER2(void, re, ullong, id, int, size) {piCout << "written id =" << id << "size =" << size;}
|
||||
};
|
||||
|
||||
void tfunc(void*,int);
|
||||
PITimer tm_(tfunc);
|
||||
void tfunc(void*,int) {piCout << tm_.elapsed_m();}
|
||||
int main (int argc, char * argv[]) {
|
||||
//PIKbdListener kbd;
|
||||
//kbd.enableExitCapture();
|
||||
|
||||
/*PIEthernet::InterfaceList il = PIEthernet::interfaces();
|
||||
//const PIEthernet::Interface & i(*(il.getByName("lo")));
|
||||
piForeachC (PIEthernet::Interface & i, il)
|
||||
@@ -243,7 +243,7 @@ int main (int argc, char * argv[]) {
|
||||
int a__, b__;
|
||||
PIConsole console(false);
|
||||
console.enableExitCapture();
|
||||
PIProtocol p("/home/peri4/work/ISPUM/nosit_VM6/protocols.conf", "gas", 0, 0, &a__, 4, &b__, 4);
|
||||
PIProtocol p("/home/peri4/work/ISPUM/nosit_VM6/protocols.conf_", "gas", 0, 0, &a__, 4, &b__, 4);
|
||||
p.start();
|
||||
console.addTab("ftab", 'f');
|
||||
console.addVariable("service", &p);
|
||||
|
||||
Reference in New Issue
Block a user