LEFT | RIGHT |
(no file at all) | |
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 153 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
164 // Packet bursts cellId | 164 // Packet bursts cellId |
165 uint16_t pbCellId[numOfPbs]; | 165 uint16_t pbCellId[numOfPbs]; |
166 | 166 |
167 /** | 167 /** |
168 * Build packet burst | 168 * Build packet burst |
169 */ | 169 */ |
170 for ( int pb = 0 ; pb < numOfPbs ; pb++ ) | 170 for ( int pb = 0 ; pb < numOfPbs ; pb++ ) |
171 { | 171 { |
172 // Create packet burst | 172 // Create packet burst |
173 packetBursts[pb] = CreateObject<PacketBurst> (); | 173 packetBursts[pb] = CreateObject<PacketBurst> (); |
174 pbCellId[pb] = cellId * (pb + 1); | 174 pbCellId[pb] = static_cast<uint16_t> (cellId * (pb + 1)); |
175 | 175 |
176 // Create packets and add them to the burst | 176 // Create packets and add them to the burst |
177 for ( int i = 0 ; i < numOfPkts ; i++ ) | 177 for ( int i = 0 ; i < numOfPkts ; i++ ) |
178 { | 178 { |
179 pkt[pb][i] = Create<Packet> (1000); | 179 pkt[pb][i] = Create<Packet> (1000); |
180 | 180 |
181 packetBursts[pb]->AddPacket ( pkt[pb][i] ); | 181 packetBursts[pb]->AddPacket ( pkt[pb][i] ); |
182 } | 182 } |
183 } | 183 } |
184 | 184 |
(...skipping 141 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
326 std::list<Ptr<LteControlMessage> > ctrlMsgList[numOfUes]; | 326 std::list<Ptr<LteControlMessage> > ctrlMsgList[numOfUes]; |
327 ·· | 327 ·· |
328 // signals cellId | 328 // signals cellId |
329 uint16_t pbCellId[numOfUes]; | 329 uint16_t pbCellId[numOfUes]; |
330 ·· | 330 ·· |
331 /** | 331 /** |
332 * Build ctrl msg lists | 332 * Build ctrl msg lists |
333 */ | 333 */ |
334 for ( int pb = 0 ; pb < numOfUes ; pb++ ) | 334 for ( int pb = 0 ; pb < numOfUes ; pb++ ) |
335 { | 335 { |
336 pbCellId[pb] = cellId * (pb + 1); | 336 pbCellId[pb] = static_cast<uint16_t> (cellId * (pb + 1)); |
337 ···· | 337 ···· |
338 // Create ctrl msg and add them to the list | 338 // Create ctrl msg and add them to the list |
339 for ( int i = 0 ; i < numOfCtrlMsgs ; i++ ) | 339 for ( int i = 0 ; i < numOfCtrlMsgs ; i++ ) |
340 { | 340 { |
341 Ptr<DlDciLteControlMessage> msg = Create<DlDciLteControlMessage> (); | 341 Ptr<DlDciLteControlMessage> msg = Create<DlDciLteControlMessage> (); |
342 DlDciListElement_s dci; | 342 DlDciListElement_s dci; |
343 msg->SetDci (dci); | 343 msg->SetDci (dci); |
344 ctrlMsgList[pb].push_back (msg); | 344 ctrlMsgList[pb].push_back (msg); |
345 } | 345 } |
346 } | 346 } |
(...skipping 84 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
431 Simulator::Stop (Seconds (5.0)); | 431 Simulator::Stop (Seconds (5.0)); |
432 Simulator::Run (); | 432 Simulator::Run (); |
433 ·· | 433 ·· |
434 NS_LOG_INFO ("Ctrl Frame - Theoretical SINR: " << *m_expectedSinr); | 434 NS_LOG_INFO ("Ctrl Frame - Theoretical SINR: " << *m_expectedSinr); |
435 NS_LOG_INFO ("Ctrl Frame - Calculated SINR: " << *(actualSinrCatcher.GetValue
())); | 435 NS_LOG_INFO ("Ctrl Frame - Calculated SINR: " << *(actualSinrCatcher.GetValue
())); |
436 ·· | 436 ·· |
437 NS_TEST_ASSERT_MSG_SPECTRUM_VALUE_EQ_TOL(*(actualSinrCatcher.GetValue ()), *m_
expectedSinr, 0.0000001, "Data Frame - Wrong SINR !"); | 437 NS_TEST_ASSERT_MSG_SPECTRUM_VALUE_EQ_TOL(*(actualSinrCatcher.GetValue ()), *m_
expectedSinr, 0.0000001, "Data Frame - Wrong SINR !"); |
438 dlPhy->Dispose (); | 438 dlPhy->Dispose (); |
439 Simulator::Destroy (); | 439 Simulator::Destroy (); |
440 } | 440 } |
LEFT | RIGHT |