A Discrete-Event Network Simulator
API
NetAnimExperiment Class Reference

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...
 

Detailed Description

Helper class for UAN CW MAC example.

Definition at line 34 of file uan-animation.h.

Constructor & Destructor Documentation

◆ NetAnimExperiment()

NetAnimExperiment::NetAnimExperiment ( )

the experiment

Definition at line 52 of file uan-animation.cc.

Member Function Documentation

◆ IncrementCw()

void NetAnimExperiment::IncrementCw ( uint32_t  cw)

Increment CW function.

Parameters
cwthe 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:

◆ ReceivePacket()

void NetAnimExperiment::ReceivePacket ( Ptr< Socket socket)

Receive packet function.

Parameters
socketthe 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:

◆ ResetData()

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:

◆ Run()

◆ UpdatePositions()

void NetAnimExperiment::UpdatePositions ( NodeContainer nodes)

Update positions function.

Parameters
nodesthe 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:

Member Data Documentation

◆ m_avgs

uint32_t NetAnimExperiment::m_avgs

averages

Definition at line 68 of file uan-animation.h.

Referenced by IncrementCw(), and Run().

◆ m_boundary

double NetAnimExperiment::m_boundary

boundary

Definition at line 62 of file uan-animation.h.

Referenced by Run(), and UpdatePositions().

◆ m_bytesTotal

uint32_t NetAnimExperiment::m_bytesTotal

bytes total

Definition at line 64 of file uan-animation.h.

Referenced by ReceivePacket(), ResetData(), and Run().

◆ m_cwMax

uint32_t NetAnimExperiment::m_cwMax

CW maximum.

Definition at line 66 of file uan-animation.h.

Referenced by Run().

◆ m_cwMin

uint32_t NetAnimExperiment::m_cwMin

CW minimum.

Definition at line 65 of file uan-animation.h.

Referenced by Run().

◆ m_cwStep

uint32_t NetAnimExperiment::m_cwStep

CW step.

Definition at line 67 of file uan-animation.h.

Referenced by IncrementCw(), and Run().

◆ m_dataRate

uint32_t NetAnimExperiment::m_dataRate

data rate

Definition at line 60 of file uan-animation.h.

Referenced by Run().

◆ m_depth

double NetAnimExperiment::m_depth

depth

Definition at line 61 of file uan-animation.h.

Referenced by Run().

◆ m_numNodes

uint32_t NetAnimExperiment::m_numNodes

number of nodes

Definition at line 59 of file uan-animation.h.

Referenced by Run().

◆ m_packetSize

uint32_t NetAnimExperiment::m_packetSize

packet size

Definition at line 63 of file uan-animation.h.

Referenced by Run().

◆ m_simTime

Time NetAnimExperiment::m_simTime

simulation time

Definition at line 71 of file uan-animation.h.

Referenced by ResetData(), and Run().

◆ m_slotTime

Time NetAnimExperiment::m_slotTime

slot time

Definition at line 70 of file uan-animation.h.

Referenced by Run().

◆ m_throughputs

std::vector<double> NetAnimExperiment::m_throughputs

throughputs

Definition at line 73 of file uan-animation.h.

Referenced by IncrementCw(), and ResetData().


The documentation for this class was generated from the following files: