#include "ns3/vector.h"
#include "ns3/string.h"
#include "ns3/socket.h"
#include "ns3/double.h"
#include "ns3/config.h"
#include "ns3/log.h"
#include "ns3/command-line.h"
#include "ns3/mobility-model.h"
#include "ns3/yans-wifi-helper.h"
#include "ns3/position-allocator.h"
#include "ns3/mobility-helper.h"
#include "ns3/internet-stack-helper.h"
#include "ns3/ipv4-address-helper.h"
#include "ns3/ipv4-interface-container.h"
#include <iostream>
#include "ns3/ocb-wifi-mac.h"
#include "ns3/wifi-80211p-helper.h"
#include "ns3/wave-mac-helper.h"
Go to the source code of this file.
Functions | |
static void | GenerateTraffic (Ptr< Socket > socket, uint32_t pktSize, uint32_t pktCount, Time pktInterval) |
int | main (int argc, char *argv[]) |
NS_LOG_COMPONENT_DEFINE ("WifiSimpleOcb") | |
This example shows basic construction of an 802.11p node. More... | |
void | ReceivePacket (Ptr< Socket > socket) |
|
static |
Definition at line 81 of file wave-simple-80211p.cc.
References ns3::Socket::Close(), ns3::Simulator::Schedule(), and ns3::Socket::Send().
Referenced by main().
int main | ( | int | argc, |
char * | argv[] | ||
) |
Definition at line 96 of file wave-simple-80211p.cc.
References ns3::ListPositionAllocator::Add(), ns3::CommandLine::AddValue(), ns3::Ipv4AddressHelper::Assign(), ns3::Socket::Bind(), ns3::Socket::Connect(), ns3::YansWifiChannelHelper::Create(), ns3::NodeContainer::Create(), ns3::Socket::CreateSocket(), ns3::NqosWaveMacHelper::Default(), ns3::Wifi80211pHelper::Default(), ns3::YansWifiChannelHelper::Default(), ns3::YansWifiPhyHelper::Default(), ns3::Simulator::Destroy(), first::devices, ns3::YansWifiPhyHelper::DLT_IEEE802_11, ns3::Wifi80211pHelper::EnableLogComponents(), GenerateTraffic(), ns3::NodeContainer::Get(), ns3::Ipv4Address::GetAny(), ns3::Node::GetId(), ns3::Socket::GetNode(), ns3::Wifi80211pHelper::Install(), ns3::InternetStackHelper::Install(), ns3::MobilityHelper::Install(), ns3::TypeId::LookupByName(), ns3::MakeCallback(), NS_LOG_INFO, ns3::CommandLine::Parse(), ReceivePacket(), ns3::Simulator::Run(), ns3::Simulator::ScheduleWithContext(), ns3::Socket::SetAllowBroadcast(), ns3::Ipv4AddressHelper::SetBase(), ns3::YansWifiPhyHelper::SetChannel(), ns3::MobilityHelper::SetMobilityModel(), ns3::YansWifiPhyHelper::SetPcapDataLinkType(), ns3::MobilityHelper::SetPositionAllocator(), ns3::Socket::SetRecvCallback(), ns3::WifiHelper::SetRemoteStationManager(), and verbose.
NS_LOG_COMPONENT_DEFINE | ( | "WifiSimpleOcb" | ) |
This example shows basic construction of an 802.11p node.
Two nodes are constructed with 802.11p devices, and by default, one node sends a single packet to another node (the number of packets and interval between them can be configured by command-line arguments). The example shows typical usage of the helper classes for this mode of WiFi (where "OCB" refers to "Outside the Context of a BSS")."
Definition at line 76 of file wave-simple-80211p.cc.
References NS_LOG_UNCOND.
Referenced by main().