[Tinyos Core WG] Interface proposals and agreed upon changes, condensed

Philip Levis pal at cs.stanford.edu
Wed Jun 13 09:24:45 PDT 2007


Agreed on change to AMPacket for 2.0.2:

interface AMPacket {
   // Current commands
   command am_addr_t address();
   command bool isForMe(message_t* amsg);
   command am_addr_t destination(message_t* amsg);
   command am_addr_t source(message_t* amsg);
   command am_id_t type(message_t* amsg);
   command void setDestination(message_t* amsg, am_addr_t addr);
   command void setSource(message_t* amsg, am_addr_t addr);
   command void setType(message_t* amsg, am_id_t t);

   // New commands
   command am_group_t group(message_t* amsg);
   command void setGroup(message_t* amsg, am_group_t group);
}

Proposal from net2 for 2.X.X:

interface PacketPhyQuality {
   command bool hasHighQuality(message_t* pmsg);
}

Proposal from David Moss (note it is async so SIDs do not apply) for  
2.0.2:

interface ActiveMessageAddress {
   async command am_addr_t amAddress();
   async command void setAmAddress(am_addr_t a);
   async event void addressChanged(am_addr_t a);
}

Agreed-upon change to Packet for 2.1:

   command void* getPayload(message_t* msg, uint8_t* len);

   becomes

   command void* getPayload(message_t* msg, uint8_t minLen);
   // Note that Packet has a payloadLength() command as well as a  
maxPayloadLength()

Agreed upon change to Receive for 2.1:

interface Receive {
   event message_t* receive(message_t* msg, void* payload, uint8_t len);

   // Lose these two commands
   command void* getPayload(message_t* msg, uint8_t* len);
   command uint8_t payloadLength(message_t* msg);
}

One packet issue still remains, timestamps.

Phil





More information about the Tinyos-2.0wg mailing list