#include "ns3/boolean.h"#include "ns3/command-line.h"#include "ns3/config.h"#include "ns3/data-rate.h"#include "ns3/double.h"#include "ns3/enum.h"#include "ns3/error-model.h"#include "ns3/inet-socket-address.h"#include "ns3/internet-stack-helper.h"#include "ns3/ipv4-address-helper.h"#include "ns3/ipv4-l3-protocol.h"#include "ns3/ipv4-list-routing-helper.h"#include "ns3/ipv4-static-routing-helper.h"#include "ns3/ipv4-static-routing.h"#include "ns3/log.h"#include "ns3/mobility-helper.h"#include "ns3/mobility-model.h"#include "ns3/names.h"#include "ns3/node.h"#include "ns3/on-off-helper.h"#include "ns3/packet-sink-helper.h"#include "ns3/packet-sink.h"#include "ns3/simulator.h"#include "ns3/socket.h"#include "ns3/ssid.h"#include "ns3/string.h"#include "ns3/test.h"#include "ns3/trace-helper.h"#include "ns3/udp-socket-factory.h"#include "ns3/udp-socket.h"#include "ns3/uinteger.h"#include "ns3/wifi-mac.h"#include "ns3/wifi-net-device.h"#include "ns3/wifi-psdu.h"#include "ns3/yans-wifi-channel.h"#include "ns3/yans-wifi-helper.h"#include <limits>#include <sstream>#include <string>
Include dependency graph for wifi-multicast.cc:Go to the source code of this file.
Functions | |
| uint32_t | ContextToNodeId (const std::string &context) |
| Parse context strings of the form "/NodeList/x/DeviceList/x/..." to extract the NodeId integer. | |
| void | RxCallback (std::string context, Ptr< const Packet > p, double snr, WifiMode mode, WifiPreamble preamble) |
| Callback when a frame is successfully received. | |
| void | SocketRxPacket (std::string context, Ptr< const Packet > p, const Address &from) |
| void | SocketTxPacket (std::string context, Ptr< const Packet > p) |
| Socket sent packet. | |
| void | TxCallback (Ptr< ListErrorModel > rxErrorModel, Ptr< RandomVariableStream > ranVar, double errorRate, std::string context, WifiConstPsduMap psduMap, WifiTxVector txVector, double txPowerW) |
| Callback when a frame is transmitted. | |
Variables | |
| Time | g_firstTx |
| Time at which first TX packet is generated. | |
| Time | g_lastRx |
| Time at which last RX packet is received. | |
| Time | g_lastTx |
| Time at which last TX packet is generated. | |
| uint64_t | g_txBytes |
| Number of generated bytes. | |
$ ./ns3 run "wifi-multicast [Program Options]"
--logging --verbose --pcap --nStations --simulationTime --payloadSize --maxPackets --dataRate --rtsThreshold --rateManager --mcs --targetAddress --accessCategory --gcrRetransmissionPolicy --nRetriesGcrUr --gcrProtection --multicastFrameErrorRate --maxAmpduLength --minExpectedPackets --maxExpectedPackets --minExpectedThroughput --maxExpectedThroughput Definition in file wifi-multicast.cc.
| uint32_t ContextToNodeId | ( | const std::string & | context | ) |
Parse context strings of the form "/NodeList/x/DeviceList/x/..." to extract the NodeId integer.
| context | The context to parse. |
Definition at line 113 of file wifi-multicast.cc.
Referenced by RxCallback().
Here is the caller graph for this function:| void RxCallback | ( | std::string | context, |
| Ptr< const Packet > | p, | ||
| double | snr, | ||
| WifiMode | mode, | ||
| WifiPreamble | preamble ) |
Callback when a frame is successfully received.
| context | the context |
| p | the packet |
| snr | the SNR (in linear scale) |
| mode | the mode used to transmit the packet |
| preamble | the preamble |
Definition at line 196 of file wifi-multicast.cc.
References ContextToNodeId(), ns3::WifiMacHeader::GetAddr1(), ns3::Mac48Address::IsBroadcast(), ns3::Mac48Address::IsGroup(), ns3::WifiMacHeader::IsQosData(), NS_LOG_INFO, and ns3::WifiMacHeader::Print().
Here is the call graph for this function:| context | The context. |
| p | The packet. |
| from | sender address. |
Definition at line 144 of file wifi-multicast.cc.
References g_lastRx, and ns3::Simulator::Now().
Here is the call graph for this function:Socket sent packet.
| context | The context. |
| p | The packet. |
Definition at line 127 of file wifi-multicast.cc.
References g_firstTx, g_lastTx, g_txBytes, and ns3::Simulator::Now().
Here is the call graph for this function:| void TxCallback | ( | Ptr< ListErrorModel > | rxErrorModel, |
| Ptr< RandomVariableStream > | ranVar, | ||
| double | errorRate, | ||
| std::string | context, | ||
| WifiConstPsduMap | psduMap, | ||
| WifiTxVector | txVector, | ||
| double | txPowerW ) |
Callback when a frame is transmitted.
| rxErrorModel | the post reception error model on the receiver |
| ranVar | the random variable to determine whether the packet shall be corrupted |
| errorRate | the configured corruption error rate for multicast frames |
| context | the context |
| psduMap | the PSDU map |
| txVector | the TX vector |
| txPowerW | the tx power in Watts |
Definition at line 160 of file wifi-multicast.cc.
References NS_LOG_INFO.
| Time g_firstTx |
Time at which first TX packet is generated.
Definition at line 102 of file wifi-multicast.cc.
Referenced by SocketTxPacket().
| Time g_lastRx |
Time at which last RX packet is received.
Definition at line 104 of file wifi-multicast.cc.
Referenced by SocketRxPacket().
| Time g_lastTx |
Time at which last TX packet is generated.
Definition at line 103 of file wifi-multicast.cc.
Referenced by SocketTxPacket().
| uint64_t g_txBytes |
Number of generated bytes.
Definition at line 101 of file wifi-multicast.cc.
Referenced by SocketTxPacket().