[Tinyos-beta-commits] CVS: tinyos-1.x/beta/SystemCore/Grouper GrouperM.nc, 1.2, 1.3

Gilman Tolle gtolle at users.sourceforge.net
Mon Sep 20 20:57:55 PDT 2004


Update of /cvsroot/tinyos/tinyos-1.x/beta/SystemCore/Grouper
In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv23049/Grouper

Modified Files:
	GrouperM.nc 
Log Message:
* MultiHopRSSI will now use the LQI indicator available on the CC2420
radio. This may suggest a name change. Any suggestions?

* The MultiHopRSSI tree construction message now can have a
user-settable period. It's included in the message.




Index: GrouperM.nc
===================================================================
RCS file: /cvsroot/tinyos/tinyos-1.x/beta/SystemCore/Grouper/GrouperM.nc,v
retrieving revision 1.2
retrieving revision 1.3
diff -C2 -d -r1.2 -r1.3
*** GrouperM.nc	11 Aug 2004 23:36:28 -0000	1.2
--- GrouperM.nc	21 Sep 2004 03:57:53 -0000	1.3
***************
*** 16,24 ****
    
    command result_t StdControl.init() {
-     call Drip.init(); (void) unique("Drip");
- 
      return SUCCESS;
    }
    command result_t StdControl.start() {
      return SUCCESS;
    }
--- 16,23 ----
    
    command result_t StdControl.init() {
      return SUCCESS;
    }
    command result_t StdControl.start() {
+     call Drip.init(); (void) unique("Drip");
      return SUCCESS;
    }
***************
*** 50,70 ****
    event result_t Drip.rebroadcastRequest(TOS_MsgPtr msg, void* pData) {
  
!     if (call Naming.isIntermediary(&namingMsgCache)) {
!       GrouperCmdMsg *cmdMsg;
!       
!       NamingMsg *namingMsg = (NamingMsg*) pData;
!       memcpy(namingMsg, &namingMsgCache, sizeof(namingMsgCache));
  
!       call Naming.prepareRebroadcast(msg, namingMsg);
  
!       cmdMsg = (GrouperCmdMsg *) call Naming.getBuffer(namingMsg);
!       memcpy(cmdMsg, &cmdMsgCache, sizeof(cmdMsgCache));
  
!       call Drip.rebroadcast(msg, pData, 
! 			    sizeof(namingMsgCache) + 
! 			    sizeof(cmdMsgCache));
!       return SUCCESS;
!     }
!     return FAIL;
    }
  }
--- 49,72 ----
    event result_t Drip.rebroadcastRequest(TOS_MsgPtr msg, void* pData) {
  
!     GrouperCmdMsg *cmdMsg;
!     NamingMsg *namingMsg = (NamingMsg*) pData;
  
!     if (!call Naming.isIntermediary(&namingMsgCache))
!       return FAIL;
  
!     memcpy(namingMsg, &namingMsgCache, sizeof(namingMsgCache));
!     
!     call Naming.prepareRebroadcast(msg, namingMsg);
!     
!     cmdMsg = (GrouperCmdMsg *) call Naming.getBuffer(namingMsg);
!     memcpy(cmdMsg, &cmdMsgCache, sizeof(cmdMsgCache));
  
!     dripMsg = msg;
!     dripMsgData = pData;
! 
!     call Drip.rebroadcast(msg, pData, 
! 			  sizeof(namingMsgCache) + 
! 			  sizeof(cmdMsgCache));
!     return SUCCESS;
    }
  }



More information about the Tinyos-beta-commits mailing list