Presentation is loading. Please wait.

Presentation is loading. Please wait.

Session 8. LTE in ns-3 박태준 Multimedia & Wireless Networking Laboratory, SNU tjpark@mwnl.snu.ac.kr.

Similar presentations


Presentation on theme: "Session 8. LTE in ns-3 박태준 Multimedia & Wireless Networking Laboratory, SNU tjpark@mwnl.snu.ac.kr."— Presentation transcript:

1 Session 8. LTE in ns-3 박태준 Multimedia & Wireless Networking Laboratory, SNU

2 Contents LTE Overview LTE in ns-3 Simulation Examples
Packet Transmission Example Configurable Parameters Multi-cell Environment Example

3 LTE Overview

4 3GPP LTE and LTE-A LTE (Long Term Evolution) LTE-A (LTE Advanced)
LTE is 3GPP system for the years 2010 to 2020 and beyond It must keep the support for high mobility users like in GSM/UMTS Bandwidth: 1.4 MHz ~ 20 MHz Peak Data Rate: 300 Mbps (4x4 MIMO, 20 MHz) Key feature: AMC (Adaptive Modulation Coding), MIMO (up to 4x4) LTE-A (LTE Advanced) LTE-A is often used for LTE release 10 and beyond Bandwidth: up to 100 MHz Peak Data Rate: 3 Gbps Key feature: CA (Carrier Aggregation), MIMO (up to 8x8), CoMP (Coordinated Multi Point Transmission), HetNet (Heterogeneous Network), Relay

5 LTE System Architecture
EPS Serving GW P-GW HSS MME eNodeB: evolved Node B MME: Mobility Management Entity P-GW: Packet Data Network Gateway HSS: Home Subscriber Server

6 Key Entity eNB (evolved Node B) MME (Mobility Management Entity)
It is the hardware that is connected to the mobile phone network Functions for radio resource management Scheduling and transmission MME (Mobility Management Entity) Tracking area list management Bearer management functions including dedicated bearer establishment S-GW (Serving Gateway) Packet routing and forwarding Mobility anchoring for inter-3GPP mobility P-GW (Packet Data Network Gateway) Per-user based packet filtering UE IP address allocation Mobility anchoring for non-3GPP mobility

7 Protocol Architecture

8 QoS and EPS Bearer EPS Bearer EPS Bearers
In order to support multiple QoS requirements, different bearers are setup within EPS Default EPS Bearer Establish when UE connects to PDN Provide always-on connectivity Non-GBR (Non Guaranteed Bit Rate) Dedicated EPS Bearer Establish in addition when it is needed Can be GBR or non-GBR EPS Bearer

9 LTE Resources RB (Resource Block)
12 sub-carriers allocated during a 0.5 ms timeslot are called a resource block A LTE terminal can be allocated a minimum of 2 RBs during 1 subframe (1 ms) Relationship between bandwidth and RB The number of RBs is determined according to bandwidth For example, 6 RBs in 1.4 MHz and 100 RBs in 20 MHz

10 Resource Allocation MAC scheduler allocates RBs to UEs
Reference: Rohde & Schwarz, UMTS Long Term Evolution (LTE) Technology Introduction

11 Important Channel in LTE
PDCCH (Physical Downlink Control Channel) Transmit scheduling assignment PDSCH (Physical Downlink Shared Channel) Main data bearing channel which is allocated to users 15 kHz frequency

12 LTE in ns-3

13 LTE-EPC Simulation Model
LTE model Supporting the evaluation of the following aspects of LTE systems Radio Resource Management QoS-aware Packet Scheduling Inter-cell Interference Coordination Dynamic Spectrum Access EPC model Supporting the interconnection of multiple UEs to the Internet Packet Data Network (PDN) type: IPv4 SGW/PGW node: functional entities are implemented within a single node Reference: ns-3 Model Library Release ns-3.22

