Hello everyone,
I am trying to simulate CAP-SV routing protocol for ad hoc networks,
derived from AODV. I need to control the transmission power of each
node and vary it according to the next hop since my protocol logs the
min. power to reach each neighbor. Is there anyone who knows how to
achieve this through C++? I tried the following and it did not work:

Tcl& tcl = Tcl::instance();
tcl.evalf("Phy/WirelessPhy set Pt_ %f", myPower);

Or, can I reach the WirelessPhy object through mac/mac-802_11.cc?
There is a variable called "netif_" through which I can reach the
nodes and their energy modules as netif_->node()->energy_model(), but
the problem is netif_ is a "Phy *" instance, not "WirelessPhy *".

Another thing is what is the relation between Pt_ and Pt_consume_?

I am supposed to complete my MS thesis in a month or so, so I am very
short on time. Any help is appreciated. Thanks,

Akif

Reply via email to