[Tinyos-2-commits] CVS: tinyos-2.x/tos/lib/net/lqi LqiForwardingEngineP.nc, 1.8, 1.9 LqiRoutingEngineP.nc, 1.4, 1.5

Razvan Musaloiu-E. razvanm at users.sourceforge.net
Wed May 16 12:07:21 PDT 2007


Update of /cvsroot/tinyos/tinyos-2.x/tos/lib/net/lqi
In directory sc8-pr-cvs10.sourceforge.net:/tmp/cvs-serv3604

Modified Files:
	LqiForwardingEngineP.nc LqiRoutingEngineP.nc 
Log Message:
Add defaults for CollectionDebug interface.


Index: LqiForwardingEngineP.nc
===================================================================
RCS file: /cvsroot/tinyos/tinyos-2.x/tos/lib/net/lqi/LqiForwardingEngineP.nc,v
retrieving revision 1.8
retrieving revision 1.9
diff -C2 -d -r1.8 -r1.9
*** LqiForwardingEngineP.nc	18 Apr 2007 17:11:29 -0000	1.8
--- LqiForwardingEngineP.nc	16 May 2007 19:07:19 -0000	1.9
***************
*** 521,524 ****
--- 521,544 ----
     return 1;
   }
+ 
+   /* Default implementations for CollectionDebug calls.
+    * These allow CollectionDebug not to be wired to anything if debugging
+    * is not desired. */
+     
+   default command error_t CollectionDebug.logEvent(uint8_t type) {
+     return SUCCESS;
+   }
+   default command error_t CollectionDebug.logEventSimple(uint8_t type, uint16_t arg) {
+     return SUCCESS;
+   }
+   default command error_t CollectionDebug.logEventDbg(uint8_t type, uint16_t arg1, uint16_t arg2, uint16_t arg3) {
+     return SUCCESS;
+   }
+   default command error_t CollectionDebug.logEventMsg(uint8_t type, uint16_t msg, am_addr_t origin, am_addr_t node) {
+     return SUCCESS;
+   }
+   default command error_t CollectionDebug.logEventRoute(uint8_t type, am_addr_t parent, uint8_t hopcount, uint16_t metric) {
+     return SUCCESS;
+   }
  }
  

Index: LqiRoutingEngineP.nc
===================================================================
RCS file: /cvsroot/tinyos/tinyos-2.x/tos/lib/net/lqi/LqiRoutingEngineP.nc,v
retrieving revision 1.4
retrieving revision 1.5
diff -C2 -d -r1.4 -r1.5
*** LqiRoutingEngineP.nc	14 Apr 2007 00:40:59 -0000	1.4
--- LqiRoutingEngineP.nc	16 May 2007 19:07:19 -0000	1.5
***************
*** 398,401 ****
--- 398,421 ----
      msgBufBusy = FALSE;
    }
+ 
+     /* Default implementations for CollectionDebug calls.
+      * These allow CollectionDebug not to be wired to anything if debugging
+      * is not desired. */
+ 
+   default command error_t CollectionDebug.logEvent(uint8_t type) {
+     return SUCCESS;
+   }
+   default command error_t CollectionDebug.logEventSimple(uint8_t type, uint16_t arg) {
+     return SUCCESS;
+   }
+   default command error_t CollectionDebug.logEventDbg(uint8_t type, uint16_t arg1, uint16_t arg2, uint16_t arg3) {
+     return SUCCESS;
+   }
+   default command error_t CollectionDebug.logEventMsg(uint8_t type, uint16_t msg, am_addr_t origin, am_addr_t node) {
+     return SUCCESS;
+   }
+   default command error_t CollectionDebug.logEventRoute(uint8_t type, am_addr_t parent, uint8_t hopcount, uint16_t etx) {
+     return SUCCESS;
+   }
    
  }



More information about the Tinyos-2-commits mailing list