14 LTE Protocol Stack PHY model MAC/Scheduler model
Frequency Division Duplexing (FDD) Granularity Frequency domain: 1 Resource Block (RB) Time domain: 1 Transmission Time Interval (TTI) Supports different frequencies and bandwidths per eNBs MAC/Scheduler model Downlink Allocation type 0 (min. scheduling unit = RBG) Round Robin (RR), Proportional Fair (PF), … Uplink Only RR supported

15 LTE Protocol Stack RLC model PDCP model Segmentation Reassembly
Maintenance of PDCP SNs Transfer of SN (Sequence Number) status for handover Unsupported features Header compression/decompression Ciphering/Deciphering

16 Simulation Examples

17 Simulation Code Flow LteHelper EpcHelper Install eNB and UE
Attach UE to eNB EpcHelper Attach eNB to EPC Activate default bearer Get P-GW node in order for LTE network to connect external network Single node in ns-3

18 LteHelper Install LTE eNB/UE protocol stack to a set of node
NetDeviceContainer InstallEnbDevice (NodeContainer c) NetDeviceContainer InstallUeDevice (NodeContainer c) Attach UE(s) to eNB(s) Automatic attachment of UE(s) void Attach (Ptr<NetDevice> ueDevice) void Attach (NetDeviceContainer ueDevices) Manual attachment of UE(s) void Attach (NetDeviceContainer ueDevices, Ptr<NetDevice> enbDevice) void Attach (Ptr<NetDevice> ueDevice, Ptr<NetDevice> enbDevice)

19 LteHelper Set scheduler type Set DL/UL bandwidth
void LteHelper::SetSchedulerType(std::string type) Type Round Robin: RrFfMacScheduler Proportional Fair: PfFfMacScheduler Set DL/UL bandwidth DL bandwidth: Void LteHelper::SetEnbDeviceAttribute(“DlBandwidth”, UintegerValue()) UL bandwidth Void LteHelper::SetEnbDeviceAttribute(“UlBandwidth”, UintegerValue())

20 EpcHelper Attach eNB to EPC Activate default bearer Get P-GW node
Automatically attachment of eNB(s) to an EPC Related functions of LteHelper void LteHelper::SetEpcHelper (Ptr<EpcHelper> h) NetDeviceContainer LteHelper::InstallEnbDevice (NodeContainer c) Activate default bearer Automatically activate default bearer for each UE Related function of LteHelper void LteHelper::Attach( … ) Get P-GW node Ptr<Node> GetPgwNode ()

21 Packet Transmission Example
Simulation environment Remote host generates UDP packet Packet size: 1460 bytes Downlink bandwidth: 20 MHz (100 RBs) PGW/SGW 10 m UE UDP client eNB Packet sink Internet Remote host

