From 9633b4aa3fb13d4b914813ef00a23c2047ac6176 Mon Sep 17 00:00:00 2001 From: Manuel Requena Date: Thu, 9 May 2013 02:07:43 +0200 Subject: [PATCH 1/2] Change default maxTxBufferSize to 10KBytes --- src/lte/model/lte-rlc-um.cc | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/lte/model/lte-rlc-um.cc b/src/lte/model/lte-rlc-um.cc index 7a43eed6f..97adde8de 100644 --- a/src/lte/model/lte-rlc-um.cc +++ b/src/lte/model/lte-rlc-um.cc @@ -33,7 +33,7 @@ namespace ns3 { NS_OBJECT_ENSURE_REGISTERED (LteRlcUm); LteRlcUm::LteRlcUm () - : m_maxTxBufferSize (2 * 1024 * 1024), + : m_maxTxBufferSize (10 * 1024), m_txBufferSize (0), m_sequenceNumber (0), m_vrUr (0), @@ -59,7 +59,7 @@ LteRlcUm::GetTypeId (void) .AddConstructor () .AddAttribute ("MaxTxBufferSize", "Maximum Size of the Transmission Buffer (in Bytes)", - UintegerValue (2 * 1024 * 1024), + UintegerValue (10 * 1024), MakeUintegerAccessor (&LteRlcUm::m_maxTxBufferSize), MakeUintegerChecker ()) ; From 0aef09f336bc32b1c9000b053116d6f9b919cc4d Mon Sep 17 00:00:00 2001 From: Manuel Requena Date: Thu, 9 May 2013 02:08:33 +0200 Subject: [PATCH 2/2] Change default MaxTxBufferSize in RLC-UM to 10KBytes --- src/lte/examples/lena-dual-stripe.cc | 25 +++++++++++-------------- 1 file changed, 11 insertions(+), 14 deletions(-) diff --git a/src/lte/examples/lena-dual-stripe.cc b/src/lte/examples/lena-dual-stripe.cc index 6f36306fe..0024bab23 100644 --- a/src/lte/examples/lena-dual-stripe.cc +++ b/src/lte/examples/lena-dual-stripe.cc @@ -344,9 +344,10 @@ main (int argc, char *argv[]) // change some default attributes so that they are reasonable for // this scenario, but do this before processing command line // arguments, so that the user is allowed to override these settings - Config::SetDefault ("ns3::UdpClient::Interval", TimeValue (MilliSeconds(1))); - Config::SetDefault ("ns3::UdpClient::MaxPackets", UintegerValue(1000000)); - + Config::SetDefault ("ns3::UdpClient::Interval", TimeValue (MilliSeconds (1))); + Config::SetDefault ("ns3::UdpClient::MaxPackets", UintegerValue (1000000)); + Config::SetDefault ("ns3::LteRlcUm::MaxTxBufferSize", UintegerValue (10 * 1024)); + CommandLine cmd; cmd.Parse (argc, argv); ConfigStore inputConfig; @@ -555,8 +556,8 @@ main (int argc, char *argv[]) NodeContainer ues; Ipv4StaticRoutingHelper ipv4RoutingHelper; Ipv4InterfaceContainer ueIpIfaces; - Ptr remoteHost; - NetDeviceContainer ueDevs; + Ptr remoteHost; + NetDeviceContainer ueDevs; if (epc) { NS_LOG_LOGIC ("setting up internet and remote host"); @@ -616,12 +617,11 @@ main (int argc, char *argv[]) lteHelper->Attach (*ueDevIt, *enbDevIt); } - if (epc) { NS_LOG_LOGIC ("setting up applications"); - + // Install and start applications on UEs and remote host uint16_t dlPort = 10000; uint16_t ulPort = 20000; @@ -633,7 +633,6 @@ main (int argc, char *argv[]) startTimeSeconds->SetAttribute ("Min", DoubleValue (0)); startTimeSeconds->SetAttribute ("Max", DoubleValue (0.010)); - for (uint32_t u = 0; u < ues.GetN (); ++u) { Ptr ue = ues.Get (u); @@ -650,7 +649,7 @@ main (int argc, char *argv[]) ApplicationContainer serverApps; if (useUdp) - { + { if (epcDl) { NS_LOG_LOGIC ("installing UDP DL app for UE " << u); @@ -661,15 +660,15 @@ main (int argc, char *argv[]) serverApps.Add (dlPacketSinkHelper.Install (ue)); } if (epcUl) - { + { NS_LOG_LOGIC ("installing UDP UL app for UE " << u); UdpClientHelper ulClientHelper (remoteHostAddr, ulPort); clientApps.Add (ulClientHelper.Install (ue)); PacketSinkHelper ulPacketSinkHelper ("ns3::UdpSocketFactory", InetSocketAddress (Ipv4Address::GetAny (), ulPort)); serverApps.Add (ulPacketSinkHelper.Install (remoteHost)); - } - } + } + } else // use TCP { if (epcDl) @@ -762,8 +761,6 @@ main (int argc, char *argv[]) remHelper->SetAttribute ("Z", DoubleValue (1.5)); remHelper->Install (); // simulation will stop right after the REM has been generated - - } else {