[Ns-developers] Regarding 802.15 MAC Layer

Tom Henderson tomh at tomh.org
Tue Mar 3 10:21:16 PST 2009


Ruturaj Dhekane wrote:
> Hi,
> 
> I am working on a Wireless Sensor Networks based research project. I would
> like to simulate the WSN nodes. However 802.15.x MAC layer isnt currently
> available with NS-3.
> 
> I would like to have some pointers from the developer community regarding
> writing our own MAC layer. (As in where do I begin, and How?)

This is a piece of documentation that needs to be written.

For starters, I would recommend starting by cloning the SimpleNetDevice 
and SimpleChannel found in src/node directory, and rename it to 
something else.  This net device and channel simply pass packets between 
nodes.  The next step might be to add a new header.  A new header class 
needs to be written.  the UDP header implementation (src/internet-node/ 
directory) probably is a simple-enough example of this. After some 
semblance of a header is being serialized to and from the packets, you 
can start to think of adding more logic and detail to the models; 
perhaps add a Phy class.

For wireless channels, however, you will probably want to study the 
structure of the wifi netdevice before too long.

> 
> Would also like to know certain fields in which I might be able to
> contribute to NS-3 code in general.
> 
>

WPAN would be helpful since there seems to be a lot of interest.  There 
is an ns-2 implementation from CUNY that might be portable.  Also, see 
the earlier mail about GSOC project ideas.

Tom


More information about the Ns-developers mailing list