22 Simulation Code(1/9) test-lte-epc.cc Define variables
NS_LOG_COMPONENT_DEFINE ("TestLteEpc"); using namespace ns3; int main (int argc, char *argv[]) { double ltePktInv = ; // full pumping LTE packet double lteStartTimeSec = 1; // application start time double lteStopTimeSec = 2; // application end time double downlinkRb = 100; // the number of resource blocks used for downlink

23 Simulation Code(2/9) Create nodes UE node eNB node Remote host node
Ipv4GlobalRoutingHelper::PopulateRoutingTables (); NodeContainer remoteHostNode, enbNode, ueNode; remoteHostNode.Create (1); enbNode.Create (1); ueNode.Create (1); Create nodes UE node eNB node Remote host node

24 Simulation Code(3/9) eNB node UE node Remote host node
Allocate position Ptr<ListPositionAllocator> positionAlloc = CreateObject<ListPositionAllocator> (); positionAlloc->Add (Vector(0, 0, 0)); // for LTE eNB positionAlloc->Add (Vector(10, 0, 0)); // for LTE UE MobilityHelper mobility; mobility.SetPositionAllocator (positionAlloc); mobility.SetMobilityModel ("ns3::ConstantPositionMobilityModel"); mobility.Install (enbNode); mobility.Install (ueNode); 10 m eNB node (0, 0, 0) UE node (10, 0, 0) Remote host node

25 Simulation Code(4/9) eNB node UE node Remote host node PGW/SGW
LTE and EPC configuration Using LteHelper and EpcHelper //LteHelper Ptr<LteHelper> lteHelper = CreateObject<LteHelper> (); lteHelper->SetAttribute ("PathlossModel", StringValue ("ns3::LogDistancePropagationLossModel")); lteHelper->SetEnbDeviceAttribute ("DlBandwidth", UintegerValue (downlinkRb)); lteHelper->SetEnbDeviceAttribute ("UlBandwidth", UintegerValue (downlinkRb)); //EpcHelper Ptr<PointToPointEpcHelper> epcHelper = CreateObject<PointToPointEpcHelper> (); lteHelper->SetEpcHelper (epcHelper); Ptr<Node> pgw = epcHelper->GetPgwNode (); //Wired configuration (Remote host and PGW/SGW) PointToPointHelper pointToPoint; pointToPoint.SetDeviceAttribute ("DataRate", StringValue ("1Gbps")); pointToPoint.SetDeviceAttribute ("Mtu", UintegerValue (1500)); pointToPoint.SetChannelAttribute ("Delay", StringValue (" ms")); eNB node (0, 0, 0) UE node (10, 0, 0) Remote host node 10 m PGW/SGW

26 Simulation Code(5/9) Assign IP address to EPC //Temporal containers
NetDeviceContainer p2pDevs, enbDev, ueDevs; //Remote host– PGW/SGW p2pDevs = pointToPoint.Install (remoteHostNode.Get(0), pgw); enbDev = lteHelper->InstallEnbDevice (enbNode); ueDevs = lteHelper->InstallUeDevice (ueNode); // IP address assignment for remote host and PGW/SGW InternetStackHelper internet; internet.Install (remoteHostNode); Ipv4AddressHelper ipv4; ipv4.SetBase (" ", " "); Ipv4InterfaceContainer internetIpIfaces = ipv4.Assign (p2pDevs); //Routing setting from EPC to LTE Ipv4StaticRoutingHelper ipv4RoutingHelper; Ptr<Ipv4StaticRouting> remoteHostStaticRouting = ipv4RoutingHelper.GetStaticRouting ((remoteHostNode.Get(0))->GetObject<Ipv4> ()); remoteHostStaticRouting->AddNetworkRouteTo (Ipv4Address (" "), Ipv4Mask (" "), 1);

27 Simulation Code(6/9) PGW/SGW eNB UE Remote host
Assign IP address to LTE //IP address assignment for UE internet.Install (ueNode); Ipv4InterfaceContainer ueIfs = epcHelper->AssignUeIpv4Address (NetDeviceContainer (ueDevs)); Ptr<Ipv4StaticRouting> ueStaticRouting = ipv4RoutingHelper.GetStaticRouting (ueNode.Get(0)->GetObject<Ipv4> ()); ueStaticRouting->SetDefaultRoute (epcHelper->GetUeDefaultGatewayAddress (), 1); // Automatic attachment of a UE device to a suitable cell lteHelper->Attach (ueDevs.Get (0)); 10 m UE eNB PGW/SGW Internet Remote host ( ) ( ) ( ) ( )

28 Simulation Code(7/9) Application
uint16_t dlPort = 10000; //Setting the downlink UDP port ApplicationContainer clientApps; //Making an application container ApplicationContainer serverApps; //Set the destination IP address, port etc. UdpClientHelper dlClientHelper (ueIfs.GetAddress (0), dlPort); dlClientHelper.SetAttribute ("MaxPackets", UintegerValue ( )); dlClientHelper.SetAttribute ("Interval", TimeValue (Seconds (ltePktInv))); dlClientHelper.SetAttribute ("PacketSize", UintegerValue (1460)); //Install the UDP client application to remote server clientApps.Add (dlClientHelper.Install (remoteHostNode.Get(0))); //Install the packet sink to UE PacketSinkHelper dlPacketSinkHelper ("ns3::UdpSocketFactory", InetSocketAddress (Ipv4Address::GetAny (), dlPort)); serverApps.Add (dlPacketSinkHelper.Install (ueNode.Get(0)));

29 Simulation Code(8/9) PGW/SGW eNB UE Remote host
Activate dedicated bearer //Setting the Traffic Flow Template (TFT) Ptr<EpcTft> tft = Create<EpcTft> (); EpcTft::PacketFilter dlpf; dlpf.localPortStart = dlPort; dlpf.localPortEnd = dlPort; tft->Add (dlpf); //Setting the bearer EpsBearer bearer (EpsBearer::NGBR_VIDEO_TCP_DEFAULT); lteHelper->ActivateDedicatedEpsBearer (ueDevs.Get (0), bearer, tft); UE eNB PGW/SGW Internet Remote host ( ) ( ) ( ) ( ) Packet sink UDP client

30 Simulation Code(9/9) Simulation running and Calculate the throughput
//Setting the simulation time serverApps.Start (Seconds (lteStartTimeSec)); clientApps.Start (Seconds (lteStartTimeSec)); Simulator::Stop (Seconds(lteStopTimeSec)); Simulator::Run (); //Tracing Ptr<PacketSink> sink = serverApps.Get (0)->GetObject<PacketSink> (); double lteThroughput = sink->GetTotalRx () * 8.0 / ( *(stopTimeSec - lteStartTimeSec)); NS_LOG_UNCOND (“UE(" << ueIfs.GetAddress(0) <<“) lte throughput: " << lteThroughput); Simulator::Destroy (); return 0;

31 Packet Transmission Examples
Simulation Results ./waf --run scratch/test-lte-epc UE eNB PGW/SGW Internet Remote host 69.87 Mbps

32 Configurable Parameters
Simulation environment Which factor affect throughput performance? Example eNB UE 10 m 100 m 100 RBs 50 RBs 1 ms inter-packet interval 2 ms inter-packet interval 10 MHz bandwidth 20 MHz bandwidth Transmission power Center frequency

33 Configurable Parameters
eNB transmission power configuration test-lte-epc-config-skeleton.cc double ltePktInv = ; double downlinkRb = 100; double dlEarfcn = 100; double lteTxPower = 30; double distance = 10; CommandLine cmd; cmd.AddValue ("dlEarfcn", "downlink frequency",dlEarfcn); cmd.AddValue ("lteTxPower", "lte eNB transmission power [dBm]",lteTxPower); cmd.Parse (argc, argv); Ptr<LteHelper> lteHelper = CreateObject<LteHelper> (); lteHelper->SetEnbDeviceAttribute ("DlEarfcn", UintegerValue (dlEarfcn)); lteHelper->SetEnbDeviceAttribute ("UlEarfcn", UintegerValue (dlEarfcn+18000)); Config::SetDefault("ns3::LteEnbPhy::TxPower", DoubleValue (lteTxPower));

34 Configurable Parameters
In class assignment test-lte-epc-config-skeleton.cc double ltePktInv = ; double downlinkRb = 100; double dlEarfcn = 100; double lteTxPower = 30; double distance = 10; CommandLine cmd; // To Do List // Insert command line to get the number of resource blocks used for downlink // Insert command line to get the distance between eNB and UE // Insert command line to get the LTE packet interval cmd.AddValue ("dlEarfcn", "downlink frequency",dlEarfcn); cmd.AddValue ("lteTxPower", "lte eNB transmission power [dBm]",lteTxPower); cmd.Parse (argc, argv);

35 Configurable Parameters
test-lte-epc-config.cc Bandwidth configuration double ltePktInv = ; double downlinkRb = 100; double dlEarfcn = 100; double ulEarfcn = 18100; double lteTxPower = 30; double distance = 10; CommandLine cmd; cmd.AddValue ("downlinkRb", "number of resource blocks in downlink",downlinkRb); cmd.AddValue ("distance", “distance between eNB and UE [m]",distance); cmd.AddValue ("ltePktInv", “packet generation interval of UDP [s]",ltePktInv); cmd.AddValue ("dlEarfcn", "downlink frequency",dlEarfcn); cmd.AddValue ("lteTxPower", "lte eNB transmission power [dBm]",lteTxPower); cmd.Parse (argc, argv);

36 Configurable Parameters
Distance between eNB and UE configuration LTE packet interval configuration

37 Multi-cell Environment Example
Simulation environment eNB 1 eNB 2 UE 1 UE 2 UE 6 UE 5 interference UE 3 UE 4 10 m 10 m 200 m 99 m 99 m 100 m 100 m

38 Multi-cell Environment Example
Simulation code (scratch/test-multicell-skeleton.cc) Make topology Attaching eNB 1 to UE 1, 3, 5 and eNB 2 to UE 2, 4, 6 Ptr<ListPositionAllocator> positionAlloc = CreateObject<ListPositionAllocator> (); positionAlloc->Add (Vector(-100.0, 0.0, 0.0)); //for enb 1 positionAlloc->Add (Vector(100.0, 0.0, 0.0)); //for enb 2 positionAlloc->Add (Vector(-100.0, 10.0, 0.0)); //for ue 1 positionAlloc->Add (Vector(100.0, 10.0, 0.0)); //for ue 2 positionAlloc->Add (Vector(-100.0, , 0.0)); //for ue 3 positionAlloc->Add (Vector(100.0, , 0.0)); //for ue 4 positionAlloc->Add (Vector(-1.0, 0.0, 0.0)); //for ue 5 positionAlloc->Add (Vector(1.0, 0.0, 0.0)); //for ue 6 MobilityHelper mobility; mobility.SetMobilityModel("ns3::ConstantPositionMobilityModel"); mobility.SetPositionAllocator(positionAlloc); mobility.Install(enbNodes); mobility.Install(ueNodes); for (uint16_t i = 0; i < numberOfNodes; i++) { lteHelper->Attach (ueLteDevs.Get(i), enbLteDevs.Get(i)); lteHelper->Attach (ueLteDevs.Get(i+2), enbLteDevs.Get(i)); lteHelper->Attach (ueLteDevs.Get(i+4), enbLteDevs.Get(i)); }

39 Multi-cell Environment Example
Simulation code (scratch/test-multicell-skeleton.cc) Install and start applications on UEs Throughput calculation uint16_t dlPort = 1234; ApplicationContainer clientApps; ApplicationContainer serverApps; for (uint32_t u = 0; u < ueNodes.GetN (); ++u) { PacketSinkHelper dlPacketSinkHelper ("ns3::UdpSocketFactory", InetSocketAddress (Ipv4Address::GetAny (), dlPort + u)); serverApps.Add (dlPacketSinkHelper.Install (ueNodes.Get(u))); UdpClientHelper dlClientHelper (ueIpIface.GetAddress (u), dlPort + u); dlClientHelper.SetAttribute ("Interval", TimeValue (MilliSeconds(interPacketInterval))); dlClientHelper.SetAttribute ("MaxPackets", UintegerValue( )); clientApps.Add (dlClientHelper.Install (remoteHostNode.Get(0))); } Ptr<PacketSink> sink = serverApps.Get (0) -> GetObject<PacketSink> (); NS_LOG_UNCOND("LTE throughput :" << sink->GetTotalRx()*8.0 / << " Mbps");

40 Multi-cell Environment Example
Simulation results ./waf --run scratch/test-multicell eNB 1 eNB 2 UE 1 UE 2 UE 6 UE 5 interference UE 3 UE 4 10 m 100 m 99 m 200 m 6.2 Mbps 1.7 Mbps 0.8 Mbps

41 References 3GPP TS 36.300 3GPP TS 36.104
The LTE Network Architecture, Alcatel Lucent LTE/EPS overview, NSN ns-3 Model Library Release ns-3.22 E. Dahlman, S. Parkvall, and J. Skold, 4G: LTE/LTE-Advanced for Mobile Broadband, Academic Press, 2011 Rohde & Schwarz, UMTS Long Term Evolution (LTE) Technology Introduction

42 Thank You !


Download ppt "Session 8. LTE in ns-3 박태준 Multimedia & Wireless Networking Laboratory, SNU tjpark@mwnl.snu.ac.kr."

Similar presentations


Ads by Google