]> oss.titaniummirror.com Git - tinyos-2.x.git/commitdiff
Support for I-frames is on by default.
authorscipio <scipio>
Mon, 16 Jun 2008 22:45:07 +0000 (22:45 +0000)
committerscipio <scipio>
Mon, 16 Jun 2008 22:45:07 +0000 (22:45 +0000)
Fix TinyOSNetworkP to support changes to Receive
and getPayload().

tos/chips/cc2420/CC2420.h
tos/chips/cc2420/lowpan/CC2420TinyosNetworkP.nc

index 83cee7c283bafc0db47e8dcc5e02f44de3d40ec1..a3413ec2d061721657aa2ac0ee963e2ab0e734a3 100644 (file)
 
 typedef uint8_t cc2420_status_t;
 
+#ifndef TFRAMES_ENABLED
+#define CC2420_IFRAME_TYPE
+#endif
+
 /**
  * CC2420 header.  An I-frame (interoperability frame) header has an 
  * extra network byte specified by 6LowPAN
@@ -119,10 +123,10 @@ typedef nx_struct cc2420_packet_t {
 #endif
 
 /** 
- * The 6LowPAN ID has yet to be defined for a TinyOS network.
+ * The 6LowPAN NALP ID for a TinyOS network is 63 (TEP 125).
  */
 #ifndef TINYOS_6LOWPAN_NETWORK_ID
-#define TINYOS_6LOWPAN_NETWORK_ID 0x0
+#define TINYOS_6LOWPAN_NETWORK_ID 0x3f
 #endif
 
 
index 0bd6dc583f550e58792911dcc3a3f62a8e6fd0df..6c2570c4a5c1f458f2ac4cc789b9a2f0938512b5 100644 (file)
@@ -71,26 +71,8 @@ implementation {
     return call SubSend.maxPayloadLength();
   }
 
-  command void* Send.getPayload(message_t* msg) {
-    return call SubSend.getPayload(msg);
-  }
-  
-  /***************** Receive Commands ****************/
-  command void* Receive.getPayload(message_t* msg, uint8_t* len) {
-    return call SubReceive.getPayload(msg, len);
-  }
-
-  command uint8_t Receive.payloadLength(message_t* msg) {
-    return call SubReceive.payloadLength(msg);
-  }
-  
-  /***************** NonTinyosReceive Commands ****************/
-  command void* NonTinyosReceive.getPayload[uint8_t networkId](message_t* msg, uint8_t* len) {
-    return call SubReceive.getPayload(msg, len);
-  }
-
-  command uint8_t NonTinyosReceive.payloadLength[uint8_t networkId](message_t* msg) {
-    return call SubReceive.payloadLength(msg);
+  command void* Send.getPayload(message_t* msg, uint8_t len) {
+    return call SubSend.getPayload(msg, len);
   }
   
   /***************** SubSend Events *****************/