[Tinyos-contrib-commits] CVS: tinyos-1.x/contrib/wustl/apps/Agilla/components ExpLoggerC.nc, 1.3, 1.4 ExpLoggerM.nc, 1.6, 1.7 MessageBufferM.nc, 1.2, 1.3

Chien-Liang Fok chien-liang at users.sourceforge.net
Fri Apr 21 14:57:00 PDT 2006


Update of /cvsroot/tinyos/tinyos-1.x/contrib/wustl/apps/Agilla/components
In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv20992/components

Modified Files:
	ExpLoggerC.nc ExpLoggerM.nc MessageBufferM.nc 
Log Message:


Index: ExpLoggerC.nc
===================================================================
RCS file: /cvsroot/tinyos/tinyos-1.x/contrib/wustl/apps/Agilla/components/ExpLoggerC.nc,v
retrieving revision 1.3
retrieving revision 1.4
diff -C2 -d -r1.3 -r1.4
*** ExpLoggerC.nc	11 Apr 2006 06:18:18 -0000	1.3
--- ExpLoggerC.nc	21 Apr 2006 21:56:58 -0000	1.4
***************
*** 21,25 ****
    ExpLoggerM.SendTrace -> NetworkInterfaceProxy.SendMsg[AM_AGILLATRACEMSG];
    ExpLoggerM.SendGetAgentsResultsTrace -> NetworkInterfaceProxy.SendMsg[AM_AGILLATRACEGETAGENTSMSG];
!   ExpLoggerM.ReceiveQuery -> NetworkInterfaceProxy.ReceiveMsg[AM_AGILLAEXPQUERYRESULTSMSG];  
    ExpLoggerM.MessageBufferI -> MessageBufferM;
    ExpLoggerM.Time -> SimpleTime;
--- 21,25 ----
    ExpLoggerM.SendTrace -> NetworkInterfaceProxy.SendMsg[AM_AGILLATRACEMSG];
    ExpLoggerM.SendGetAgentsResultsTrace -> NetworkInterfaceProxy.SendMsg[AM_AGILLATRACEGETAGENTSMSG];
!   //ExpLoggerM.ReceiveQuery -> NetworkInterfaceProxy.ReceiveMsg[AM_AGILLAEXPQUERYRESULTSMSG];  
    ExpLoggerM.MessageBufferI -> MessageBufferM;
    ExpLoggerM.Time -> SimpleTime;

Index: ExpLoggerM.nc
===================================================================
RCS file: /cvsroot/tinyos/tinyos-1.x/contrib/wustl/apps/Agilla/components/ExpLoggerM.nc,v
retrieving revision 1.6
retrieving revision 1.7
diff -C2 -d -r1.6 -r1.7
*** ExpLoggerM.nc	20 Apr 2006 22:05:58 -0000	1.6
--- ExpLoggerM.nc	21 Apr 2006 21:56:58 -0000	1.7
***************
*** 10,14 ****
      interface SendMsg as SendTrace;
      interface SendMsg as SendGetAgentsResultsTrace;
!     interface ReceiveMsg as ReceiveQuery;
      interface MessageBufferI;
      interface Time;
--- 10,14 ----
      interface SendMsg as SendTrace;
      interface SendMsg as SendGetAgentsResultsTrace;
!     //interface ReceiveMsg as ReceiveQuery;
      interface MessageBufferI;
      interface Time;
***************
*** 93,102 ****
    }  
    
    command result_t ExpLoggerI.sendGetAgentsResultsTrace(AgillaQueryReplyAllAgentsMsg* replyMsg)
    {
!     TOS_MsgPtr msg = call MessageBufferI.getMsg();
!     uint16_t i;
      if (msg != NULL)
      {
        struct AgillaTraceGetAgentsMsg *traceMsg = (struct AgillaTraceGetAgentsMsg *)msg->data;
        traceMsg->timestamp = call Time.get();
--- 93,106 ----
    }  
    
+   
+   /**
+    * This is a special trace for recording operation GetAgents.
+    */
    command result_t ExpLoggerI.sendGetAgentsResultsTrace(AgillaQueryReplyAllAgentsMsg* replyMsg)
    {
!     TOS_MsgPtr msg = call MessageBufferI.getMsg();    
      if (msg != NULL)
      {
+       uint16_t i;
        struct AgillaTraceGetAgentsMsg *traceMsg = (struct AgillaTraceGetAgentsMsg *)msg->data;
        traceMsg->timestamp = call Time.get();

Index: MessageBufferM.nc
===================================================================
RCS file: /cvsroot/tinyos/tinyos-1.x/contrib/wustl/apps/Agilla/components/MessageBufferM.nc,v
retrieving revision 1.2
retrieving revision 1.3
diff -C2 -d -r1.2 -r1.3
*** MessageBufferM.nc	12 Feb 2006 07:11:21 -0000	1.2
--- MessageBufferM.nc	21 Apr 2006 21:56:58 -0000	1.3
***************
*** 97,101 ****
      
      #if DEBUG_MESSAGE_BUFFER
!       uint16_t j, k;
      #endif
      
--- 97,101 ----
      
      #if DEBUG_MESSAGE_BUFFER
!       uint16_t freeCount, k;
      #endif
      
***************
*** 105,114 ****
  
          #if DEBUG_MESSAGE_BUFFER
!           j = 0;
            for (k = 0; k < MESSAGE_BUFFER_SIZE; k++) {
              if (msgBuffPtr[k] != NULL)
!               j++;
            }        
!           dbg(DBG_USR1, "MessageBufferI: buffer %i de-allocated, %i free.\n", i, j);      
          #endif
          
--- 105,114 ----
  
          #if DEBUG_MESSAGE_BUFFER
!           freeCount = 0;
            for (k = 0; k < MESSAGE_BUFFER_SIZE; k++) {
              if (msgBuffPtr[k] != NULL)
!               freeCount++;
            }        
!           dbg(DBG_USR1, "MessageBufferI: buffer %i de-allocated, %i free.\n", i, freeCount);      
          #endif
          



More information about the Tinyos-contrib-commits mailing list