]> oss.titaniummirror.com Git - tinyos-2.x.git/blobdiff - tos/lib/net/lqi/MultiHopEngineM.nc
Remove bogus 'tab:4' and 'tab:2' markers.
[tinyos-2.x.git] / tos / lib / net / lqi / MultiHopEngineM.nc
index 220c3a1e6602032b5350621ef938a8b9da0ac0cc..b567d7245bfcc7ea12161c2962937a60c2c212ac 100644 (file)
@@ -1,6 +1,6 @@
 // $Id$
 
-/*                                                                     tab:4
+/*
  * "Copyright (c) 2000-2003 The Regents of the University  of California.  
  * All rights reserved.
  *
@@ -119,15 +119,18 @@ implementation {
    ***********************************************************************/
   command error_t Send.send(message_t* pMsg, uint8_t len) {
     len += sizeof(lqi_header_t);
-    if (len > call Packet.maxPayloadLength()) {
+    if (len > call SubPacket.maxPayloadLength()) {
+      call Leds.led0On();
       return ESIZE;
     }
     if (call RootControl.isRoot()) {
+      call Leds.led1On();
       return FAIL;
     }
     call RouteSelect.initializeFields(pMsg);
     
     if (call RouteSelect.selectRoute(pMsg, 0) != SUCCESS) {
+      call Leds.led2On();
       return FAIL;
     }
     call PacketAcknowledgements.requestAck(pMsg);
@@ -168,7 +171,8 @@ implementation {
   static message_t* mForward(message_t* msg) {
     message_t* newMsg = msg;
     int8_t buf = get_buff();
-
+    call Leds.led2Toggle();
+    
     if (call RootControl.isRoot()) {
       return signal Receive.receive(msg, call Packet.getPayload(msg, NULL), call Packet.payloadLength(msg));
     }