]> oss.titaniummirror.com Git - tinyos-2.x.git/blobdiff - tos/chips/cc2420/csma/CC2420CsmaP.nc
The big interface switchover for Packet, Send, Receive, and AMSend.
[tinyos-2.x.git] / tos / chips / cc2420 / csma / CC2420CsmaP.nc
index fe497824af3b4d4040c4aab3a4f5ee48211b14e2..9dada4cae5bacfa9ae302ffb80791bad03da1e61 100644 (file)
@@ -155,8 +155,13 @@ implementation {
 
   }
 
-  command void* Send.getPayload(message_t* m) {
-    return m->data;
+  command void* Send.getPayload(message_t* m, uint8_t len) {
+    if (len <= call Send.maxPayloadLength()) {
+      return m->data;
+    }
+    else {
+      return NULL;
+    }
   }
 
   command uint8_t Send.maxPayloadLength() {