Suggestions on building a tree topology with wifi and wired nodes

39 views
Skip to first unread message

vikasha...@gmail.com

unread,
Mar 4, 2017, 10:13:23 PM3/4/17
to ns-3-users
Hi everyone,

I am new to ns-3 simulation infrastructure. I am trying to setup a complete binary tree topology which has depth 2 and all the leaf nodes(4 in number) are wifi acces-points. Other nodes are csma nodes( 3 wired nodes). So totally there are 7 nodes(1 root, 2 intermediate nodes and 4 APs). And I am trying to connect a wifi station to one of the APs in the leaf of the tree. I went through the example wifi-wired-bridging.cc and tried to extend it to make the desired topology. My final goal is to create a mobility scenario where the wifi station can move with constant velocity along a straight line and connect to any of the AP depending on the proximity. Right now I am stuck with the part where according to me the tree topology is setup but the wifi station is not able to connect to the AP. I can see that the wifi station is broadcasting beacon for association but there is no reply from the AP.

I am attaching the code for reference. Any suggestion will be really helpful and is appreciable.

Thanks and Regards,
Vikash.
wifi-wired-bridging-mine.cc

Tommaso Pecorella

unread,
Mar 5, 2017, 6:06:50 AM3/5/17
to ns-3-users
All your wifi devices are on a different channel:
      wifiPhy.SetChannel (wifiChannel.Create ());

If you do that, they'll never communicate, because the channel object is different.

T.

vikasha...@gmail.com

unread,
Mar 5, 2017, 1:51:57 PM3/5/17
to ns-3-users
Thanks Tommaso! I changed the code to use a common channel and now the wifi station is able to communicate with the wifi AP but if I change the destination as one of the csma nodes and source as wifi station, the communication is not happening. I am suspecting there is something wrong with the bridging of wifi AP and csma device. Request you to please take a look and suggest if there is something wrong with the way bridging is done. I am attaching the code as well as Pcap file for reference. I can see from the Pcap reference that wifi station is able to associate with wifi AP but to csma nodes there is not communication. My end goal is to make a mobility model so that wifi station moving with constant velocity can communicate with the root (csma node) via wifi APs.

Thanks and Regards,
Vikash.
wifi-wired-bridging-min-0-2.pcap
wifi-wired-bridging-mine.cc

vikasha...@gmail.com

unread,
Mar 5, 2017, 5:11:22 PM3/5/17
to ns-3-users
I tried a very simple topology where there are three nodes(1 csma node, 1 wifi AP and 1 wifi station). The wifi AP is connected to csma node. I am trying to send packets from wifi station to csma node via wifi AP. The association with wifi AP is happening but after that further beacons are not acknowledged or replied. I am installing a bridge device on Wifi AP as shown by example wifi-wired-bridging.cc. I am attaching the code for this simple topology setup. Please suggest if something is wrong.
wifi-wired-simple.cc

Tommaso Pecorella

unread,
Mar 5, 2017, 6:25:26 PM3/5/17
to ns-3-users
Hi,

your script is overcomplicated, and you forgot to add an IP number to the sender node.
Consider that there's a perfectly working example (wifi-wired-bridging.cc) - study it.

Cheers,

T.
Reply all
Reply to author
Forward
0 new messages