A Discrete-Event Network Simulator
API
lte-ffr-soft-algorithm.cc
Go to the documentation of this file.
1 /* -*- Mode: C++; c-file-style: "gnu"; indent-tabs-mode:nil; -*- */
2 /*
3  * Copyright (c) 2014 Piotr Gawlowicz
4  *
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
7  * published by the Free Software Foundation;
8  *
9  * This program is distributed in the hope that it will be useful,
10  * but WITHOUT ANY WARRANTY; without even the implied warranty of
11  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
12  * GNU General Public License for more details.
13  *
14  * You should have received a copy of the GNU General Public License
15  * along with this program; if not, write to the Free Software
16  * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
17  *
18  * Author: Piotr Gawlowicz <gawlowicz.p@gmail.com>
19  *
20  */
21 
22 #include "lte-ffr-soft-algorithm.h"
23 #include <ns3/log.h>
24 #include "ns3/boolean.h"
25 
26 namespace ns3 {
27 
28 NS_LOG_COMPONENT_DEFINE ("LteFfrSoftAlgorithm");
29 
30 NS_OBJECT_ENSURE_REGISTERED (LteFfrSoftAlgorithm);
31 
34 {
35  uint8_t cellId;
36  uint8_t dlBandwidth;
41  { 1, 15, 2, 0, 4},
42  { 2, 15, 2, 4, 4},
43  { 3, 15, 2, 8, 4},
44  { 1, 25, 6, 0, 6},
45  { 2, 25, 6, 6, 6},
46  { 3, 25, 6, 12, 6},
47  { 1, 50, 21, 0, 9},
48  { 2, 50, 21, 9, 9},
49  { 3, 50, 21, 18, 11},
50  { 1, 75, 36, 0, 12},
51  { 2, 75, 36, 12, 12},
52  { 3, 75, 36, 24, 15},
53  { 1, 100, 28, 0, 24},
54  { 2, 100, 28, 24, 24},
55  { 3, 100, 28, 48, 24}
56 };
57 
60 {
61  uint8_t cellId;
62  uint8_t ulBandwidth;
67  { 1, 15, 3, 0, 4},
68  { 2, 15, 3, 4, 4},
69  { 3, 15, 3, 8, 4},
70  { 1, 25, 6, 0, 6},
71  { 2, 25, 6, 6, 6},
72  { 3, 25, 6, 12, 6},
73  { 1, 50, 21, 0, 9},
74  { 2, 50, 21, 9, 9},
75  { 3, 50, 21, 18, 11},
76  { 1, 75, 36, 0, 12},
77  { 2, 75, 36, 12, 12},
78  { 3, 75, 36, 24, 15},
79  { 1, 100, 28, 0, 24},
80  { 2, 100, 28, 24, 24},
81  { 3, 100, 28, 48, 24}
82 };
83 
88 
89 
91  : m_ffrSapUser (0),
92  m_ffrRrcSapUser (0),
93  m_dlEdgeSubBandOffset (0),
94  m_dlEdgeSubBandwidth (0),
95  m_ulEdgeSubBandOffset (0),
96  m_ulEdgeSubBandwidth (0),
97  m_measId (0)
98 {
99  NS_LOG_FUNCTION (this);
102 }
103 
104 
106 {
107  NS_LOG_FUNCTION (this);
108 }
109 
110 
111 void
113 {
114  NS_LOG_FUNCTION (this);
115  delete m_ffrSapProvider;
116  delete m_ffrRrcSapProvider;
117 }
118 
119 
120 TypeId
122 {
123  static TypeId tid = TypeId ("ns3::LteFfrSoftAlgorithm")
125  .SetGroupName("Lte")
126  .AddConstructor<LteFfrSoftAlgorithm> ()
127  .AddAttribute ("UlCommonSubBandwidth",
128  "Uplink Medium (Common) SubBandwidth Configuration in number of Resource Block Groups",
129  UintegerValue (6),
131  MakeUintegerChecker<uint8_t> ())
132  .AddAttribute ("UlEdgeSubBandOffset",
133  "Uplink Edge SubBand Offset in number of Resource Block Groups",
134  UintegerValue (0),
136  MakeUintegerChecker<uint8_t> ())
137  .AddAttribute ("UlEdgeSubBandwidth",
138  "Uplink Edge SubBandwidth Configuration in number of Resource Block Groups",
139  UintegerValue (6),
141  MakeUintegerChecker<uint8_t> ())
142  .AddAttribute ("DlCommonSubBandwidth",
143  "Downlink Medium (Common) SubBandwidth Configuration in number of Resource Block Groups",
144  UintegerValue (6),
146  MakeUintegerChecker<uint8_t> ())
147  .AddAttribute ("DlEdgeSubBandOffset",
148  "Downlink Edge SubBand Offset in number of Resource Block Groups",
149  UintegerValue (0),
151  MakeUintegerChecker<uint8_t> ())
152  .AddAttribute ("DlEdgeSubBandwidth",
153  "Downlink Edge SubBandwidth Configuration in number of Resource Block Groups",
154  UintegerValue (0),
156  MakeUintegerChecker<uint8_t> ())
157  .AddAttribute ("CenterRsrqThreshold",
158  "If the RSRQ of is worse than this threshold, UE should be served in Medium sub-band",
159  UintegerValue (30),
161  MakeUintegerChecker<uint8_t> ())
162  .AddAttribute ("EdgeRsrqThreshold",
163  "If the RSRQ of is worse than this threshold, UE should be served in Edge sub-band",
164  UintegerValue (20),
166  MakeUintegerChecker<uint8_t> ())
167  .AddAttribute ("CenterAreaPowerOffset",
168  "PdschConfigDedicated::Pa value for Center Sub-band, default value dB0",
169  UintegerValue (5),
171  MakeUintegerChecker<uint8_t> ())
172  .AddAttribute ("MediumAreaPowerOffset",
173  "PdschConfigDedicated::Pa value for Medium Sub-band, default value dB0",
174  UintegerValue (5),
176  MakeUintegerChecker<uint8_t> ())
177  .AddAttribute ("EdgeAreaPowerOffset",
178  "PdschConfigDedicated::Pa value for Edge Sub-band, default value dB0",
179  UintegerValue (5),
181  MakeUintegerChecker<uint8_t> ())
182  .AddAttribute ("CenterAreaTpc",
183  "TPC value which will be set in DL-DCI for UEs in center area"
184  "Absolute mode is used, default value 1 is mapped to -1 according to"
185  "TS36.213 Table 5.1.1.1-2",
186  UintegerValue (1),
188  MakeUintegerChecker<uint8_t> ())
189  .AddAttribute ("MediumAreaTpc",
190  "TPC value which will be set in DL-DCI for UEs in medium area"
191  "Absolute mode is used, default value 1 is mapped to -1 according to"
192  "TS36.213 Table 5.1.1.1-2",
193  UintegerValue (1),
195  MakeUintegerChecker<uint8_t> ())
196  .AddAttribute ("EdgeAreaTpc",
197  "TPC value which will be set in DL-DCI for UEs in edge area"
198  "Absolute mode is used, default value 1 is mapped to -1 according to"
199  "TS36.213 Table 5.1.1.1-2",
200  UintegerValue (1),
202  MakeUintegerChecker<uint8_t> ())
203  ;
204  return tid;
205 }
206 
207 
208 void
210 {
211  NS_LOG_FUNCTION (this << s);
212  m_ffrSapUser = s;
213 }
214 
215 
218 {
219  NS_LOG_FUNCTION (this);
220  return m_ffrSapProvider;
221 }
222 
223 void
225 {
226  NS_LOG_FUNCTION (this << s);
227  m_ffrRrcSapUser = s;
228 }
229 
230 
233 {
234  NS_LOG_FUNCTION (this);
235  return m_ffrRrcSapProvider;
236 }
237 
238 
239 void
241 {
242  NS_LOG_FUNCTION (this);
244 
245  NS_ASSERT_MSG (m_dlBandwidth > 14,"DlBandwidth must be at least 15 to use FFR algorithms");
246  NS_ASSERT_MSG (m_ulBandwidth > 14,"UlBandwidth must be at least 15 to use FFR algorithms");
247 
248  if (m_frCellTypeId != 0)
249  {
252  }
253 
254  NS_LOG_LOGIC (this << " requesting Event A1 measurements"
255  << " (threshold = 0" << ")");
256  LteRrcSap::ReportConfigEutra reportConfig;
259  reportConfig.threshold1.range = 0;
263 }
264 
265 void
267 {
268  NS_LOG_FUNCTION (this);
269  if (m_frCellTypeId != 0)
270  {
273  }
276  m_needReconfiguration = false;
277 }
278 
279 void
280 LteFfrSoftAlgorithm::SetDownlinkConfiguration (uint16_t cellId, uint8_t bandwidth)
281 {
282  NS_LOG_FUNCTION (this);
283  for (uint16_t i = 0; i < NUM_DOWNLINK_CONFS; ++i)
284  {
285  if ((g_ffrSoftDownlinkDefaultConfiguration[i].cellId == cellId)
287  {
291  }
292  }
293 }
294 
295 void
296 LteFfrSoftAlgorithm::SetUplinkConfiguration (uint16_t cellId, uint8_t bandwidth)
297 {
298  NS_LOG_FUNCTION (this);
299  for (uint16_t i = 0; i < NUM_UPLINK_CONFS; ++i)
300  {
301  if ((g_ffrSoftUplinkDefaultConfiguration[i].cellId == cellId)
303  {
307  }
308  }
309 }
310 
311 void
313 {
314  m_dlRbgMap.clear ();
315  m_dlCenterRbgMap.clear ();
316  m_dlMediumRbgMap.clear ();
317  m_dlEdgeRbgMap.clear ();
318 
319  int rbgSize = GetRbgSize (m_dlBandwidth);
320  m_dlRbgMap.resize (m_dlBandwidth / rbgSize, false);
321  m_dlCenterRbgMap.resize (m_dlBandwidth / rbgSize, true);
322  m_dlMediumRbgMap.resize (m_dlBandwidth / rbgSize, false);
323  m_dlEdgeRbgMap.resize (m_dlBandwidth / rbgSize, false);
324 
325  NS_ASSERT_MSG (m_dlCommonSubBandwidth <= m_dlBandwidth,"DlCommonSubBandwidth higher than DlBandwidth");
327  "DlCommonSubBandwidth + DlEdgeSubBandOffset higher than DlBandwidth");
328  NS_ASSERT_MSG (m_dlEdgeSubBandOffset <= m_dlBandwidth,"DlEdgeSubBandOffset higher than DlBandwidth");
329  NS_ASSERT_MSG (m_dlEdgeSubBandwidth <= m_dlBandwidth,"DlEdgeSubBandwidth higher than DlBandwidth");
331  "(DlCommonSubBandwidth + DlEdgeSubBandOffset+DlEdgeSubBandwidth) higher than DlBandwidth");
332 
333  for (uint8_t i = 0;
334  i < m_dlCommonSubBandwidth / rbgSize; i++)
335  {
336  m_dlMediumRbgMap[i] = true;
337  m_dlCenterRbgMap[i] = false;
338  }
339 
340  for (uint8_t i = (m_dlCommonSubBandwidth + m_dlEdgeSubBandOffset) / rbgSize;
342  {
343  m_dlEdgeRbgMap[i] = true;
344  m_dlCenterRbgMap[i] = false;
345  }
346 }
347 
348 
349 void
351 {
352  m_ulRbgMap.clear ();
353  m_ulCenterRbgMap.clear ();
354  m_ulMediumRbgMap.clear ();
355  m_ulEdgeRbgMap.clear ();
356 
357  m_ulRbgMap.resize (m_ulBandwidth, false);
358  m_ulCenterRbgMap.resize (m_ulBandwidth, true);
359  m_ulMediumRbgMap.resize (m_ulBandwidth, false);
360  m_ulEdgeRbgMap.resize (m_ulBandwidth, false);
361 
362  NS_ASSERT_MSG (m_ulCommonSubBandwidth <= m_ulBandwidth,"UlCommonSubBandwidth higher than UlBandwidth");
364  "UlCommonSubBandwidth + UlEdgeSubBandOffset higher than UlBandwidth");
365  NS_ASSERT_MSG (m_ulEdgeSubBandOffset <= m_ulBandwidth,"UlEdgeSubBandOffset higher than UlBandwidth");
366  NS_ASSERT_MSG (m_ulEdgeSubBandwidth <= m_ulBandwidth,"UlEdgeSubBandwidth higher than UlBandwidth");
368  "(UlCommonSubBandwidth + UlEdgeSubBandOffset+UlEdgeSubBandwidth) higher than UlBandwidth");
369 
370  for (uint8_t i = 0;
371  i < m_ulCommonSubBandwidth; i++)
372  {
373  m_ulMediumRbgMap[i] = true;
374  m_ulCenterRbgMap[i] = false;
375  }
376 
377  for (uint8_t i = (m_ulCommonSubBandwidth + m_ulEdgeSubBandOffset);
379  {
380  m_ulEdgeRbgMap[i] = true;
381  m_ulCenterRbgMap[i] = false;
382  }
383 }
384 
385 std::vector <bool>
387 {
388  NS_LOG_FUNCTION (this);
389 
391  {
392  Reconfigure ();
393  }
394 
395  if (m_dlRbgMap.empty ())
396  {
398  }
399 
400  return m_dlRbgMap;
401 }
402 
403 bool
405 {
406  NS_LOG_FUNCTION (this);
407 
408  bool isCenterRbg = m_dlCenterRbgMap[rbgId];
409  bool isMediumRbg = m_dlMediumRbgMap[rbgId];
410  bool isEdgeRbg = m_dlEdgeRbgMap[rbgId];
411 
412  std::map< uint16_t, uint8_t >::iterator it = m_ues.find (rnti);
413  if (it == m_ues.end ())
414  {
415  m_ues.insert (std::pair< uint16_t, uint8_t > (rnti, AreaUnset));
416  }
417 
418  it = m_ues.find (rnti);
419 
420  //if UE area is unknown, serve UE in medium (common) RBGs
421  if (it->second == AreaUnset)
422  {
423  return isMediumRbg;
424  }
425 
426 
427  bool isCenterUe = false;
428  bool isMediumUe = false;
429  bool isEdgeUe = false;
430 
431  if (it->second == CenterArea )
432  {
433  isCenterUe = true;
434  }
435  else if (it->second == MediumArea)
436  {
437  isMediumUe = true;
438  }
439  else if (it->second == EdgeArea)
440  {
441  isEdgeUe = true;
442  }
443 
444  return (isCenterRbg && isCenterUe) || (isMediumRbg && isMediumUe) || (isEdgeRbg && isEdgeUe);
445 }
446 
447 std::vector <bool>
449 {
450  NS_LOG_FUNCTION (this);
451 
452  if (m_ulRbgMap.empty ())
453  {
455  }
456 
457  return m_ulRbgMap;
458 }
459 
460 bool
462 {
463  NS_LOG_FUNCTION (this);
464 
465  if (!m_enabledInUplink)
466  {
467  return true;
468  }
469 
470  bool isCenterRbg = m_ulCenterRbgMap[rbgId];
471  bool isMediumRbg = m_ulMediumRbgMap[rbgId];
472  bool isEdgeRbg = m_ulEdgeRbgMap[rbgId];
473 
474  std::map< uint16_t, uint8_t >::iterator it = m_ues.find (rnti);
475  if (it == m_ues.end ())
476  {
477  m_ues.insert (std::pair< uint16_t, uint8_t > (rnti, AreaUnset));
478  }
479 
480  it = m_ues.find (rnti);
481 
482  //if UE area is unknown, serve UE in medium (common) RBGs
483  if (it->second == AreaUnset)
484  {
485  return isMediumRbg;
486  }
487 
488 
489  bool isCenterUe = false;
490  bool isMediumUe = false;
491  bool isEdgeUe = false;
492 
493  if (it->second == CenterArea )
494  {
495  isCenterUe = true;
496  }
497  else if (it->second == MediumArea)
498  {
499  isMediumUe = true;
500  }
501  else if (it->second == EdgeArea)
502  {
503  isEdgeUe = true;
504  }
505 
506  return (isCenterRbg && isCenterUe) || (isMediumRbg && isMediumUe) || (isEdgeRbg && isEdgeUe);
507 }
508 
509 void
511 {
512  NS_LOG_FUNCTION (this);
513  NS_LOG_WARN ("Method should not be called, because it is empty");
514 }
515 
516 void
518 {
519  NS_LOG_FUNCTION (this);
520  NS_LOG_WARN ("Method should not be called, because it is empty");
521 }
522 
523 void
524 LteFfrSoftAlgorithm::DoReportUlCqiInfo (std::map <uint16_t, std::vector <double> > ulCqiMap)
525 {
526  NS_LOG_FUNCTION (this);
527  NS_LOG_WARN ("Method should not be called, because it is empty");
528 }
529 
530 uint8_t
532 {
533  NS_LOG_FUNCTION (this);
534 
535  if (!m_enabledInUplink)
536  {
537  return 1; // 1 is mapped to 0 for Accumulated mode, and to -1 in Absolute mode TS36.213 Table 5.1.1.1-2
538  }
539 
540  //TS36.213 Table 5.1.1.1-2
541  // TPC | Accumulated Mode | Absolute Mode
542  //------------------------------------------------
543  // 0 | -1 | -4
544  // 1 | 0 | -1
545  // 2 | 1 | 1
546  // 3 | 3 | 4
547  //------------------------------------------------
548  // here Absolute mode is used
549 
550  std::map< uint16_t, uint8_t >::iterator it = m_ues.find (rnti);
551  if (it == m_ues.end ())
552  {
553  return 1;
554  }
555 
556  if (it->second == CenterArea )
557  {
558  return m_centerAreaTpc;
559  }
560  else if (it->second == MediumArea)
561  {
562  return m_mediumAreaTpc;
563  }
564  else if (it->second == EdgeArea)
565  {
566  return m_edgeAreaTpc;
567  }
568 
569  return 1;
570 }
571 
572 uint16_t
574 {
575  NS_LOG_FUNCTION (this);
576 
577  if (!m_enabledInUplink)
578  {
579  return m_ulBandwidth;
580  }
581 
582  uint8_t centerSubBandwidth = 0;
583  uint8_t mediumSubBandwidth = 0;
584  uint8_t edgeSubBandwidth = 0;
585 
586  for (uint8_t i = 0; i < m_ulCenterRbgMap.size (); i++)
587  {
588  if ( m_ulCenterRbgMap[i] == true)
589  {
590  centerSubBandwidth++;
591  }
592  }
593 
594  for (uint8_t i = 0; i < m_ulMediumRbgMap.size (); i++)
595  {
596  if ( m_ulMediumRbgMap[i] == true)
597  {
598  mediumSubBandwidth++;
599  }
600  }
601 
602  for (uint8_t i = 0; i < m_ulEdgeRbgMap.size (); i++)
603  {
604  if ( m_ulEdgeRbgMap[i] == true)
605  {
606  edgeSubBandwidth++;
607  }
608  }
609 
610  uint8_t minContinuousUlBandwidth = m_ulBandwidth;
611 
612  minContinuousUlBandwidth =
613  ((centerSubBandwidth > 0 ) && (centerSubBandwidth < minContinuousUlBandwidth)) ? centerSubBandwidth : minContinuousUlBandwidth;
614 
615  minContinuousUlBandwidth =
616  ((mediumSubBandwidth > 0 ) && (mediumSubBandwidth < minContinuousUlBandwidth)) ? mediumSubBandwidth : minContinuousUlBandwidth;
617 
618  minContinuousUlBandwidth =
619  ((edgeSubBandwidth > 0 ) && (edgeSubBandwidth < minContinuousUlBandwidth)) ? edgeSubBandwidth : minContinuousUlBandwidth;
620 
621  NS_LOG_INFO ("minContinuousUlBandwidth: " << (int)minContinuousUlBandwidth);
622 
623  return minContinuousUlBandwidth;
624 }
625 
626 void
628  LteRrcSap::MeasResults measResults)
629 {
630  NS_LOG_FUNCTION (this << rnti << (uint16_t) measResults.measId);
631  NS_LOG_INFO ("RNTI :" << rnti << " MeasId: " << (uint16_t) measResults.measId
632  << " RSRP: " << (uint16_t)measResults.measResultPCell.rsrpResult
633  << " RSRQ: " << (uint16_t)measResults.measResultPCell.rsrqResult);
634 
636  "CenterSubBandThreshold must be higher than EdgeSubBandThreshold");
637 
638  if (measResults.measId != m_measId)
639  {
640  NS_LOG_WARN ("Ignoring measId " << (uint16_t) measResults.measId);
641  }
642  else
643  {
644 
645  std::map< uint16_t, uint8_t >::iterator it = m_ues.find (rnti);
646  if (it == m_ues.end ())
647  {
648  m_ues.insert (std::pair< uint16_t, uint8_t > (rnti, AreaUnset));
649  }
650 
651  it = m_ues.find (rnti);
653  {
654  if (it->second != CenterArea)
655  {
656  NS_LOG_INFO ("UE RNTI: " << rnti << " will be served in Center sub-band");
657  it->second = CenterArea;
658 
659  LteRrcSap::PdschConfigDedicated pdschConfigDedicated;
660  pdschConfigDedicated.pa = m_centerAreaPowerOffset;
661  m_ffrRrcSapUser->SetPdschConfigDedicated (rnti, pdschConfigDedicated);
662  }
663  }
664  else if (measResults.measResultPCell.rsrqResult < m_edgeSubBandThreshold)
665  {
666  if (it->second != EdgeArea )
667  {
668  NS_LOG_INFO ("UE RNTI: " << rnti << " will be served in Edge sub-band");
669  it->second = EdgeArea;
670 
671  LteRrcSap::PdschConfigDedicated pdschConfigDedicated;
672  pdschConfigDedicated.pa = m_edgeAreaPowerOffset;
673  m_ffrRrcSapUser->SetPdschConfigDedicated (rnti, pdschConfigDedicated);
674  }
675  }
676  else
677  {
678  if (it->second != MediumArea)
679  {
680  NS_LOG_INFO ("UE RNTI: " << rnti << " will be served in Medium sub-band");
681  it->second = MediumArea;
682 
683  LteRrcSap::PdschConfigDedicated pdschConfigDedicated;
684  pdschConfigDedicated.pa = m_mediumAreaPowerOffset;
685  m_ffrRrcSapUser->SetPdschConfigDedicated (rnti, pdschConfigDedicated);
686  }
687  }
688  }
689 }
690 
691 void
693 {
694  NS_LOG_FUNCTION (this);
695  NS_LOG_WARN ("Method should not be called, because it is empty");
696 }
697 
698 } // end of namespace ns3
The abstract base class of a Frequency Reuse algorithm.
bool m_needReconfiguration
If true FR algorithm will be reconfigured.
uint8_t m_frCellTypeId
FFR cell type ID for automatic configuration.
int GetRbgSize(int dlbandwidth)
Get RBG size for DL Bandwidth according to table 7.1.6.1-1 of 36.213.
bool m_enabledInUplink
If true FR algorithm will also work in Uplink.
uint8_t m_dlBandwidth
downlink bandwidth in RBs
uint8_t m_ulBandwidth
uplink bandwidth in RBs
Service Access Point (SAP) offered by the Frequency Reuse algorithm instance to the eNodeB RRC instan...
Service Access Point (SAP) offered by the eNodeB RRC instance to the Frequency Reuse algorithm instan...
virtual void SetPdschConfigDedicated(uint16_t rnti, LteRrcSap::PdschConfigDedicated pdschConfigDedicated)=0
Instruct the eNodeB RRC entity to perform RrcConnectionReconfiguration to inform UE about new PdschCo...
virtual uint8_t AddUeMeasReportConfigForFfr(LteRrcSap::ReportConfigEutra reportConfig)=0
Request a certain reporting configuration to be fulfilled by the UEs attached to the eNodeB entity.
Service Access Point (SAP) offered by the Frequency Reuse algorithm instance to the MAC Scheduler ins...
Definition: lte-ffr-sap.h:40
Service Access Point (SAP) offered by the eNodeB RRC instance to the Frequency Reuse algorithm instan...
Definition: lte-ffr-sap.h:139
Soft Fractional Frequency Reuse algorithm implementation.
virtual void Reconfigure()
Automatic FR reconfiguration.
void SetUplinkConfiguration(uint16_t cellId, uint8_t bandwidth)
Set uplink configuration function.
std::vector< bool > m_dlRbgMap
DL RBG Map.
LteFfrSoftAlgorithm()
Creates a trivial ffr algorithm instance.
uint8_t m_dlEdgeSubBandOffset
DL edge subband offset.
virtual uint8_t DoGetTpc(uint16_t rnti)
DoGetTpc for UE.
LteFfrSapProvider * m_ffrSapProvider
FFR SAP provider.
friend class MemberLteFfrRrcSapProvider< LteFfrSoftAlgorithm >
let the forwarder class access the protected and private members
std::vector< bool > m_ulMediumRbgMap
UL medium RBG map.
uint8_t m_ulEdgeSubBandwidth
UL edge subbandwidth.
uint8_t m_centerAreaTpc
center area tpc
std::vector< bool > m_ulRbgMap
UL RBG map.
virtual bool DoIsDlRbgAvailableForUe(int i, uint16_t rnti)
Implementation of LteFfrSapProvider::IsDlRbgAvailableForUe.
virtual void DoDispose()
Destructor implementation.
virtual bool DoIsUlRbgAvailableForUe(int i, uint16_t rnti)
Implementation of LteFfrSapProvider::IsUlRbgAvailableForUe.
std::vector< bool > m_dlMediumRbgMap
DL medium RBG map.
std::vector< bool > m_dlEdgeRbgMap
DL edge RBG map.
uint8_t m_mediumAreaPowerOffset
medium area power offset
virtual LteFfrRrcSapProvider * GetLteFfrRrcSapProvider()
Export the "provider" part of the LteFfrRrcSap interface.
virtual void DoReportUlCqiInfo(const struct FfMacSchedSapProvider::SchedUlCqiInfoReqParameters &params)
DoReportUlCqiInfo.
uint8_t m_edgeAreaPowerOffset
edge area power offset
virtual void DoReportDlCqiInfo(const struct FfMacSchedSapProvider::SchedDlCqiInfoReqParameters &params)
DoReportDlCqiInfo.
std::vector< bool > m_dlCenterRbgMap
DL center RBG map.
uint8_t m_mediumAreaTpc
medium area tpc
virtual void DoRecvLoadInformation(EpcX2Sap::LoadInformationParams params)
DoRecvLoadInformation.
virtual void SetLteFfrRrcSapUser(LteFfrRrcSapUser *s)
Set the "user" part of the LteFfrRrcSap interface that this frequency reuse algorithm instance will i...
void InitializeUplinkRbgMaps()
Initialize uplink RBG maps function.
uint8_t m_ulEdgeSubBandOffset
UL edge subband offset.
uint8_t m_dlEdgeSubBandwidth
DL edge subbandwidth.
uint8_t m_edgeSubBandThreshold
edge subband threshold
virtual void DoReportUeMeas(uint16_t rnti, LteRrcSap::MeasResults measResults)
Implementation of LteFfrRrcSapProvider::ReportUeMeas.
LteFfrSapUser * m_ffrSapUser
FFR SAP user.
std::vector< bool > m_ulCenterRbgMap
UL center RBG map.
void SetDownlinkConfiguration(uint16_t cellId, uint8_t bandwidth)
Set downlink configuration function.
std::vector< bool > m_ulEdgeRbgMap
UL edge RBG map.
virtual void SetLteFfrSapUser(LteFfrSapUser *s)
Set the "user" part of the LteFfrSap interface that this frequency reuse algorithm instance will inte...
uint8_t m_ulCommonSubBandwidth
UL common subbandwidth.
uint8_t m_centerAreaPowerOffset
center area power offset
virtual std::vector< bool > DoGetAvailableDlRbg()
Implementation of LteFfrSapProvider::GetAvailableDlRbg.
uint8_t m_centerSubBandThreshold
center subband threshold
uint8_t m_measId
The expected measurement identity.
virtual uint16_t DoGetMinContinuousUlBandwidth()
DoGetMinContinuousUlBandwidth in number of RB.
LteFfrRrcSapProvider * m_ffrRrcSapProvider
FFR RRC SAP provider.
LteFfrRrcSapUser * m_ffrRrcSapUser
FFR RRC SAP user.
uint8_t m_dlCommonSubBandwidth
DL common subbandwidth.
void InitializeDownlinkRbgMaps()
Initialize downlink RBG maps function.
std::map< uint16_t, uint8_t > m_ues
UEs.
friend class MemberLteFfrSapProvider< LteFfrSoftAlgorithm >
let the forwarder class access the protected and private members
virtual void DoInitialize()
Initialize() implementation.
virtual std::vector< bool > DoGetAvailableUlRbg()
Implementation of LteFfrSapProvider::GetAvailableUlRbg.
uint8_t m_edgeAreaTpc
edge area tpc
static TypeId GetTypeId()
Get the type ID.
virtual LteFfrSapProvider * GetLteFfrSapProvider()
Export the "provider" part of the LteFfrSap interface.
virtual void DoInitialize(void)
Initialize() implementation.
Definition: object.cc:353
a unique identifier for an interface.
Definition: type-id.h:59
TypeId SetParent(TypeId tid)
Set the parent TypeId.
Definition: type-id.cc:922
Hold an unsigned integer type.
Definition: uinteger.h:44
#define NS_ASSERT_MSG(condition, message)
At runtime, in debugging builds, if this condition is not true, the program prints the message to out...
Definition: assert.h:88
Ptr< const AttributeAccessor > MakeUintegerAccessor(T1 a1)
Create an AttributeAccessor for a class data member, or a lone class get functor or set method.
Definition: uinteger.h:45
#define NS_LOG_COMPONENT_DEFINE(name)
Define a Log component with a specific name.
Definition: log.h:205
#define NS_LOG_LOGIC(msg)
Use NS_LOG to output a message of level LOG_LOGIC.
Definition: log.h:289
#define NS_LOG_FUNCTION(parameters)
If log level LOG_FUNCTION is enabled, this macro will output all input parameters separated by ",...
#define NS_LOG_WARN(msg)
Use NS_LOG to output a message of level LOG_WARN.
Definition: log.h:265
#define NS_LOG_INFO(msg)
Use NS_LOG to output a message of level LOG_INFO.
Definition: log.h:281
#define NS_OBJECT_ENSURE_REGISTERED(type)
Register an Object subclass with the TypeId system.
Definition: object-base.h:45
Every class exported by the ns3 library is enclosed in the ns3 namespace.
static const struct ns3::FfrSoftUplinkDefaultConfiguration g_ffrSoftUplinkDefaultConfiguration[]
the soft uplink default configuration
const uint16_t NUM_DOWNLINK_CONFS(sizeof(g_ffrEnhancedDownlinkDefaultConfiguration)/sizeof(FfrEnhancedDownlinkDefaultConfiguration))
const uint16_t NUM_UPLINK_CONFS(sizeof(g_ffrEnhancedUplinkDefaultConfiguration)/sizeof(FfrEnhancedUplinkDefaultConfiguration))
static const struct ns3::FfrSoftDownlinkDefaultConfiguration g_ffrSoftDownlinkDefaultConfiguration[]
the soft downlink default configuration
Parameters of the LOAD INFORMATION message.
Definition: epc-x2-sap.h:304
Parameters of the SCHED_DL_CQI_INFO_REQ primitive.
Parameters of the SCHED_UL_CQI_INFO_REQ primitive.
uint8_t rsrqResult
the RSRQ result
Definition: lte-rrc-sap.h:639
uint8_t rsrpResult
the RSRP result
Definition: lte-rrc-sap.h:638
MeasResults structure.
Definition: lte-rrc-sap.h:680
uint8_t measId
measure ID
Definition: lte-rrc-sap.h:681
MeasResultPCell measResultPCell
measurement result primary cell
Definition: lte-rrc-sap.h:682
PdschConfigDedicated structure.
Definition: lte-rrc-sap.h:155
Specifies criteria for triggering of an E-UTRA measurement reporting event.
Definition: lte-rrc-sap.h:362
@ EVENT_A1
Event A1: Serving becomes better than absolute threshold.
Definition: lte-rrc-sap.h:373
@ RSRQ
Reference Signal Received Quality.
Definition: lte-rrc-sap.h:407
ThresholdEutra threshold1
Threshold for event A1, A2, A4, and A5.
Definition: lte-rrc-sap.h:381
enum ns3::LteRrcSap::ReportConfigEutra::@67 triggerQuantity
Trigger type enumeration.
enum ns3::LteRrcSap::ReportConfigEutra::@66 eventId
Event enumeration.
enum ns3::LteRrcSap::ReportConfigEutra::@69 reportInterval
Report interval enumeration.
@ THRESHOLD_RSRQ
RSRQ is used for the threshold.
Definition: lte-rrc-sap.h:355
uint8_t range
Value range used in RSRP/RSRQ threshold.
Definition: lte-rrc-sap.h:357
enum ns3::LteRrcSap::ThresholdEutra::@64 choice
Threshold enumeration.