Helper class for UAN CW MAC example. More...
#include "uan-animation.h"
Collaboration diagram for NetAnimExperiment:Public Member Functions | |
| NetAnimExperiment () | |
| the experiment More... | |
| void | IncrementCw (uint32_t cw) |
| Increment CW function. More... | |
| void | ReceivePacket (Ptr< Socket > socket) |
| Receive packet function. More... | |
| void | ResetData () |
| Reset data function. More... | |
| void | Run (UanHelper &uan) |
| Run function. More... | |
| void | UpdatePositions (NodeContainer &nodes) |
| Update positions function. More... | |
Public Attributes | |
| uint32_t | m_avgs |
| averages More... | |
| double | m_boundary |
| boundary More... | |
| uint32_t | m_bytesTotal |
| bytes total More... | |
| uint32_t | m_cwMax |
| CW maximum. More... | |
| uint32_t | m_cwMin |
| CW minimum. More... | |
| uint32_t | m_cwStep |
| CW step. More... | |
| uint32_t | m_dataRate |
| data rate More... | |
| double | m_depth |
| depth More... | |
| uint32_t | m_numNodes |
| number of nodes More... | |
| uint32_t | m_packetSize |
| packet size More... | |
| Time | m_simTime |
| simulation time More... | |
| Time | m_slotTime |
| slot time More... | |
| std::vector< double > | m_throughputs |
| throughputs More... | |
Helper class for UAN CW MAC example.
Definition at line 34 of file uan-animation.h.
| NetAnimExperiment::NetAnimExperiment | ( | ) |
the experiment
Definition at line 52 of file uan-animation.cc.
| void NetAnimExperiment::IncrementCw | ( | uint32_t | cw | ) |
Increment CW function.
| cw | the CW |
Definition at line 77 of file uan-animation.cc.
References m_avgs, m_cwStep, m_throughputs, NS_ASSERT, NS_LOG_DEBUG, and ns3::Config::Set().
Referenced by Run().
Here is the call graph for this function:
Here is the caller graph for this function:Receive packet function.
| socket | the socket to receive from |
Definition at line 112 of file uan-animation.cc.
References ns3::Packet::GetSize(), m_bytesTotal, and ns3::Socket::Recv().
Referenced by Run().
Here is the call graph for this function:
Here is the caller graph for this function:| void NetAnimExperiment::ResetData | ( | ) |
Reset data function.
Definition at line 69 of file uan-animation.cc.
References ns3::Time::GetSeconds(), m_bytesTotal, m_simTime, m_throughputs, ns3::Now(), and NS_LOG_DEBUG.
Referenced by Run().
Here is the call graph for this function:
Here is the caller graph for this function:| void NetAnimExperiment::Run | ( | UanHelper & | uan | ) |
Run function.
| uan | the UAN helper |
Definition at line 124 of file uan-animation.cc.
References ns3::ListPositionAllocator::Add(), ns3::Object::AggregateObject(), ns3::Socket::Bind(), third::channel, ns3::NodeContainer::Create(), first::devices, ns3::NetDeviceContainer::Get(), ns3::NodeContainer::Get(), ns3::NetDeviceContainer::GetN(), ns3::NodeContainer::GetN(), ns3::Object::GetObject(), GetPosition(), ns3::UniformRandomVariable::GetValue(), IncrementCw(), ns3::PacketSocketHelper::Install(), ns3::OnOffHelper::Install(), ns3::UanHelper::Install(), m_avgs, m_boundary, m_bytesTotal, m_cwMax, m_cwMin, m_cwStep, m_dataRate, m_depth, m_numNodes, m_packetSize, m_simTime, m_slotTime, ns3::MakeCallback(), min, third::mobility, NS_LOG_DEBUG, ReceivePacket(), ResetData(), ns3::Seconds(), ns3::OnOffHelper::SetAttribute(), ns3::ObjectBase::SetAttribute(), ns3::UanHelper::SetMac(), ns3::PacketSocketAddress::SetPhysicalAddress(), ns3::PacketSocketAddress::SetProtocol(), ns3::Socket::SetRecvCallback(), ns3::PacketSocketAddress::SetSingleDevice(), sink, ns3::ApplicationContainer::Start(), ns3::ApplicationContainer::Stop(), UpdatePositions(), and sample-rng-plot::x.
Here is the call graph for this function:| void NetAnimExperiment::UpdatePositions | ( | NodeContainer & | nodes | ) |
Update positions function.
| nodes | the collection of nodes |
Definition at line 96 of file uan-animation.cc.
References ns3::Object::GetObject(), ns3::UniformRandomVariable::GetValue(), m_boundary, first::nodes, ns3::Now(), NS_LOG_DEBUG, ns3::ObjectBase::SetAttribute(), and ns3::MobilityModel::SetPosition().
Referenced by Run().
Here is the call graph for this function:
Here is the caller graph for this function:| uint32_t NetAnimExperiment::m_avgs |
| double NetAnimExperiment::m_boundary |
| uint32_t NetAnimExperiment::m_bytesTotal |
bytes total
Definition at line 64 of file uan-animation.h.
Referenced by ReceivePacket(), ResetData(), and Run().
| uint32_t NetAnimExperiment::m_cwMax |
| uint32_t NetAnimExperiment::m_cwMin |
| uint32_t NetAnimExperiment::m_cwStep |
| uint32_t NetAnimExperiment::m_dataRate |
| double NetAnimExperiment::m_depth |
| uint32_t NetAnimExperiment::m_numNodes |
| uint32_t NetAnimExperiment::m_packetSize |
| Time NetAnimExperiment::m_simTime |
simulation time
Definition at line 71 of file uan-animation.h.
Referenced by ResetData(), and Run().
| Time NetAnimExperiment::m_slotTime |
| std::vector<double> NetAnimExperiment::m_throughputs |
throughputs
Definition at line 73 of file uan-animation.h.
Referenced by IncrementCw(), and ResetData().