Dear Gomathi, Your question is not clear. What neighbor you are looking for? If you are looking for routing neighbours you can only do in routing layer. If you are looking for Radio Range or Carrier Sense neightbour you can do either using a) routing.cc - this approach has been recently elaborated, kindly check the NS2 messages archive ,or b) channel.cc - WirelessChannel::getAffectedNodes() would be of your interest. Do take note, if you use this approach, you would need to modify the square radio range to a circular radio range to better exhibit the transmission property of radio of a wireless node.
Dont think you could do MAC layer in the present form, as the neighbour management is only done in routing layer. Good Luck. rgds Saravanan K On Mon, May 27, 2013 at 4:13 AM, Gomathi Rajamanickam <gomathi250...@gmail.com> wrote: > > Hi, > I am doing my project in MAC layer. I want to form a neighbor table for > each node in MAC layer. Please any one help me how to form neighbor list in > MAC layer? > > Regards, > R. Gomathi