22 #include <ns3/simulator.h>
24 #include <ns3/callback.h>
25 #include <ns3/config.h>
26 #include <ns3/string.h>
27 #include <ns3/double.h>
29 #include <ns3/boolean.h>
30 #include <ns3/pointer.h>
31 #include "ns3/ff-mac-scheduler.h"
32 #include "ns3/mobility-helper.h"
33 #include "ns3/lte-helper.h"
43 uint32_t frameNo, uint32_t subframeNo, uint16_t rnti,
44 uint8_t mcsTb1, uint16_t sizeTb1, uint8_t mcsTb2, uint16_t sizeTb2)
46 testcase->
DlScheduling (frameNo, subframeNo, rnti, mcsTb1, sizeTb1, mcsTb2, sizeTb2);
51 uint32_t frameNo, uint32_t subframeNo, uint16_t rnti,
52 uint8_t mcs, uint16_t sizeTb)
54 testcase->
UlScheduling (frameNo, subframeNo, rnti, mcs, sizeTb);
63 :
TestSuite (
"lte-cqi-generation", SYSTEM)
78 uint16_t dlMcs, uint16_t ulMcs)
79 :
TestCase (
"Downlink Power Control: " + name),
93 uint8_t mcsTb1, uint16_t sizeTb1, uint8_t mcsTb2, uint16_t sizeTb2)
105 uint8_t mcs, uint16_t sizeTb)
149 positionAlloc->
Add (
Vector (0.0, 0.0, 0.0));
150 positionAlloc->
Add (
Vector (1000, 0.0, 0.0));
151 positionAlloc->
Add (
Vector (500.0, 0.0, 0.0));
152 positionAlloc->
Add (
Vector (500, 0.0, 0.0));
183 lteHelper->
Attach (ueDevs1, enbDevs.
Get (0));
184 lteHelper->
Attach (ueDevs2, enbDevs.
Get (1));
204 Simulator::Stop (
Seconds (1.100));
207 Simulator::Destroy ();
NetDeviceContainer InstallEnbDevice(NodeContainer c)
create a set of eNB devices
void DlScheduling(uint32_t frameNo, uint32_t subframeNo, uint16_t rnti, uint8_t mcsTb1, uint16_t sizeTb1, uint8_t mcsTb2, uint16_t sizeTb2)
void Reset(void)
Reset the initial value of every attribute as well as the value of every global to what they were bef...
Ptr< NetDevice > Get(uint32_t i) const
Get the Ptr stored in this container at a given index.
Callback< R > MakeBoundCallback(R(*fnPtr)(TX), ARG a1)
Make Callbacks with one bound argument.
void Attach(NetDeviceContainer ueDevices)
Enables automatic attachment of a set of UE devices to a suitable cell using Idle mode initial cell s...
#define NS_LOG_COMPONENT_DEFINE(name)
Define a Log component with a specific name.
Time MilliSeconds(uint64_t value)
Construct a Time in the indicated unit.
LteCqiGenerationTestSuite()
TestSuite.
virtual void DoRun(void)
Implementation to actually run this TestCase.
#define NS_LOG_INFO(msg)
Use NS_LOG to output a message of level LOG_INFO.
LteCqiGenerationTestCase(std::string name, bool usePdcchForCqiGeneration, uint16_t dlMcs, uint16_t ulMcs)
void Connect(std::string path, const CallbackBase &cb)
void ActivateDataRadioBearer(NetDeviceContainer ueDevices, EpsBearer bearer)
Call ActivateDataRadioBearer (ueDevice, bearer) for each UE device in a given set.
void SetFfrAlgorithmType(std::string type)
void SetSchedulerType(std::string type)
This class contains the specification of EPS Bearers.
void Install(Ptr< Node > node) const
"Layout" a single node according to the current position allocator type.
hold variables of type 'enum'
void Add(NetDeviceContainer other)
Append the contents of another NetDeviceContainer to the end of this container.
Hold an unsigned integer type.
void SetSchedulerAttribute(std::string n, const AttributeValue &v)
set an attribute for the scheduler to be created
#define NS_TEST_ASSERT_MSG_EQ(actual, limit, msg)
Test that an actual and expected (limit) value are equal and report and abort if not.
holds a vector of ns3::NetDevice pointers
void UlScheduling(uint32_t frameNo, uint32_t subframeNo, uint16_t rnti, uint8_t mcs, uint16_t sizeTb)
static LteCqiGenerationTestSuite lteCqiGenerationTestSuite
void SetDefault(std::string name, const AttributeValue &value)
keep track of a set of node pointers.
bool m_usePdcchForCqiGeneration
void SetMobilityModel(std::string type, std::string n1="", const AttributeValue &v1=EmptyAttributeValue(), std::string n2="", const AttributeValue &v2=EmptyAttributeValue(), std::string n3="", const AttributeValue &v3=EmptyAttributeValue(), std::string n4="", const AttributeValue &v4=EmptyAttributeValue(), std::string n5="", const AttributeValue &v5=EmptyAttributeValue(), std::string n6="", const AttributeValue &v6=EmptyAttributeValue(), std::string n7="", const AttributeValue &v7=EmptyAttributeValue(), std::string n8="", const AttributeValue &v8=EmptyAttributeValue(), std::string n9="", const AttributeValue &v9=EmptyAttributeValue())
void AddTestCase(TestCase *testCase) NS_DEPRECATED
Add an individual child TestCase case to this TestCase.
NetDeviceContainer InstallUeDevice(NodeContainer c)
create a set of UE devices
Helper class used to assign positions and mobility models to nodes.
Time Now(void)
create an ns3::Time instance which contains the current simulation time.
#define NS_LOG_DEBUG(msg)
Use NS_LOG to output a message of level LOG_DEBUG.
Time Seconds(double value)
Construct a Time in the indicated unit.
void LteTestDlSchedulingCallback(LteCqiGenerationTestCase *testcase, std::string path, uint32_t frameNo, uint32_t subframeNo, uint16_t rnti, uint8_t mcsTb1, uint16_t sizeTb1, uint8_t mcsTb2, uint16_t sizeTb2)
void Create(uint32_t n)
Create n nodes and append pointers to them to the end of this NodeContainer.
void SetPositionAllocator(Ptr< PositionAllocator > allocator)
Set the position allocator which will be used to allocate the initial position of every node initiali...
virtual ~LteCqiGenerationTestCase()
void SetFfrAlgorithmAttribute(std::string n, const AttributeValue &v)
set an attribute for the FFR algorithm to be created
void LteTestUlSchedulingCallback(LteCqiGenerationTestCase *testcase, std::string path, uint32_t frameNo, uint32_t subframeNo, uint16_t rnti, uint8_t mcs, uint16_t sizeTb)