manage and create wifi channel objects for the YANS model. More...
#include "yans-wifi-helper.h"
Public Member Functions | |
YansWifiChannelHelper () | |
Create a channel helper without any parameter set. | |
template<typename... Ts> | |
void | AddPropagationLoss (std::string name, Ts &&... args) |
int64_t | AssignStreams (Ptr< YansWifiChannel > c, int64_t stream) |
Assign a fixed random variable stream number to the random variables used by the channel. | |
Ptr< YansWifiChannel > | Create () const |
template<typename... Ts> | |
void | SetPropagationDelay (std::string name, Ts &&... args) |
Static Public Member Functions | |
static YansWifiChannelHelper | Default () |
Create a channel helper in a default working state. | |
Private Attributes | |
ObjectFactory | m_propagationDelay |
propagation delay model | |
std::vector< ObjectFactory > | m_propagationLoss |
vector of propagation loss models | |
manage and create wifi channel objects for the YANS model.
The intent of this class is to make it easy to create a channel object which implements the YANS channel model. The YANS channel model is described in "Yet Another Network Simulator"; an author-prepared version of this paper * is at: https://hal.inria.fr/file/index/docid/78318/filename/yans-rr.pdf
Definition at line 38 of file yans-wifi-helper.h.
ns3::YansWifiChannelHelper::YansWifiChannelHelper | ( | ) |
Create a channel helper without any parameter set.
The user must set them all to be able to call Create later.
Definition at line 39 of file yans-wifi-helper.cc.
void ns3::YansWifiChannelHelper::AddPropagationLoss | ( | std::string | name, |
Ts &&... | args | ||
) |
Ts | [deduced] Argument types |
name | the name of the model to add | |
[in] | args | Name and AttributeValue pairs to set. |
Add a propagation loss model to the set of currently-configured loss models. This method is additive to allow you to construct complex propagation loss models such as a log distance + Jakes model, etc.
The order in which PropagationLossModels are added may be significant. Some propagation models are dependent of the "txPower" (e.g. Nakagami model), and are therefore not commutative. The final receive power (excluding receiver gains) are calculated in the order the models are added.
Definition at line 159 of file yans-wifi-helper.h.
References m_propagationLoss.
Referenced by DsdvManetExample::CreateDevices(), Default(), and RoutingExperiment::Run().
int64_t ns3::YansWifiChannelHelper::AssignStreams | ( | Ptr< YansWifiChannel > | c, |
int64_t | stream | ||
) |
Assign a fixed random variable stream number to the random variables used by the channel.
Typically this corresponds to random variables used in the propagation loss models. Return the number of streams (possibly zero) that have been assigned.
c | NetDeviceContainer of the set of net devices for which the WifiNetDevice should be modified to use fixed streams |
stream | first stream index to use |
Definition at line 78 of file yans-wifi-helper.cc.
Referenced by ChainRegressionTest::CreateDevices(), Bug772ChainTest::CreateDevices(), HwmpProactiveRegressionTest::CreateDevices(), HwmpReactiveRegressionTest::CreateDevices(), HwmpSimplestRegressionTest::CreateDevices(), HwmpDoRfRegressionTest::CreateDevices(), PeerManagementProtocolRegressionTest::CreateDevices(), and FlameRegressionTest::CreateDevices().
Ptr< YansWifiChannel > ns3::YansWifiChannelHelper::Create | ( | ) | const |
Create a channel based on the configuration parameters set previously.
Definition at line 53 of file yans-wifi-helper.cc.
References ns3::ObjectFactory::Create(), m_propagationDelay, m_propagationLoss, and prev.
Referenced by BatteryLifetimeTest::ConstantLoadTest(), AodvExample::CreateDevices(), ChainRegressionTest::CreateDevices(), Bug772ChainTest::CreateDevices(), TracerouteExample::CreateDevices(), HwmpProactiveRegressionTest::CreateDevices(), HwmpReactiveRegressionTest::CreateDevices(), HwmpSimplestRegressionTest::CreateDevices(), HwmpDoRfRegressionTest::CreateDevices(), PeerManagementProtocolRegressionTest::CreateDevices(), FlameRegressionTest::CreateDevices(), DsdvManetExample::CreateDevices(), MeshTest::CreateNodes(), BasicEnergyDepletionTest::DepletionTestCase(), ns3::aodv::LoopbackTestCase::DoRun(), WifiAcMappingTest::DoRun(), WifiMsduAggregatorThroughputTest::DoRun(), RoutingExperiment::Run(), Experiment::Run(), and BatteryLifetimeTest::VariableLoadTest().
|
static |
Create a channel helper in a default working state.
By default, we create a channel model with a propagation delay equal to a constant, the speed of light, and a propagation loss based on a log distance model with a reference loss of 46.6777 dB at reference distance of 1m.
Definition at line 44 of file yans-wifi-helper.cc.
References AddPropagationLoss(), and SetPropagationDelay().
Referenced by AodvExample::CreateDevices(), ChainRegressionTest::CreateDevices(), Bug772ChainTest::CreateDevices(), TracerouteExample::CreateDevices(), HwmpProactiveRegressionTest::CreateDevices(), HwmpReactiveRegressionTest::CreateDevices(), HwmpSimplestRegressionTest::CreateDevices(), HwmpDoRfRegressionTest::CreateDevices(), PeerManagementProtocolRegressionTest::CreateDevices(), FlameRegressionTest::CreateDevices(), MeshTest::CreateNodes(), ns3::aodv::LoopbackTestCase::DoRun(), WifiAcMappingTest::DoRun(), WifiMsduAggregatorThroughputTest::DoRun(), BlockAckAggregationDisabledTest::DoRun(), PreservePacketsInAmpdus::DoRun(), Bug730TestCase::DoRun(), QosFragmentationTestCase::DoRun(), SetChannelFrequencyTest::DoRun(), Bug2222TestCase::DoRun(), Issue169TestCase::DoRun(), IdealRateManagerChannelWidthTest::DoRun(), IdealRateManagerMimoTest::DoRun(), Experiment::Run(), Issue40TestCase::RunOne(), Bug2470TestCase::RunSubtest(), and StaWifiMacScanningTestCase::Setup().
void ns3::YansWifiChannelHelper::SetPropagationDelay | ( | std::string | name, |
Ts &&... | args | ||
) |
Ts | [deduced] Argument types |
name | the name of the model to set | |
[in] | args | Name and AttributeValue pairs to set. |
Configure a propagation delay for this channel.
Definition at line 166 of file yans-wifi-helper.h.
References m_propagationDelay.
Referenced by BatteryLifetimeTest::ConstantLoadTest(), DsdvManetExample::CreateDevices(), Default(), BasicEnergyDepletionTest::DepletionTestCase(), RoutingExperiment::Run(), and BatteryLifetimeTest::VariableLoadTest().
|
private |
propagation delay model
Definition at line 105 of file yans-wifi-helper.h.
Referenced by Create(), and SetPropagationDelay().
|
private |
vector of propagation loss models
Definition at line 104 of file yans-wifi-helper.h.
Referenced by AddPropagationLoss(), and Create().