[Tinyos-devel] How to determine low level packet type

Eric Decker cire831 at gmail.com
Fri Jul 3 16:23:54 PDT 2009


I have noticed that in both the serial and radio stack that there doesn't
seem to be a well defined mechanism for determining packet type from data in
the packet.
What are the thoughts on this?

For example, the serial stack assumes that the first byte is a dispatch byte
which determines what the rest of the packet is.  However, this byte isn't
reflected in the header definitions for the serial_header_t.

typedef nx_struct serial_header {
  nx_am_addr_t dest;
  nx_am_addr_t src;
  nx_uint8_t length;
  nx_am_group_t group;
  nx_am_id_t type;
} serial_header_t;


Similarily for the radio/15.4, I don't see where the packet type is denoted:

typedef nx_struct cc2420_header_t {
  nxle_uint8_t length;
  nxle_uint16_t fcf;
  nxle_uint8_t dsn;
  nxle_uint16_t destpan;
  nxle_uint16_t dest;
  nxle_uint16_t src;

  /** I-Frame 6LowPAN interoperability byte */
#ifdef CC2420_IFRAME_TYPE
  nxle_uint8_t network;
#endif

#ifndef TINYOS_IP
  nxle_uint8_t type;
#endif

} cc2420_header_t;


For example if we have a radio space where motes are both talking say Radio
AM messages and some other motes are talking 6lowpan
(IP) how do they stay sane?

eric


-- 
Eric B. Decker
Senior (over 50 :-) Researcher
Autonomous Systems Lab
Jack Baskin School of Engineering
UCSC
-------------- next part --------------
An HTML attachment was scrubbed...
URL: https://www.millennium.berkeley.edu/pipermail/tinyos-devel/attachments/20090703/4f560997/attachment.htm 


More information about the Tinyos-devel mailing list