LEFT | RIGHT |
1 /* -*- Mode: C++; c-file-style: "gnu"; indent-tabs-mode:nil; -*- */ | 1 /* -*- Mode: C++; c-file-style: "gnu"; indent-tabs-mode:nil; -*- */ |
2 /* | 2 /* |
3 * Copyright (c) 2011 Centre Tecnologic de Telecomunicacions de Catalunya (CTTC) | 3 * Copyright (c) 2011 Centre Tecnologic de Telecomunicacions de Catalunya (CTTC) |
4 * | 4 * |
5 * This program is free software; you can redistribute it and/or modify | 5 * This program is free software; you can redistribute it and/or modify |
6 * it under the terms of the GNU General Public License version 2 as | 6 * it under the terms of the GNU General Public License version 2 as |
7 * published by the Free Software Foundation; | 7 * published by the Free Software Foundation; |
8 * | 8 * |
9 * This program is distributed in the hope that it will be useful, | 9 * This program is distributed in the hope that it will be useful, |
10 * but WITHOUT ANY WARRANTY; without even the implied warranty of | 10 * but WITHOUT ANY WARRANTY; without even the implied warranty of |
(...skipping 163 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
174 ·· | 174 ·· |
175 // setup default gateway for the remote hosts | 175 // setup default gateway for the remote hosts |
176 Ipv4StaticRoutingHelper ipv4RoutingHelper; | 176 Ipv4StaticRoutingHelper ipv4RoutingHelper; |
177 Ptr<Ipv4StaticRouting> remoteHostStaticRouting = ipv4RoutingHelper.GetStaticRo
uting (remoteHost->GetObject<Ipv4> ()); | 177 Ptr<Ipv4StaticRouting> remoteHostStaticRouting = ipv4RoutingHelper.GetStaticRo
uting (remoteHost->GetObject<Ipv4> ()); |
178 | 178 |
179 // hardcoded UE addresses for now | 179 // hardcoded UE addresses for now |
180 remoteHostStaticRouting->AddNetworkRouteTo (Ipv4Address ("7.0.0.0"), Ipv4Mask
("255.255.255.0"), 1); | 180 remoteHostStaticRouting->AddNetworkRouteTo (Ipv4Address ("7.0.0.0"), Ipv4Mask
("255.255.255.0"), 1); |
181 ·· | 181 ·· |
182 | 182 |
183 NodeContainer enbs; | 183 NodeContainer enbs; |
184 enbs.Create (m_enbTestData.size ()); | 184 enbs.Create (static_cast<uint32_t>(m_enbTestData.size ())); |
185 MobilityHelper enbMobility; | 185 MobilityHelper enbMobility; |
186 enbMobility.SetMobilityModel ("ns3::ConstantPositionMobilityModel"); | 186 enbMobility.SetMobilityModel ("ns3::ConstantPositionMobilityModel"); |
187 enbMobility.SetPositionAllocator ("ns3::GridPositionAllocator", | 187 enbMobility.SetPositionAllocator ("ns3::GridPositionAllocator", |
188 "MinX", DoubleValue (0.0), | 188 "MinX", DoubleValue (0.0), |
189 "MinY", DoubleValue (0.0), | 189 "MinY", DoubleValue (0.0), |
190 "DeltaX", DoubleValue (10000.0), | 190 "DeltaX", DoubleValue (10000.0), |
191 "DeltaY", DoubleValue (10000.0), | 191 "DeltaY", DoubleValue (10000.0), |
192 "GridWidth", UintegerValue (3), | 192 "GridWidth", UintegerValue (3), |
193 "LayoutType", StringValue ("RowFirst")); | 193 "LayoutType", StringValue ("RowFirst")); |
194 enbMobility.Install (enbs); | 194 enbMobility.Install (enbs); |
195 NetDeviceContainer enbLteDevs = lteHelper->InstallEnbDevice (enbs); | 195 NetDeviceContainer enbLteDevs = lteHelper->InstallEnbDevice (enbs); |
196 NetDeviceContainer::Iterator enbLteDevIt = enbLteDevs.Begin (); | 196 NetDeviceContainer::Iterator enbLteDevIt = enbLteDevs.Begin (); |
197 ·· | 197 ·· |
198 uint16_t ulPort = 1000; | 198 uint16_t ulPort = 1000; |
199 | 199 |
200 for (std::vector<EnbTestData>::iterator enbit = m_enbTestData.begin (); | 200 for (std::vector<EnbTestData>::iterator enbit = m_enbTestData.begin (); |
201 enbit < m_enbTestData.end (); | 201 enbit < m_enbTestData.end (); |
202 ++enbit, ++enbLteDevIt) | 202 ++enbit, ++enbLteDevIt) |
203 { | 203 { |
204 NS_ABORT_IF (enbLteDevIt == enbLteDevs.End ()); | 204 NS_ABORT_IF (enbLteDevIt == enbLteDevs.End ()); |
205 ······ | 205 ······ |
206 | 206 |
207 | 207 |
208 NodeContainer ues; | 208 NodeContainer ues; |
209 ues.Create (enbit->ues.size ()); | 209 ues.Create (static_cast<uint32_t>(enbit->ues.size ())); |
210 Vector enbPosition = (*enbLteDevIt)->GetNode ()->GetObject<MobilityModel>
()->GetPosition (); | 210 Vector enbPosition = (*enbLteDevIt)->GetNode ()->GetObject<MobilityModel>
()->GetPosition (); |
211 MobilityHelper ueMobility; | 211 MobilityHelper ueMobility; |
212 ueMobility.SetPositionAllocator ("ns3::UniformDiscPositionAllocator", | 212 ueMobility.SetPositionAllocator ("ns3::UniformDiscPositionAllocator", |
213 "X", DoubleValue (enbPosition.x), | 213 "X", DoubleValue (enbPosition.x), |
214 "Y", DoubleValue (enbPosition.y), | 214 "Y", DoubleValue (enbPosition.y), |
215 "rho", DoubleValue (100.0)); | 215 "rho", DoubleValue (100.0)); |
216 ueMobility.SetMobilityModel ("ns3::ConstantPositionMobilityModel"); | 216 ueMobility.SetMobilityModel ("ns3::ConstantPositionMobilityModel"); |
217 ueMobility.Install (ues); | 217 ueMobility.Install (ues); |
218 NetDeviceContainer ueLteDevs = lteHelper->InstallUeDevice (ues); | 218 NetDeviceContainer ueLteDevs = lteHelper->InstallUeDevice (ues); |
219 ······· | 219 ······· |
(...skipping 254 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
474 UeTestData u9; | 474 UeTestData u9; |
475 BearerTestData f9 (1000, 20, 0.0001); | 475 BearerTestData f9 (1000, 20, 0.0001); |
476 u9.bearers.push_back (f9); | 476 u9.bearers.push_back (f9); |
477 e9.ues.push_back (u9); | 477 e9.ues.push_back (u9); |
478 std::vector<EnbTestData> v9; | 478 std::vector<EnbTestData> v9; |
479 v9.push_back (e9); | 479 v9.push_back (e9); |
480 AddTestCase (new LteEpcE2eDataTestCase ("1 eNB, 1UE with aggregation", v9), Te
stCase::EXTENSIVE); | 480 AddTestCase (new LteEpcE2eDataTestCase ("1 eNB, 1UE with aggregation", v9), Te
stCase::EXTENSIVE); |
481 | 481 |
482 | 482 |
483 } | 483 } |
LEFT | RIGHT |