New packet attribute for specifiying MAC layer retransmissions; reorder and commented packet attributes

This commit is contained in:
adamdunkels 2010-02-28 09:19:43 +00:00
parent 970a9eb9c7
commit 8fe15f7b45

View File

@ -40,7 +40,7 @@
*
* This file is part of the Contiki operating system.
*
* $Id: packetbuf.h,v 1.5 2010/02/06 07:48:52 adamdunkels Exp $
* $Id: packetbuf.h,v 1.6 2010/02/28 09:19:43 adamdunkels Exp $
*/
/**
@ -325,37 +325,40 @@ struct packetbuf_addr {
rimeaddr_t addr;
};
extern const char *packetbuf_attr_strings[];
#define PACKETBUF_ATTR_PACKET_TYPE_DATA 0
#define PACKETBUF_ATTR_PACKET_TYPE_ACK 1
#define PACKETBUF_ATTR_PACKET_TYPE_STREAM 2
enum {
PACKETBUF_ATTR_NONE,
/* Scope 0 attributes: used only on the local node. */
PACKETBUF_ATTR_CHANNEL,
PACKETBUF_ATTR_PACKET_ID,
PACKETBUF_ATTR_PACKET_TYPE,
PACKETBUF_ATTR_EPACKET_ID,
PACKETBUF_ATTR_EPACKET_TYPE,
PACKETBUF_ATTR_HOPS,
PACKETBUF_ATTR_TTL,
PACKETBUF_ATTR_REXMIT,
PACKETBUF_ATTR_MAX_REXMIT,
PACKETBUF_ATTR_NUM_REXMIT,
PACKETBUF_ATTR_NETWORK_ID,
PACKETBUF_ATTR_LINK_QUALITY,
PACKETBUF_ATTR_RSSI,
PACKETBUF_ATTR_TIMESTAMP,
PACKETBUF_ATTR_RADIO_TXPOWER,
PACKETBUF_ATTR_LISTEN_TIME,
PACKETBUF_ATTR_TRANSMIT_TIME,
PACKETBUF_ATTR_NETWORK_ID,
PACKETBUF_ATTR_MAX_MAC_REXMIT,
/* Scope 1 attributes: used between two neighbors only. */
PACKETBUF_ATTR_RELIABLE,
PACKETBUF_ATTR_PACKET_ID,
PACKETBUF_ATTR_PACKET_TYPE,
PACKETBUF_ATTR_REXMIT,
PACKETBUF_ATTR_MAX_REXMIT,
PACKETBUF_ATTR_NUM_REXMIT,
/* Scope 2 attributes: used between end-to-end nodes. */
PACKETBUF_ATTR_HOPS,
PACKETBUF_ATTR_TTL,
PACKETBUF_ATTR_EPACKET_ID,
PACKETBUF_ATTR_EPACKET_TYPE,
PACKETBUF_ATTR_ERELIABLE,
/* These must be last */
PACKETBUF_ADDR_SENDER,
PACKETBUF_ADDR_RECEIVER,
PACKETBUF_ADDR_ESENDER,