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 27 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 28 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 148 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 65 of file yans-wifi-helper.cc.
Referenced by Bug772ChainTest::CreateDevices(), ChainRegressionTest::CreateDevices(), FlameRegressionTest::CreateDevices(), HwmpDoRfRegressionTest::CreateDevices(), HwmpProactiveRegressionTest::CreateDevices(), HwmpReactiveRegressionTest::CreateDevices(), HwmpSimplestRegressionTest::CreateDevices(), and PeerManagementProtocolRegressionTest::CreateDevices().
Ptr< YansWifiChannel > ns3::YansWifiChannelHelper::Create | ( | ) | const |
Create a channel based on the configuration parameters set previously.
Definition at line 42 of file yans-wifi-helper.cc.
References ns3::ObjectFactory::Create(), ns3::CreateObject(), m_propagationDelay, m_propagationLoss, and prev.
Referenced by BatteryLifetimeTest::ConstantLoadTest(), AodvExample::CreateDevices(), Bug772ChainTest::CreateDevices(), ChainRegressionTest::CreateDevices(), DsdvManetExample::CreateDevices(), FlameRegressionTest::CreateDevices(), HwmpDoRfRegressionTest::CreateDevices(), HwmpProactiveRegressionTest::CreateDevices(), HwmpReactiveRegressionTest::CreateDevices(), HwmpSimplestRegressionTest::CreateDevices(), PeerManagementProtocolRegressionTest::CreateDevices(), TracerouteExample::CreateDevices(), MeshTest::CreateNodes(), BasicEnergyDepletionTest::DepletionTestCase(), ns3::aodv::LoopbackTestCase::DoRun(), WifiAcMappingTest::DoRun(), WifiMsduAggregatorThroughputTest::DoRun(), WifiFilsFrameTest::DoSetup(), Experiment::Run(), Experiment::Run(), Experiment::Run(), RoutingExperiment::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 33 of file yans-wifi-helper.cc.
References AddPropagationLoss(), and SetPropagationDelay().
Referenced by AodvExample::CreateDevices(), Bug772ChainTest::CreateDevices(), ChainRegressionTest::CreateDevices(), FlameRegressionTest::CreateDevices(), HwmpDoRfRegressionTest::CreateDevices(), HwmpProactiveRegressionTest::CreateDevices(), HwmpReactiveRegressionTest::CreateDevices(), HwmpSimplestRegressionTest::CreateDevices(), PeerManagementProtocolRegressionTest::CreateDevices(), TracerouteExample::CreateDevices(), MeshTest::CreateNodes(), BlockAckAggregationDisabledTest::DoRun(), Bug2222TestCase::DoRun(), Bug730TestCase::DoRun(), DsssModulationTest::DoRun(), IdealRateManagerChannelWidthTest::DoRun(), IdealRateManagerMimoTest::DoRun(), Issue169TestCase::DoRun(), ns3::aodv::LoopbackTestCase::DoRun(), PreservePacketsInAmpdus::DoRun(), QosFragmentationTestCase::DoRun(), SetChannelFrequencyTest::DoRun(), WifiAcMappingTest::DoRun(), WifiMsduAggregatorThroughputTest::DoRun(), WifiFilsFrameTest::DoSetup(), 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 155 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 94 of file yans-wifi-helper.h.
Referenced by Create(), and SetPropagationDelay().
|
private |
vector of propagation loss models
Definition at line 93 of file yans-wifi-helper.h.
Referenced by AddPropagationLoss(), and Create().