A Discrete-Event Network Simulator
API
Loading...
Searching...
No Matches
uan-animation.h
Go to the documentation of this file.
1/*
2 * Copyright (c) 2010 Andrea Sacco
3 *
4 * SPDX-License-Identifier: GPL-2.0-only
5 *
6 * Author: Andrea Sacco <andrea.sacco85@gmail.com>
7 */
8
9#ifndef UAN_CW_EXAMPLE_H
10#define UAN_CW_EXAMPLE_H
11
12#include "ns3/network-module.h"
13#include "ns3/uan-module.h"
14
15using namespace ns3;
16
17/**
18 * \class NetAnimExperiment
19 * \brief Helper class for UAN CW MAC example
20 *
21 */
23{
24 public:
25 /**
26 * Run function
27 * \param uan the UAN helper
28 */
29 void Run(UanHelper& uan);
30 /**
31 * Receive packet function
32 * \param socket the socket to receive from
33 */
34 void ReceivePacket(Ptr<Socket> socket);
35 /**
36 * Update positions function
37 * \param nodes the collection of nodes
38 */
40 /// Reset data function
41 void ResetData();
42 /**
43 * Increment CW function
44 * \param cw the CW
45 */
46 void IncrementCw(uint32_t cw);
47 uint32_t m_numNodes; ///< number of nodes
48 uint32_t m_dataRate; ///< data rate
49 double m_depth; ///< depth
50 double m_boundary; ///< boundary
51 uint32_t m_packetSize; ///< packet size
52 uint32_t m_bytesTotal; ///< bytes total
53 uint32_t m_cwMin; ///< CW minimum
54 uint32_t m_cwMax; ///< CW maximum
55 uint32_t m_cwStep; ///< CW step
56 uint32_t m_avgs; ///< averages
57
58 Time m_slotTime; ///< slot time
59 Time m_simTime; ///< simulation time
60
61 std::vector<double> m_throughputs; ///< throughputs
62
63 /// the experiment
65};
66
67#endif /* UAN_CW_EXAMPLE_H */
Helper class for UAN CW MAC example.
void IncrementCw(uint32_t cw)
Increment CW function.
double m_boundary
boundary
std::vector< double > m_throughputs
throughputs
uint32_t m_cwMin
CW minimum.
uint32_t m_cwMax
CW maximum.
void Run(UanHelper &uan)
Run function.
Time m_simTime
simulation time
double m_depth
depth
uint32_t m_dataRate
data rate
uint32_t m_numNodes
number of nodes
Time m_slotTime
slot time
uint32_t m_packetSize
packet size
void ReceivePacket(Ptr< Socket > socket)
Receive packet function.
void ResetData()
Reset data function.
NetAnimExperiment()
the experiment
uint32_t m_avgs
averages
void UpdatePositions(NodeContainer &nodes) const
Update positions function.
uint32_t m_bytesTotal
bytes total
uint32_t m_cwStep
CW step.
keep track of a set of node pointers.
Smart pointer class similar to boost::intrusive_ptr.
Simulation virtual time values and global simulation resolution.
Definition nstime.h:94
UAN configuration helper.
Definition uan-helper.h:31
NodeContainer nodes
Every class exported by the ns3 library is enclosed in the ns3 namespace.