Accessing an interface on a node for installing OnOffHelper application

20 views
Skip to first unread message

Mahesh

unread,
Oct 5, 2017, 12:49:43 PM10/5/17
to ns-3-users
Hi ns3-users,

Suppose I have a node for which I install 4 different NetDevices like this

de_wireless1.Add (wifi.Install (phyHelper, wifiMac, nc_wireless.Get (0)));
de_wireless2
.Add (wifi.Install (phyHelper, wifiMac, nc_wireless.Get (0)));
de_wireless3
.Add (wifi.Install (phyHelper, wifiMac, nc_wireless.Get (0)));
de_wireless4
.Add (wifi.Install (phyHelper, wifiMac, nc_wireless.Get (0)));

Clearly, this node will have 4 interfaces or IP addresses corresponding to each NetDevice. Now how can I access any IP address on which I can install OnOffHelper's source application ? Please let me know.

Thanks,
Mahesh

Mahesh

unread,
Oct 5, 2017, 2:27:58 PM10/5/17
to ns-3-users
Can someone please help me ?

Thanks,
Mahesh

pdbarnes

unread,
Oct 6, 2017, 9:49:27 AM10/6/17
to ns-3-users
If I understand correctly you don't usually worry about the source address or device . You just open a socket to the destination address and let the routing layer figure out what the first hop should be and which outgoing device to use.

Peter

Reply all
Reply to author
Forward
0 new messages