A Discrete-Event Network Simulator
API
Loading...
Searching...
No Matches
lte-test-ue-measurements.h
Go to the documentation of this file.
1/*
2 * Copyright (c) 2011 Centre Tecnologic de Telecomunicacions de Catalunya (CTTC)
3 *
4 * This program is free software; you can redistribute it and/or modify
5 * it under the terms of the GNU General Public License version 2 as
6 * published by the Free Software Foundation;
7 *
8 * This program is distributed in the hope that it will be useful,
9 * but WITHOUT ANY WARRANTY; without even the implied warranty of
10 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
11 * GNU General Public License for more details.
12 *
13 * You should have received a copy of the GNU General Public License
14 * along with this program; if not, write to the Free Software
15 * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
16 *
17 * Author: Manuel Requena <manuel.requena@cttc.es>
18 * Nicola Baldo <nbaldo@cttc.es>
19 * Marco Miozzo <mmiozzo@cttc.es>
20 * adapt lte-test-interference.cc to lte-ue-measurements.cc
21 * Budiarto Herman <budiarto.herman@magister.fi>
22 */
23
24#ifndef LTE_TEST_UE_MEASUREMENTS_H
25#define LTE_TEST_UE_MEASUREMENTS_H
26
27#include <ns3/lte-rrc-sap.h>
28#include <ns3/nstime.h>
29#include <ns3/test.h>
30
31#include <list>
32#include <set>
33#include <vector>
34
35namespace ns3
36{
37
38class MobilityModel;
39
40}
41
42using namespace ns3;
43
44// ===== LTE-UE-MEASUREMENTS TEST SUITE ==================================== //
45
46/**
47 * \ingroup lte-test
48 *
49 * \brief Test that UE Measurements (see 36.214) calculation works fine in a
50 * multi-cell interference scenario.
51 */
53{
54 public:
56};
57
58/**
59 * \ingroup lte-test
60 *
61 * \brief Test that UE measurements calculation works properly in a scenario
62 * with 2 eNodeBs and 2UEs. Test that RSRP and RSRQ of the serving cell and of
63 * the neighbor cell correspond to the reference values.
64 */
66{
67 public:
68 /**
69 * Constructor
70 *
71 * \param name the reference name
72 * \param d1 distance between UE and ENB node pair
73 * \param d2 distance between UE and other ENB node
74 * \param rsrpDbmUe1 RSRP in dBm UE 1
75 * \param rsrpDbmUe2 RSRP in dBm UE 2
76 * \param rsrqDbUe1 RSRQ in dBm UE 1
77 * \param rsrqDbUe2 RSRQ in dBm UE 2
78 */
79 LteUeMeasurementsTestCase(std::string name,
80 double d1,
81 double d2,
82 double rsrpDbmUe1,
83 double rsrpDbmUe2,
84 double rsrqDbUe1,
85 double rsrqDbUe2);
87
88 /**
89 * Report UE measurements function
90 * \param rnti the RNTI
91 * \param cellId the cell ID
92 * \param rsrp the RSRP
93 * \param rsrq the RSRQ
94 * \param servingCell the serving cell
95 */
96 void ReportUeMeasurements(uint16_t rnti,
97 uint16_t cellId,
98 double rsrp,
99 double rsrq,
100 bool servingCell);
101
102 /**
103 * Reeive measurement report function
104 * \param imsi the IMSI
105 * \param cellId the cell ID
106 * \param rnti the RNTI
107 * \param meas LteRrcSap::MeasurementReport
108 */
109 void RecvMeasurementReport(uint64_t imsi,
110 uint16_t cellId,
111 uint16_t rnti,
113
114 private:
115 void DoRun() override;
116
117 double m_d1; ///< distance between UE and ENB node pair
118 double m_d2; ///< distance between UE and other ENB node
119 double m_rsrpDbmUeServingCell; ///< RSRP in dBm UE 1
120 double m_rsrpDbmUeNeighborCell; ///< RSRP in dBm UE 2
121 double m_rsrqDbUeServingCell; ///< RSRQ in dBm UE 1
122 double m_rsrqDbUeNeighborCell; ///< RSRQ in dBm UE 2
123};
124
125// ===== LTE-UE-MEASUREMENTS-PIECEWISE-1 TEST SUITE ======================== //
126
127/**
128 * \ingroup lte-test
129 *
130 * \brief Test suite for generating calls to UE measurements test case
131 * ns3::LteUeMeasurementsPiecewiseTestCase1.
132 */
134{
135 public:
137};
138
139/**
140 * \ingroup lte-test
141 *
142 * \brief Testing UE measurements in LTE with simulation of 1 eNodeB and 1 UE in
143 * piecewise configuration and 120 ms report interval. During the simulation
144 * the placement of UE is being changed several times. Four different
145 * cases are considered: UE is very near to eNodeB, UE is near to eNodeB,
146 * UE is far from eNodeB and UE is very far from eNodeB. Test checks
147 * if the measurements correspond to the real conditions of the UE, i.e.
148 * when the signal from serving cell becomes weak, the measurements should
149 * also start to correspond to the new channel conditions. Additionally, it
150 * is checked if UE detects some neighboring signal, if it does the test
151 * fails because there is no neighbor in this configuration. Also, test
152 * checks if the reporting occurs at intervals that it should according to
153 * the measurements configuration. If it occurs in some different time
154 * stamp the test will fail.
155 */
157{
158 public:
159 /**
160 * Constructor
161 *
162 * \param name the reference name
163 * \param config LteRrcSap::ReportConfigEutra
164 * \param expectedTime the expected time
165 * \param expectedRsrp the expected RSRP
166 */
169 std::vector<Time> expectedTime,
170 std::vector<uint8_t> expectedRsrp);
171
173
174 /**
175 * \brief Triggers when eNodeB receives measurement report from UE, then
176 * perform verification on it.
177 *
178 * The trigger is set up beforehand by connecting to the
179 * `LteUeRrc::RecvMeasurementReport` trace source.
180 *
181 * Verification consists of checking whether the report carries the right
182 * value of RSRP or not, and whether it occurs at the expected time or not.
183 *
184 * \param context the context
185 * \param imsi the IMSI
186 * \param cellId the cell ID
187 * \param rnti the RNTI
188 * \param report LteRrcSap::MeasurementReport
189 */
190 void RecvMeasurementReportCallback(std::string context,
191 uint64_t imsi,
192 uint16_t cellId,
193 uint16_t rnti,
195
196 private:
197 /**
198 * \brief Setup the simulation with the intended UE measurement reporting
199 * configuration, run it, and connect the
200 * `RecvMeasurementReportCallback` function to the
201 * `LteUeRrc::RecvMeasurementReport` trace source.
202 */
203 void DoRun() override;
204
205 /**
206 * \brief Runs at the end of the simulation, verifying that all expected
207 * measurement reports have been examined.
208 */
209 void DoTeardown() override;
210
211 /// Teleport very near function
212 void TeleportVeryNear();
213 /// Teleport near function
214 void TeleportNear();
215 /// Teleport far function
216 void TeleportFar();
217 /// Teleport far function
218 void TeleportVeryFar();
219
220 /**
221 * \brief The active report triggering configuration.
222 */
224
225 /**
226 * \brief The list of expected time when measurement reports are received by
227 * eNodeB.
228 */
229 std::vector<Time> m_expectedTime;
230
231 /**
232 * \brief The list of expected values of RSRP (in 3GPP range unit) from the
233 * measurement reports received.
234 */
235 std::vector<uint8_t> m_expectedRsrp;
236
237 /**
238 * \brief Pointer to the element of `m_expectedTime` which is expected to
239 * occur next in the simulation.
240 */
241 std::vector<Time>::iterator m_itExpectedTime;
242
243 /**
244 * \brief Pointer to the element of `m_expectedRsrp` which is expected to
245 * occur next in the simulation.
246 */
247 std::vector<uint8_t>::iterator m_itExpectedRsrp;
248
249 /**
250 * \brief The measurement identity being tested. Measurement reports with
251 * different measurement identity (e.g. from handover algorithm) will
252 * be ignored.
253 */
255
256 Ptr<MobilityModel> m_ueMobility; ///< the mobility model
257
258}; // end of class LteUeMeasurementsPiecewiseTestCase1
259
260// ===== LTE-UE-MEASUREMENTS-PIECEWISE-2 TEST SUITE ======================== //
261
262/**
263 * \ingroup lte-test
264 *
265 * \brief Test suite for generating calls to UE measurements test case
266 * ns3::LteUeMeasurementsPiecewiseTestCase2.
267 */
269{
270 public:
272};
273
274/**
275 * \ingroup lte-test
276 *
277 * \brief Testing UE measurements in LTE with simulation of 2 eNodeB and 1 UE in
278 * piecewise configuration and 240 ms report interval.
279 * Here is intenisvely test events A1 and A2. A1 event should be triggered
280 * when the serving cell becomes better than a given threshold. A2 shall
281 * be triggered when the serving cell becomes worse than threshold. A3
282 * event is triggered when the neighbour becomes offset better than the PCell.
283 * In this test UE is being transported several times during the simulation
284 * duration. Then the test checks if measurement report contains correct
285 * RSRP and RSRQ result, than if CQI info is correctly generated, if the
286 * reporting occurs at the correct time stamp in the simulation and according
287 * to the measurements configuration. It also checks if the reported values
288 * of RSRP and RSRQ are equal to expected reference values.
289 *
290 */
292{
293 public:
294 /**
295 * Constructor
296 *
297 * \param name the reference name
298 * \param config LteRrcSap::ReportConfigEutra
299 * \param expectedTime the expected time
300 * \param expectedRsrp the expected RSRP
301 */
304 std::vector<Time> expectedTime,
305 std::vector<uint8_t> expectedRsrp);
306
308
309 /**
310 * \brief Triggers when eNodeB receives measurement report from UE, then
311 * perform verification on it.
312 *
313 * The trigger is set up beforehand by connecting to the
314 * `LteUeRrc::RecvMeasurementReport` trace source.
315 *
316 * Verification consists of checking whether the report carries the right
317 * value of RSRP or not, and whether it occurs at the expected time or not.
318 *
319 * \param context the context
320 * \param imsi the IMSI
321 * \param cellId the cell ID
322 * \param rnti the RNTI
323 * \param report LteRrcSap::MeasurementReport
324 */
325 void RecvMeasurementReportCallback(std::string context,
326 uint64_t imsi,
327 uint16_t cellId,
328 uint16_t rnti,
330
331 private:
332 /**
333 * \brief Setup the simulation with the intended UE measurement reporting
334 * configuration, run it, and connect the
335 * `RecvMeasurementReportCallback` function to the
336 * `LteUeRrc::RecvMeasurementReport` trace source.
337 */
338 void DoRun() override;
339
340 /**
341 * \brief Runs at the end of the simulation, verifying that all expected
342 * measurement reports have been examined.
343 */
344 void DoTeardown() override;
345
346 /// Teleport very near function
347 void TeleportVeryNear();
348 /// Teleport near function
349 void TeleportNear();
350 /// Teleport far function
351 void TeleportFar();
352 /// Teleport very far function
353 void TeleportVeryFar();
354
355 /**
356 * \brief The active report triggering configuration.
357 */
359
360 /**
361 * \brief The list of expected time when measurement reports are received by
362 * eNodeB.
363 */
364 std::vector<Time> m_expectedTime;
365
366 /**
367 * \brief The list of expected values of RSRP (in 3GPP range unit) from the
368 * measurement reports received.
369 */
370 std::vector<uint8_t> m_expectedRsrp;
371
372 /**
373 * \brief Pointer to the element of `m_expectedTime` which is expected to
374 * occur next in the simulation.
375 */
376 std::vector<Time>::iterator m_itExpectedTime;
377
378 /**
379 * \brief Pointer to the element of `m_expectedRsrp` which is expected to
380 * occur next in the simulation.
381 */
382 std::vector<uint8_t>::iterator m_itExpectedRsrp;
383
384 /**
385 * \brief The measurement identity being tested. Measurement reports with
386 * different measurement identity (e.g. from handover algorithm) will
387 * be ignored.
388 */
390
391 Ptr<MobilityModel> m_ueMobility; ///< the mobility model
392
393}; // end of class LteUeMeasurementsPiecewiseTestCase2
394
395// ===== LTE-UE-MEASUREMENTS-PIECEWISE-3 TEST SUITE ======================== //
396
397/**
398 * \ingroup lte-test
399 *
400 * \brief Test suite for generating calls to UE measurements test case
401 * ns3::LteUeMeasurementsPiecewiseTestCase3.
402 */
404{
405 public:
407};
408
409/**
410 * \ingroup lte-test
411 *
412 * \brief Testing UE measurements in LTE with simulation of 3 eNodeB and 1 UE in
413 * piecewise configuration and 240 ms report interval.
414 * This test is to cover a corner case using event A4, which is not
415 * covered by LteUeMeasurementsPiecewiseTestCase1 and
416 * LteUeMeasurementsPiecewiseTestCase2. In this case, we test that the UE
417 * measurements at eNB are arriving 240 ms apart. Please note, the
418 * scenario simulated is engineered to specifically test the corner case
419 * in which whenever a new neighbour fulfils the entry condition
420 * for event A4, the UE RRC calls VarMeasReportListAdd method to include
421 * the new cell id in cellsTriggeredList, and then it schedules the
422 * SendMeasurementReport for periodic reporting. However, if the UE has
423 * already started the periodic reporting, scheduling the
424 * SendMeasurementReport method again causes following buggy behaviors:
425 *
426 * 1. It generates an intermediate measurement event, which then leads
427 * to parallel intermediate measurement reports from a UE to its eNB.
428 *
429 * 2. The old EvenId is overwritten by the new EventId stored in
430 * VarMeasReportList. This makes us lose control over the old EventId
431 * and it is impossible to cancel its events later on.
432 *
433 * These buggy behaviors generated an issue reported in
434 * https://gitlab.com/nsnam/ns-3-dev/-/issues/224, where a UE try to
435 * send measurement reports after the RLF, even though all the measurement
436 * events are properly cancelled upon detecting RLF.
437 *
438 * The correct behaviour should be that if a UE has already started the
439 * periodic reporting, and once a new neighbour fulfils the entry
440 * condition, we just need to add its cell id in cellsTriggeredList,
441 * without scheduling a new periodic event.
442 *
443 */
445{
446 public:
447 /**
448 * Constructor
449 *
450 * \param name the reference name
451 * \param config LteRrcSap::ReportConfigEutra
452 * \param expectedTime the expected time
453 */
456 std::vector<Time> expectedTime);
457
459
460 /**
461 * \brief Triggers when eNodeB receives measurement report from UE, then
462 * perform verification on it.
463 *
464 * The trigger is set up beforehand by connecting to the
465 * `LteUeRrc::RecvMeasurementReport` trace source.
466 *
467 * Verification consists of checking whether the report carries the right
468 * value of RSRP or not, and whether it occurs at the expected time or not.
469 *
470 * \param context the context
471 * \param imsi the IMSI
472 * \param cellId the cell ID
473 * \param rnti the RNTI
474 * \param report LteRrcSap::MeasurementReport
475 */
476 void RecvMeasurementReportCallback(std::string context,
477 uint64_t imsi,
478 uint16_t cellId,
479 uint16_t rnti,
481
482 private:
483 /**
484 * \brief Setup the simulation with the intended UE measurement reporting
485 * configuration, run it, and connect the
486 * `RecvMeasurementReportCallback` function to the
487 * `LteUeRrc::RecvMeasurementReport` trace source.
488 */
489 void DoRun() override;
490
491 /**
492 * \brief Runs at the end of the simulation, verifying that all expected
493 * measurement reports have been examined.
494 */
495 void DoTeardown() override;
496
497 /// Teleport the eNb near function
498 void TeleportEnbNear();
499
500 /**
501 * \brief The active report triggering configuration.
502 */
504
505 /**
506 * \brief The list of expected time when measurement reports are received by
507 * eNodeB.
508 */
509 std::vector<Time> m_expectedTime;
510
511 /**
512 * \brief Pointer to the element of `m_expectedTime` which is expected to
513 * occur next in the simulation.
514 */
515 std::vector<Time>::iterator m_itExpectedTime;
516
517 /**
518 * \brief The measurement identity being tested. Measurement reports with
519 * different measurement identity (e.g. from handover algorithm) will
520 * be ignored.
521 */
523
524 Ptr<MobilityModel> m_enbMobility; ///< the mobility model
525
526}; // end of class LteUeMeasurementsPiecewiseTestCase3
527
528// ===== LTE-UE-MEASUREMENTS-HANDOVER TEST SUITE =========================== //
529
530/**
531 * \ingroup lte-test
532 *
533 * \brief Test suite for generating calls to UE measurements test case
534 * ns3::LteUeMeasurementsHandoverTestCase.
535 */
537{
538 public:
540};
541
542/**
543 * \ingroup lte-test
544 *
545 * \brief Testing UE measurements in LTE with simulation of 2 eNodeB and 1 UE in
546 * a handover configuration.
547 *
548 * The simulation will run for the specified duration, while the handover
549 * command will be issued exactly at the middle of simulation. Handover
550 * test covers four different scenarios: switch from event A1 to event A2,
551 * from event A2 to event A1, from event A3 to event A4, from event A4 to event
552 * A3, from event A2 to event A3, from event A3 to event A2, from event A4 to
553 * event A5, from event A5 to event A4. Additionally, it tests different
554 * handover threshold configurations, A2 threshold difference, A3 offset difference,
555 * A4 and A5 threshold difference. Finally, different handover is tested for
556 * different time-to-trigger (TTT) configurations.
557 *
558 */
560{
561 public:
562 /**
563 * Constructor
564 *
565 * \param name the reference name
566 * \param sourceConfigList std::list<LteRrcSap::ReportConfigEutra>
567 * \param targetConfigList std::list<LteRrcSap::ReportConfigEutra>
568 * \param expectedTime the expected time
569 * \param expectedRsrp the expected RSRP
570 * \param duration the duration
571 */
572 LteUeMeasurementsHandoverTestCase(std::string name,
573 std::list<LteRrcSap::ReportConfigEutra> sourceConfigList,
574 std::list<LteRrcSap::ReportConfigEutra> targetConfigList,
575 std::vector<Time> expectedTime,
576 std::vector<uint8_t> expectedRsrp,
577 Time duration);
578
580
581 /**
582 * \brief Triggers when either one of the eNodeBs receives measurement report
583 * from UE, then perform verification on it.
584 *
585 * The trigger is set up beforehand by connecting to the
586 * `LteUeRrc::RecvMeasurementReport` trace source.
587 *
588 * Verification consists of checking whether the report carries the right
589 * value of RSRP or not, and whether it occurs at the expected time or not.
590 *
591 * \param context the context
592 * \param imsi the IMSI
593 * \param cellId the cell ID
594 * \param rnti the RNTI
595 * \param report LteRrcSap::MeasurementReport
596 */
597 void RecvMeasurementReportCallback(std::string context,
598 uint64_t imsi,
599 uint16_t cellId,
600 uint16_t rnti,
602
603 private:
604 /**
605 * \brief Setup the simulation with the intended UE measurement reporting
606 * configuration, run it, and connect the
607 * `RecvMeasurementReportCallback` function to the
608 * `LteUeRrc::RecvMeasurementReport` trace source.
609 */
610 void DoRun() override;
611
612 /**
613 * \brief Runs at the end of the simulation, verifying that all expected
614 * measurement reports have been examined.
615 */
616 void DoTeardown() override;
617
618 /**
619 * \brief The list of active report triggering configuration for the source
620 * eNodeB.
621 */
622 std::list<LteRrcSap::ReportConfigEutra> m_sourceConfigList;
623
624 /**
625 * \brief The list of active report triggering configuration for the target
626 * eNodeB.
627 */
628 std::list<LteRrcSap::ReportConfigEutra> m_targetConfigList;
629
630 /**
631 * \brief The list of expected time when measurement reports are received by
632 * eNodeB.
633 */
634 std::vector<Time> m_expectedTime;
635
636 /**
637 * \brief The list of expected values of RSRP (in 3GPP range unit) from the
638 * measurement reports received.
639 */
640 std::vector<uint8_t> m_expectedRsrp;
641
642 /**
643 * \brief Pointer to the element of `m_expectedTime` which is expected to
644 * occur next in the simulation.
645 */
646 std::vector<Time>::iterator m_itExpectedTime;
647
648 /**
649 * \brief Pointer to the element of `m_expectedRsrp` which is expected to
650 * occur next in the simulation.
651 */
652 std::vector<uint8_t>::iterator m_itExpectedRsrp;
653
654 /**
655 * \brief Duration of simulation.
656 */
658
659 /**
660 * \brief The list of measurement identities being tested in the source cell.
661 * Measurement reports with different measurement identity (e.g. from
662 * handover algorithm and ANR) will be ignored.
663 */
664 std::set<uint8_t> m_expectedSourceCellMeasId;
665
666 /**
667 * \brief The list of measurement identities being tested in the target cell.
668 * Measurement reports with different measurement identity (e.g. from
669 * handover algorithm and ANR) will be ignored.
670 */
671 std::set<uint8_t> m_expectedTargetCellMeasId;
672
673}; // end of class LteUeMeasurementsHandoverTestCase
674
675#endif /* LTE_TEST_UE_MEASUREMENTS_H */
Testing UE measurements in LTE with simulation of 2 eNodeB and 1 UE in a handover configuration.
std::vector< uint8_t >::iterator m_itExpectedRsrp
Pointer to the element of m_expectedRsrp which is expected to occur next in the simulation.
std::vector< Time > m_expectedTime
The list of expected time when measurement reports are received by eNodeB.
std::list< LteRrcSap::ReportConfigEutra > m_sourceConfigList
The list of active report triggering configuration for the source eNodeB.
void DoRun() override
Setup the simulation with the intended UE measurement reporting configuration, run it,...
std::set< uint8_t > m_expectedTargetCellMeasId
The list of measurement identities being tested in the target cell.
void RecvMeasurementReportCallback(std::string context, uint64_t imsi, uint16_t cellId, uint16_t rnti, LteRrcSap::MeasurementReport report)
Triggers when either one of the eNodeBs receives measurement report from UE, then perform verificatio...
void DoTeardown() override
Runs at the end of the simulation, verifying that all expected measurement reports have been examined...
Time m_duration
Duration of simulation.
std::vector< Time >::iterator m_itExpectedTime
Pointer to the element of m_expectedTime which is expected to occur next in the simulation.
std::list< LteRrcSap::ReportConfigEutra > m_targetConfigList
The list of active report triggering configuration for the target eNodeB.
std::set< uint8_t > m_expectedSourceCellMeasId
The list of measurement identities being tested in the source cell.
std::vector< uint8_t > m_expectedRsrp
The list of expected values of RSRP (in 3GPP range unit) from the measurement reports received.
Test suite for generating calls to UE measurements test case ns3::LteUeMeasurementsHandoverTestCase.
Testing UE measurements in LTE with simulation of 1 eNodeB and 1 UE in piecewise configuration and 12...
std::vector< Time > m_expectedTime
The list of expected time when measurement reports are received by eNodeB.
void TeleportVeryFar()
Teleport far function.
LteRrcSap::ReportConfigEutra m_config
The active report triggering configuration.
uint8_t m_expectedMeasId
The measurement identity being tested.
std::vector< Time >::iterator m_itExpectedTime
Pointer to the element of m_expectedTime which is expected to occur next in the simulation.
Ptr< MobilityModel > m_ueMobility
the mobility model
void TeleportVeryNear()
Teleport very near function.
void TeleportNear()
Teleport near function.
std::vector< uint8_t > m_expectedRsrp
The list of expected values of RSRP (in 3GPP range unit) from the measurement reports received.
void DoTeardown() override
Runs at the end of the simulation, verifying that all expected measurement reports have been examined...
std::vector< uint8_t >::iterator m_itExpectedRsrp
Pointer to the element of m_expectedRsrp which is expected to occur next in the simulation.
void RecvMeasurementReportCallback(std::string context, uint64_t imsi, uint16_t cellId, uint16_t rnti, LteRrcSap::MeasurementReport report)
Triggers when eNodeB receives measurement report from UE, then perform verification on it.
void DoRun() override
Setup the simulation with the intended UE measurement reporting configuration, run it,...
Testing UE measurements in LTE with simulation of 2 eNodeB and 1 UE in piecewise configuration and 24...
Ptr< MobilityModel > m_ueMobility
the mobility model
std::vector< Time >::iterator m_itExpectedTime
Pointer to the element of m_expectedTime which is expected to occur next in the simulation.
void TeleportVeryNear()
Teleport very near function.
std::vector< uint8_t > m_expectedRsrp
The list of expected values of RSRP (in 3GPP range unit) from the measurement reports received.
void DoTeardown() override
Runs at the end of the simulation, verifying that all expected measurement reports have been examined...
LteRrcSap::ReportConfigEutra m_config
The active report triggering configuration.
void DoRun() override
Setup the simulation with the intended UE measurement reporting configuration, run it,...
void RecvMeasurementReportCallback(std::string context, uint64_t imsi, uint16_t cellId, uint16_t rnti, LteRrcSap::MeasurementReport report)
Triggers when eNodeB receives measurement report from UE, then perform verification on it.
void TeleportVeryFar()
Teleport very far function.
void TeleportNear()
Teleport near function.
std::vector< uint8_t >::iterator m_itExpectedRsrp
Pointer to the element of m_expectedRsrp which is expected to occur next in the simulation.
uint8_t m_expectedMeasId
The measurement identity being tested.
std::vector< Time > m_expectedTime
The list of expected time when measurement reports are received by eNodeB.
Testing UE measurements in LTE with simulation of 3 eNodeB and 1 UE in piecewise configuration and 24...
Ptr< MobilityModel > m_enbMobility
the mobility model
void DoTeardown() override
Runs at the end of the simulation, verifying that all expected measurement reports have been examined...
void DoRun() override
Setup the simulation with the intended UE measurement reporting configuration, run it,...
void RecvMeasurementReportCallback(std::string context, uint64_t imsi, uint16_t cellId, uint16_t rnti, LteRrcSap::MeasurementReport report)
Triggers when eNodeB receives measurement report from UE, then perform verification on it.
LteRrcSap::ReportConfigEutra m_config
The active report triggering configuration.
uint8_t m_expectedMeasId
The measurement identity being tested.
std::vector< Time > m_expectedTime
The list of expected time when measurement reports are received by eNodeB.
void TeleportEnbNear()
Teleport the eNb near function.
std::vector< Time >::iterator m_itExpectedTime
Pointer to the element of m_expectedTime which is expected to occur next in the simulation.
Test suite for generating calls to UE measurements test case ns3::LteUeMeasurementsPiecewiseTestCase1...
Test suite for generating calls to UE measurements test case ns3::LteUeMeasurementsPiecewiseTestCase2...
Test suite for generating calls to UE measurements test case ns3::LteUeMeasurementsPiecewiseTestCase3...
Test that UE measurements calculation works properly in a scenario with 2 eNodeBs and 2UEs.
double m_d1
distance between UE and ENB node pair
double m_rsrqDbUeServingCell
RSRQ in dBm UE 1.
double m_rsrpDbmUeServingCell
RSRP in dBm UE 1.
void ReportUeMeasurements(uint16_t rnti, uint16_t cellId, double rsrp, double rsrq, bool servingCell)
Report UE measurements function.
void DoRun() override
Implementation to actually run this TestCase.
double m_rsrqDbUeNeighborCell
RSRQ in dBm UE 2.
double m_d2
distance between UE and other ENB node
double m_rsrpDbmUeNeighborCell
RSRP in dBm UE 2.
void RecvMeasurementReport(uint64_t imsi, uint16_t cellId, uint16_t rnti, LteRrcSap::MeasurementReport meas)
Reeive measurement report function.
Test that UE Measurements (see 36.214) calculation works fine in a multi-cell interference scenario.
Keep track of the current position and velocity of an object.
Smart pointer class similar to boost::intrusive_ptr.
Definition: ptr.h:77
encapsulates test code
Definition: test.h:1061
A suite of tests to run.
Definition: test.h:1268
Simulation virtual time values and global simulation resolution.
Definition: nstime.h:105
Every class exported by the ns3 library is enclosed in the ns3 namespace.
MeasurementReport structure.
Definition: lte-rrc-sap.h:948
Specifies criteria for triggering of an E-UTRA measurement reporting event.
Definition: lte-rrc-sap.h:373