[Ns-developers] mixed-wireless example questions

Duy Nguyen dnlove at gmail.com
Sun May 3 18:13:11 PDT 2009


I've been going through the mixed-wireless example, and have a few
questions.  I really appreciate developers help.

1) NodeContainer class
Assume, multiple objects are created from NodeContainer class, then
NodeList class automatically has access to all these objects like
indices of the node?

2)OnOffHelper class
basically to turn the application on and off
It does not seem like I can bring the nodes up and down using this
class.  Do you have any pointers for bringing a specific number of
nodes down(offline) and up(online) again in the simulation.

3)CommandLine Class
For example;
int count = 5;
CommandLine cmd;
cmd.AddValue("count", "number of nodes", count);

How do I set the count at run time?
i tried
./waf --run --count=20 scratch/filename
but it does not work

4) device id
it is the id of the device to generate pcap output,
I still have a very vague idea of it.  How do you find out the device
id so you can enablePcap?

As in the third params of these funtions
CsmaHelper::EnablePcap ("mixed-wireless", appSource->GetId (), 0, false);
 YansWifiPhyHelper::EnablePcap ("mixed-wireless", 9, 2);
 YansWifiPhyHelper::EnablePcap ("mixed-wireless", 9, 0);

Thank you for your time.

Duy


More information about the Ns-developers mailing list