[Tinyos-2-commits] CVS: tinyos-2.x/apps/tests/TestNetwork
TestNetworkAppC.nc, 1.1.2.13, 1.1.2.14 TestNetworkC.nc,
1.1.2.15, 1.1.2.16
Omprakash Gnawali
gnawali at users.sourceforge.net
Sun Oct 15 19:25:31 PDT 2006
Update of /cvsroot/tinyos/tinyos-2.x/apps/tests/TestNetwork
In directory sc8-pr-cvs10.sourceforge.net:/tmp/cvs-serv16420
Modified Files:
Tag: tinyos-2_0_devel-BRANCH
TestNetworkAppC.nc TestNetworkC.nc
Log Message:
log application failures
Index: TestNetworkAppC.nc
===================================================================
RCS file: /cvsroot/tinyos/tinyos-2.x/apps/tests/TestNetwork/TestNetworkAppC.nc,v
retrieving revision 1.1.2.13
retrieving revision 1.1.2.14
diff -C2 -d -r1.1.2.13 -r1.1.2.14
*** TestNetworkAppC.nc 3 Oct 2006 00:18:43 -0000 1.1.2.13
--- TestNetworkAppC.nc 16 Oct 2006 02:25:29 -0000 1.1.2.14
***************
*** 51,53 ****
--- 51,55 ----
DebugSender.SendQueue -> DebugSendQueue;
Collector.CollectionDebug -> DebugSender;
+ TestNetworkC.CollectionDebug -> DebugSender;
+ TestNetworkC.AMPacket -> ActiveMessageC;
}
Index: TestNetworkC.nc
===================================================================
RCS file: /cvsroot/tinyos/tinyos-2.x/apps/tests/TestNetwork/TestNetworkC.nc,v
retrieving revision 1.1.2.15
retrieving revision 1.1.2.16
diff -C2 -d -r1.1.2.15 -r1.1.2.16
*** TestNetworkC.nc 3 Oct 2006 00:18:43 -0000 1.1.2.15
--- TestNetworkC.nc 16 Oct 2006 02:25:29 -0000 1.1.2.16
***************
*** 13,16 ****
--- 13,17 ----
#include <Timer.h>
#include "TestNetwork.h"
+ #include "CtpDebugMsg.h"
module TestNetworkC {
***************
*** 30,33 ****
--- 31,36 ----
uses interface CtpInfo;
uses interface Random;
+ uses interface CollectionDebug;
+ uses interface AMPacket;
}
implementation {
***************
*** 69,73 ****
if (firstTimer) {
firstTimer = FALSE;
! call Timer.startPeriodic(1024);
}
if (busy || call ReadSensor.read() != SUCCESS) {
--- 72,76 ----
if (firstTimer) {
firstTimer = FALSE;
! call Timer.startPeriodic(10240);
}
if (busy || call ReadSensor.read() != SUCCESS) {
***************
*** 80,83 ****
--- 83,87 ----
void failedSend() {
dbg("App", "%s: Send failed.\n", __FUNCTION__);
+ call CollectionDebug.logEvent(NET_C_DBG_1);
}
***************
*** 150,153 ****
--- 154,161 ----
dbg("Traffic", "Sending packet to UART.\n");
if (call UARTSend.send(0xffff, recvPtr, msglen) != SUCCESS) {
+ call CollectionDebug.logEventMsg(NET_C_DBG_2,
+ call CollectionPacket.getSequenceNumber(recvPtr),
+ call CollectionPacket.getOrigin(recvPtr),
+ call AMPacket.destination(recvPtr));
uartbusy = FALSE;
}
More information about the Tinyos-2-commits
mailing list