Arianna autonomous DAQ firmware
Dependencies: mbed SDFileSystemFilinfo AriSnProtocol NetServicesMin AriSnComm MODSERIAL PowerControlClkPatch DS1820OW
Diff: SnCommAfarTCP.cpp
- Revision:
- 16:744ce85aede2
- Parent:
- 15:f2569d8e4176
- Child:
- 18:55f1581f2ee4
--- a/SnCommAfarTCP.cpp Fri Aug 31 02:09:09 2012 +0000 +++ b/SnCommAfarTCP.cpp Wed Sep 12 04:47:22 2012 +0000 @@ -6,6 +6,8 @@ #include "Watchdog.h" +//#define DEBUG + #define CALL_MEMBER_FN(object,ptrToMember) ((object).*(ptrToMember)) SnCommAfarTCP::SnCommAfarTCP(const SnConfigFrame& conf) : @@ -15,6 +17,10 @@ fMyGate(conf.GetMbedGate()), fEth(new EthernetInterface), fSock(new TCPSocketConnection) { +#ifdef DEBUG + printf("init. ip=%s, mas=%s, gate=%s\r\n", + fMyIp.c_str(),fMyMask.c_str(), fMyGate.c_str()); +#endif fEth->init(fMyIp.c_str(),fMyMask.c_str(), fMyGate.c_str()); } @@ -77,7 +83,7 @@ }; Watchdog::kick(); // don't reset; wait until timeout } - return res; // timeout + return b; // timeout } int32_t SnCommAfarTCP::ReceiveAll(char* const buf, const uint32_t mlen,