A Discrete-Event Network Simulator
API
lte-enb-rrc.h
Go to the documentation of this file.
1 /* -*- Mode: C++; c-file-style: "gnu"; indent-tabs-mode:nil; -*- */
2 /*
3  * Copyright (c) 2011, 2012 Centre Tecnologic de Telecomunicacions de Catalunya (CTTC)
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  * Authors: Nicola Baldo <nbaldo@cttc.es>
19  * Marco Miozzo <mmiozzo@cttc.es>
20  * Manuel Requena <manuel.requena@cttc.es>
21  * Modified by:
22  * Danilo Abrignani <danilo.abrignani@unibo.it> (Carrier Aggregation - GSoC 2015)
23  * Biljana Bojovic <biljana.bojovic@cttc.es> (Carrier Aggregation)
24  */
25 
26 #ifndef LTE_ENB_RRC_H
27 #define LTE_ENB_RRC_H
28 
29 #include <ns3/nstime.h>
30 #include <ns3/object.h>
31 #include <ns3/traced-callback.h>
32 #include <ns3/event-id.h>
33 
34 #include <ns3/lte-enb-cmac-sap.h>
35 #include <ns3/lte-mac-sap.h>
36 #include <ns3/ff-mac-sched-sap.h>
37 #include <ns3/ff-mac-csched-sap.h>
38 #include <ns3/lte-pdcp-sap.h>
39 #include <ns3/epc-x2-sap.h>
40 #include <ns3/epc-enb-s1-sap.h>
41 #include <ns3/lte-handover-management-sap.h>
42 #include <ns3/lte-ccm-rrc-sap.h>
43 #include <ns3/lte-enb-cphy-sap.h>
44 #include <ns3/lte-rrc-sap.h>
45 #include <ns3/lte-anr-sap.h>
46 #include <ns3/lte-ffr-rrc-sap.h>
47 #include <ns3/lte-rlc.h>
48 
49 #include <map>
50 #include <set>
51 #include <ns3/component-carrier-enb.h>
52 #include <vector>
53 
54 #define MIN_NO_CC 1
55 #define MAX_NO_CC 5 // this is the maximum number of carrier components allowed by 3GPP up to R13
56 
57 namespace ns3 {
58 
59 class LteRadioBearerInfo;
60 class LteSignalingRadioBearerInfo;
61 class LteDataRadioBearerInfo;
62 class LteEnbRrc;
63 class Packet;
64 
65 
66 
72 class UeManager : public Object
73 {
76 
77 public:
78 
79 
84  enum State
85  {
97  };
98 
99  UeManager ();
100 
111  UeManager (Ptr<LteEnbRrc> rrc, uint16_t rnti, State s, uint8_t componentCarrierId);
112 
113  virtual ~UeManager (void);
114 
115  // inherited from Object
116 protected:
117  virtual void DoInitialize ();
118  virtual void DoDispose ();
119 public:
124  static TypeId GetTypeId (void);
125 
133  void SetSource (uint16_t sourceCellId, uint16_t sourceX2apId);
134 
140  void SetImsi (uint64_t imsi);
141 
152  void SetupDataRadioBearer (EpsBearer bearer, uint8_t bearerId, uint32_t gtpTeid, Ipv4Address transportLayerAddress);
153 
160 
166  void StartDataRadioBearers ();
167 
174  void ReleaseDataRadioBearer (uint8_t drbid);
175 
181 
187  void PrepareHandover (uint16_t cellId);
188 
195 
202 
213 
220  void SendData (uint8_t bid, Ptr<Packet> p);
221 
226  std::vector<EpcX2Sap::ErabToBeSetupItem> GetErabList ();
227 
233  void SendUeContextRelease ();
234 
240  void RecvHandoverPreparationFailure (uint16_t cellId);
241 
248 
255 
256 
257  // METHODS FORWARDED FROM ENB RRC SAP ///////////////////////////////////////
258 
294 
295 
296  // METHODS FORWARDED FROM ENB CMAC SAP //////////////////////////////////////
297 
303 
304  // METHODS FORWARDED FROM ENB PDCP SAP //////////////////////////////////////
305 
311 
317  uint16_t GetRnti (void) const;
318 
323  uint64_t GetImsi (void) const;
324 
329  uint8_t GetComponentCarrierId () const;
330 
335  uint16_t GetSrsConfigurationIndex (void) const;
336 
342  void SetSrsConfigurationIndex (uint16_t srsConfIndex);
343 
348  State GetState () const;
349 
356  void SetPdschConfigDedicated (LteRrcSap::PdschConfigDedicated pdschConfigDedicated);
357 
367  typedef void (*StateTracedCallback)
368  (const uint64_t imsi, const uint16_t cellId, const uint16_t rnti,
369  const State oldState, const State newState);
370 
371 private:
372 
380  uint8_t AddDataRadioBearerInfo (Ptr<LteDataRadioBearerInfo> radioBearerInfo);
381 
388 
394  void RemoveDataRadioBearerInfo (uint8_t drbid);
395 
402 
409 
416 
422 
428  uint8_t Lcid2Drbid (uint8_t lcid);
429 
435  uint8_t Drbid2Lcid (uint8_t drbid);
436 
442  uint8_t Lcid2Bid (uint8_t lcid);
443 
449  uint8_t Bid2Lcid (uint8_t bid);
450 
456  uint8_t Drbid2Bid (uint8_t drbid);
457 
463  uint8_t Bid2Drbid (uint8_t bid);
464 
470  void SwitchToState (State s);
471 
473 
478  std::map <uint8_t, Ptr<LteDataRadioBearerInfo> > m_drbMap;
479 
488 
492  uint16_t m_rnti;
497  uint64_t m_imsi;
502 
504 
510 
512 
514 
521 
522  uint16_t m_sourceX2apId;
523  uint16_t m_sourceCellId;
524  uint16_t m_targetCellId;
525  std::list<uint8_t> m_drbsToBeStarted;
527 
561 
564 
567 
568 }; // end of `class UeManager`
569 
570 
571 
577 class LteEnbRrc : public Object
578 {
579 
595  friend class UeManager;
598 
599 public:
604  LteEnbRrc ();
605 
609  virtual ~LteEnbRrc ();
610 
611 
612  // inherited from Object
613 protected:
614  virtual void DoDispose (void);
615 public:
620  static TypeId GetTypeId (void);
621 
627 
633 
634 
641 
648  void SetLteEnbCmacSapProvider (LteEnbCmacSapProvider * s, uint8_t pos);
649 
655 
662 
669 
676 
677 
684 
691 
692 
699 
706 
707 
708 
721  void SetLteFfrRrcSapProvider (LteFfrRrcSapProvider * s, uint8_t index);
722 
735  LteFfrRrcSapUser* GetLteFfrRrcSapUser (uint8_t index);
736 
743 
750 
759 
760 
767 
773 
774 
781 
788  void SetLteEnbCphySapProvider (LteEnbCphySapProvider * s, uint8_t pos);
789 
796 
804 
812  bool HasUeManager (uint16_t rnti) const;
813 
821  Ptr<UeManager> GetUeManager (uint16_t rnti);
822 
836 
860  void ConfigureCell (std::map<uint8_t, Ptr<ComponentCarrierEnb>> ccPhyConf);
861 
866  void ConfigureCarriers (std::map<uint8_t, Ptr<ComponentCarrierEnb>> ccPhyConf);
867 
873  void SetCellId (uint16_t m_cellId);
874 
881  void SetCellId (uint16_t m_cellId, uint8_t ccIndex);
882 
890  uint8_t CellToComponentCarrierId (uint16_t cellId);
891 
899  uint16_t ComponentCarrierToCellId (uint8_t componentCarrierId);
900 
910  bool SendData (Ptr<Packet> p);
911 
917  void SetForwardUpCallback (Callback <void, Ptr<Packet> > cb);
918 
925  void ConnectionRequestTimeout (uint16_t rnti);
926 
934  void ConnectionSetupTimeout (uint16_t rnti);
935 
942  void ConnectionRejectedTimeout (uint16_t rnti);
943 
951  void HandoverJoiningTimeout (uint16_t rnti);
952 
960  void HandoverLeavingTimeout (uint16_t rnti);
961 
970  void SendHandoverRequest (uint16_t rnti, uint16_t cellId);
971 
978  void DoSendReleaseDataRadioBearer (uint64_t imsi, uint16_t rnti, uint8_t bearerId);
979 
987  PER_BASED = 4};
988 
995  typedef void (*NewUeContextTracedCallback)
996  (const uint16_t cellId, const uint16_t rnti);
997 
1005  typedef void (*ConnectionHandoverTracedCallback)
1006  (const uint64_t imsi, const uint16_t cellId, const uint16_t rnti);
1007 
1016  typedef void (*HandoverStartTracedCallback)
1017  (const uint64_t imsi, const uint16_t cellId, const uint16_t rnti,
1018  const uint16_t targetCid);
1019 
1030  typedef void (*ReceiveReportTracedCallback)
1031  (const uint64_t imsi, const uint16_t cellId, const uint16_t rnti,
1032  const LteRrcSap::MeasurementReport report);
1033 
1034 private:
1035 
1036 
1037  // RRC SAP methods
1038 
1086  void DoRecvMeasurementReport (uint16_t rnti, LteRrcSap::MeasurementReport msg);
1087 
1088  // S1 SAP methods
1089 
1102 
1103  // X2 SAP methods
1104 
1153 
1154  // CMAC SAP methods
1155 
1162  uint16_t DoAllocateTemporaryCellRnti (uint8_t componentCarrierId);
1170  void DoNotifyLcConfigResult (uint16_t rnti, uint8_t lcid, bool success);
1177 
1178  // Handover Management SAP methods
1179 
1194 
1201  void DoTriggerHandover (uint16_t rnti, uint16_t targetCellId);
1202 
1203  // ANR SAP methods
1204 
1212 
1213  // FFR RRC SAP methods
1234 
1235  // Internal methods
1236 
1247  uint16_t AddUe (UeManager::State state, uint8_t componentCarrierId);
1248 
1254  void RemoveUe (uint16_t rnti);
1255 
1256 
1263  TypeId GetRlcType (EpsBearer bearer);
1264 
1265 
1266 
1267 public:
1268 
1274  void AddX2Neighbour (uint16_t cellId);
1275 
1280  void SetSrsPeriodicity (uint32_t p);
1281 
1286  uint32_t GetSrsPeriodicity () const;
1287 
1307  void SetCsgId (uint32_t csgId, bool csgIndication);
1308 
1313  void SetNumberOfComponentCarriers (uint16_t numberOfComponentCarriers);
1314 
1315 private:
1316 
1325  uint16_t GetNewSrsConfigurationIndex (void);
1326 
1335  void RemoveSrsConfigurationIndex (uint16_t srcCi);
1336 
1337 
1338 
1346  uint8_t GetLogicalChannelGroup (EpsBearer bearer);
1347 
1356  uint8_t GetLogicalChannelPriority (EpsBearer bearer);
1357 
1358 
1363  void SendSystemInformation ();
1364 
1366 
1371 
1373  std::vector<LteEnbCmacSapUser*> m_cmacSapUser;
1375  std::vector<LteEnbCmacSapProvider*> m_cmacSapProvider;
1376 
1381 
1386 
1391 
1393  std::vector<LteFfrRrcSapUser*> m_ffrRrcSapUser;
1395  std::vector<LteFfrRrcSapProvider*> m_ffrRrcSapProvider;
1396 
1401 
1404 
1409 
1411  std::vector<LteEnbCphySapUser*> m_cphySapUser;
1413  std::vector<LteEnbCphySapProvider*> m_cphySapProvider;
1414 
1418  uint32_t m_dlEarfcn;
1420  uint32_t m_ulEarfcn;
1422  uint16_t m_dlBandwidth;
1424  uint16_t m_ulBandwidth;
1427 
1429  std::vector<LteRrcSap::SystemInformationBlockType1> m_sib1;
1430 
1434  std::map<uint16_t, Ptr<UeManager> > m_ueMap;
1435 
1441 
1443  std::set<uint8_t> m_handoverMeasIds;
1445  std::set<uint8_t> m_anrMeasIds;
1447  std::set<uint8_t> m_ffrMeasIds;
1449  std::set<uint8_t> m_componentCarrierMeasIds;
1450 
1453  {
1454  uint16_t rnti;
1455  uint8_t drbid;
1456  };
1457 
1459  std::map<uint32_t, X2uTeidInfo> m_x2uTeidInfoMap;
1460 
1480  std::set<uint16_t> m_ueSrsConfigurationIndexSet;
1483 
1489  int8_t m_qRxLevMin;
1546 
1577 
1579 
1581 
1582  std::map<uint8_t, Ptr<ComponentCarrierEnb>> m_componentCarrierPhyConf;
1583 
1584 }; // end of `class LteEnbRrc`
1585 
1586 
1587 } // namespace ns3
1588 
1589 #endif // LTE_ENB_RRC_H
Callback< void, Ptr< Packet > > m_forwardUpCallback
forward up callback function
Definition: lte-enb-rrc.h:1365
TracedCallback< uint64_t, uint16_t, uint16_t, State, State > m_stateTransitionTrace
The StateTransition trace source.
Definition: lte-enb-rrc.h:520
uint8_t GetComponentCarrierId() const
TracedCallback< uint64_t, uint16_t, uint16_t > m_handoverEndOkTrace
The HandoverEndOk trace source.
Definition: lte-enb-rrc.h:1571
RrcConnectionRequest structure.
Definition: lte-rrc-sap.h:685
void ConnectionRequestTimeout(uint16_t rnti)
Method triggered when a UE is expected to request for connection but does not do so in a reasonable t...
bool HasUeManager(uint16_t rnti) const
Parameters passed to DataRadioBearerSetupRequest ()
void ConnectionSetupTimeout(uint16_t rnti)
Method triggered when a UE is expected to complete a connection setup procedure but does not do so in...
PhysicalConfigDedicated structure.
Definition: lte-rrc-sap.h:216
Service Access Point (SAP) offered by the Frequency Reuse algorithm instance to the eNodeB RRC instan...
void SetEpcX2SapProvider(EpcX2SapProvider *s)
Set the X2 SAP this RRC should interact with.
Template for the implementation of the EpcEnbS1SapUser as a member of an owner class of type C to whi...
This class implements the Service Access Point (SAP) between the LteEnbRrc and the EpcEnbApplication...
Simulation virtual time values and global simulation resolution.
Definition: nstime.h:102
Ptr< LteSignalingRadioBearerInfo > m_srb1
The Srb1 attribute.
Definition: lte-enb-rrc.h:487
void SendHandoverRequest(uint16_t rnti, uint16_t cellId)
Send a HandoverRequest through the X2 SAP interface.
void SendSystemInformation()
method used to periodically send System Information
LteRrcSap::RadioResourceConfigDedicated GetRadioResourceConfigForHandoverPreparationInfo()
Definition: lte-enb-rrc.cc:685
Smart pointer class similar to boost::intrusive_ptr.
Definition: ptr.h:73
These service primitives of this part of the X2 SAP are provided by the X2 entity and issued by RRC e...
Definition: epc-x2-sap.h:343
LteEnbRrc()
create an RRC instance for use within an eNB
MeasurementReport structure.
Definition: lte-rrc-sap.h:894
Callback template class.
Definition: callback.h:1176
void ConfigureCell(std::map< uint8_t, Ptr< ComponentCarrierEnb >> ccPhyConf)
Configure cell-specific parameters.
EpcX2SpecificEpcX2SapUser.
Definition: epc-x2-sap.h:608
void RecordDataRadioBearersToBeStarted()
Start all configured data radio bearers.
Definition: lte-enb-rrc.cc:468
virtual void DoDispose()
Destructor implementation.
Definition: lte-enb-rrc.cc:306
uint16_t m_dlBandwidth
Downlink transmission bandwidth configuration in number of Resource Blocks.
Definition: lte-enb-rrc.h:1422
bool m_caSupportConfigured
Define if the Carrier Aggregation was already configure for the current UE on not.
Definition: lte-enb-rrc.h:563
void RecvUeContextRelease(EpcX2SapUser::UeContextReleaseParams params)
Take the necessary actions in response to the reception of an X2 UE CONTEXT RELEASE message...
Definition: lte-enb-rrc.cc:838
This class implements the Service Access Point (SAP) between the LteEnbRrc and the EpcEnbApplication...
void SetSource(uint16_t sourceCellId, uint16_t sourceX2apId)
Set the identifiers of the source eNB for the case where a UE joins the current eNB as part of a hand...
Definition: lte-enb-rrc.cc:352
void RecvHandoverPreparationFailure(uint16_t cellId)
Take the necessary actions in response to the reception of an X2 HO preparation failure message...
Definition: lte-enb-rrc.cc:801
void DoNotifyLcConfigResult(uint16_t rnti, uint8_t lcid, bool success)
Notify LC config result function.
void(* NewUeContextTracedCallback)(const uint16_t cellId, const uint16_t rnti)
TracedCallback signature for new Ue Context events.
Definition: lte-enb-rrc.h:996
void SetCellId(uint16_t m_cellId)
set the cell id of this eNB
uint8_t GetLogicalChannelGroup(EpsBearer bearer)
void(* ConnectionHandoverTracedCallback)(const uint64_t imsi, const uint16_t cellId, const uint16_t rnti)
TracedCallback signature for connection and handover end events.
Definition: lte-enb-rrc.h:1006
void AddX2Neighbour(uint16_t cellId)
Add a neighbour with an X2 interface.
uint8_t Drbid2Bid(uint8_t drbid)
bool m_admitHandoverRequest
The AdmitHandoverRequest attribute.
Definition: lte-enb-rrc.h:1494
Parameters of the HANDOVER REQUEST message.
Definition: epc-x2-sap.h:228
Part of the RRC protocol.
Definition: lte-rrc-sap.h:1182
void DoRecvRrcConnectionReconfigurationCompleted(uint16_t rnti, LteRrcSap::RrcConnectionReconfigurationCompleted msg)
Part of the RRC protocol.
Template for the implementation of the LteHandoverManagementSapUser as a member of an owner class of ...
Class for forwarding CMAC SAP User functions.
Definition: lte-enb-rrc.cc:60
Specifies criteria for triggering of an E-UTRA measurement reporting event.
Definition: lte-rrc-sap.h:354
void SetCsgId(uint32_t csgId, bool csgIndication)
Associate this RRC entity with a particular CSG information.
uint16_t GetSrsConfigurationIndex(void) const
uint8_t DoAddUeMeasReportConfigForComponentCarrier(LteRrcSap::ReportConfigEutra reportConfig)
Add UE measure report config for component carrier function.
MeasConfig structure.
Definition: lte-rrc-sap.h:511
X2uTeidInfo structure.
Definition: lte-enb-rrc.h:1452
static TypeId GetTypeId(void)
Get the type ID.
uint16_t m_sourceCellId
source cell ID
Definition: lte-enb-rrc.h:523
virtual ~LteEnbRrc()
Destructor.
uint16_t m_rnti
The C-RNTI attribute.
Definition: lte-enb-rrc.h:492
uint8_t Lcid2Bid(uint8_t lcid)
void SetLteHandoverManagementSapProvider(LteHandoverManagementSapProvider *s)
set the Handover Management SAP this RRC should interact with
EpcX2SapUser * GetEpcX2SapUser()
Get the X2 SAP offered by this RRC.
void SetLteEnbCphySapProvider(LteEnbCphySapProvider *s)
set the CPHY SAP this RRC should use to interact with the PHY
uint16_t m_lastAllocatedRnti
Last allocated RNTI.
Definition: lte-enb-rrc.h:1426
uint16_t GetNewSrsConfigurationIndex(void)
Allocate a new SRS configuration index for a new UE.
LteEnbCmacSapUser * GetLteEnbCmacSapUser()
Get the CMAC SAP offered by this RRC.
std::vector< LteEnbCphySapProvider * > m_cphySapProvider
Interface to the eNodeB PHY instances.
Definition: lte-enb-rrc.h:1413
uint16_t m_ulBandwidth
Uplink transmission bandwidth configuration in number of Resource Blocks.
Definition: lte-enb-rrc.h:1424
uint8_t m_lastRrcTransactionIdentifier
last RRC transaction identifier
Definition: lte-enb-rrc.h:503
uint16_t m_srsCurrentPeriodicityId
The SrsPeriodicity attribute.
Definition: lte-enb-rrc.h:1479
The LTE Radio Resource Control entity at the eNB.
Definition: lte-enb-rrc.h:577
bool m_pendingStartDataRadioBearers
Pending start data radio bearers.
Definition: lte-enb-rrc.h:566
void SetLteEnbRrcSapUser(LteEnbRrcSapUser *s)
set the RRC SAP this RRC should interact with
void SetLteEnbCmacSapProvider(LteEnbCmacSapProvider *s)
set the CMAC SAP this RRC should interact with
uint64_t m_imsi
International Mobile Subscriber Identity assigned to this UE.
Definition: lte-enb-rrc.h:497
std::vector< LteEnbCmacSapProvider * > m_cmacSapProvider
Interface to the eNodeB MAC instance.
Definition: lte-enb-rrc.h:1375
Service Access Point (SAP) offered by the UE PHY to the UE RRC for control purposes.
Time m_handoverLeavingTimeoutDuration
The HandoverLeavingTimeoutDuration attribute.
Definition: lte-enb-rrc.h:1545
Time m_connectionRejectedTimeoutDuration
The ConnectionRejectedTimeoutDuration attribute.
Definition: lte-enb-rrc.h:1530
LteMacSapProvider * m_macSapProvider
Interface to the eNodeB MAC instance, to be used by RLC instances.
Definition: lte-enb-rrc.h:1403
LteHandoverManagementSapUser * GetLteHandoverManagementSapUser()
Get the Handover Management SAP offered by this RRC.
LteEnbRrcSapProvider * m_rrcSapProvider
Interface to receive messages from UE over the RRC protocol.
Definition: lte-enb-rrc.h:1400
void RemoveSrsConfigurationIndex(uint16_t srcCi)
remove a previously allocated SRS configuration index
std::map< uint8_t, Ptr< ComponentCarrierEnb > > m_componentCarrierPhyConf
component carrier phy configuration
Definition: lte-enb-rrc.h:1582
State GetState() const
MemberLteCcmRrcSapUser class.
void SetImsi(uint64_t imsi)
Set the IMSI.
Definition: lte-enb-rrc.cc:359
void SetLteMacSapProvider(LteMacSapProvider *s)
set the MAC SAP provider.
void SendUeContextRelease()
send the UE CONTEXT RELEASE X2 message to the source eNB, thus successfully terminating an X2 handove...
Definition: lte-enb-rrc.cc:777
LteRrcSap::RrcConnectionReconfiguration GetRrcConnectionReconfigurationForHandover()
Definition: lte-enb-rrc.cc:692
void SwitchToState(State s)
Switch the UeManager to the given state.
Time m_connectionSetupTimeoutDuration
The ConnectionSetupTimeoutDuration attribute.
Definition: lte-enb-rrc.h:1525
void RecvRrcConnectionReconfigurationCompleted(LteRrcSap::RrcConnectionReconfigurationCompleted msg)
Implement the LteEnbRrcSapProvider::RecvRrcConnectionReconfigurationCompleted interface.
Definition: lte-enb-rrc.cc:938
void ReleaseDataRadioBearer(uint8_t drbid)
Release a given radio bearer.
Definition: lte-enb-rrc.cc:500
void SetNumberOfComponentCarriers(uint16_t numberOfComponentCarriers)
Set number of component carriers.
uint16_t ComponentCarrierToCellId(uint8_t componentCarrierId)
convert the component carrier id to cell id
uint8_t AddDataRadioBearerInfo(Ptr< LteDataRadioBearerInfo > radioBearerInfo)
Add a new LteDataRadioBearerInfo structure to the UeManager.
EpcX2SapUser * m_x2SapUser
Interface to receive messages from neighbour eNodeB over the X2 interface.
Definition: lte-enb-rrc.h:1368
uint8_t m_rsrqFilterCoefficient
The RsrqFilterCoefficient attribute.
Definition: lte-enb-rrc.h:1511
LteEnbRrcSapUser * m_rrcSapUser
Interface to send messages to UE over the RRC protocol.
Definition: lte-enb-rrc.h:1398
bool m_needPhyMacConfiguration
need Phy MAC configuration
Definition: lte-enb-rrc.h:526
Ptr< LteEnbRrc > m_rrc
Pointer to the parent eNodeB RRC.
Definition: lte-enb-rrc.h:507
EpcEnbS1SapProvider * m_s1SapProvider
Interface to send messages to core network over the S1 protocol.
Definition: lte-enb-rrc.h:1406
Time m_connectionRequestTimeoutDuration
The ConnectionRequestTimeoutDuration attribute.
Definition: lte-enb-rrc.h:1518
void SetForwardUpCallback(Callback< void, Ptr< Packet > > cb)
set the callback used to forward data packets up the stack
void DoRecvRrcConnectionSetupCompleted(uint16_t rnti, LteRrcSap::RrcConnectionSetupCompleted msg)
Part of the RRC protocol.
void DoRecvRrcConnectionReestablishmentComplete(uint16_t rnti, LteRrcSap::RrcConnectionReestablishmentComplete msg)
Part of the RRC protocol.
LteHandoverManagementSapUser * m_handoverManagementSapUser
Receive API calls from the handover algorithm instance.
Definition: lte-enb-rrc.h:1378
void DoCompleteSetupUe(uint16_t rnti, LteEnbRrcSapProvider::CompleteSetupUeParameters params)
Part of the RRC protocol.
TracedCallback< uint16_t, uint16_t > m_newUeContextTrace
The NewUeContext trace source.
Definition: lte-enb-rrc.h:1551
Service Access Point (SAP) offered by the MAC to the RRC See Femto Forum MAC Scheduler Interface Spec...
Template for the implementation of the LteFfrRrcSapUser as a member of an owner class of type C to wh...
Ptr< UeManager > GetUeManager(uint16_t rnti)
Parameters for LtePdcpSapUser::ReceivePdcpSdu.
Definition: lte-pdcp-sap.h:76
This class contains the specification of EPS Bearers.
Definition: eps-bearer.h:71
bool m_admitRrcConnectionRequest
The AdmitRrcConnectionRequest attribute.
Definition: lte-enb-rrc.h:1499
int8_t m_qRxLevMin
The QRxLevMin attribute.
Definition: lte-enb-rrc.h:1489
LtePdcpSapUser * m_drbPdcpSapUser
DRB PDCP SAP user.
Definition: lte-enb-rrc.h:511
uint8_t AddUeMeasReportConfig(LteRrcSap::ReportConfigEutra config)
Add a new UE measurement reporting configuration.
EventId m_connectionRejectedTimeout
The delay before a connection rejected timeout occurs.
Definition: lte-enb-rrc.h:546
void SetLteFfrRrcSapProvider(LteFfrRrcSapProvider *s)
set the FFR SAP this RRC should interact with
uint16_t m_numberOfComponentCarriers
number of component carriers
Definition: lte-enb-rrc.h:1578
std::vector< LteFfrRrcSapProvider * > m_ffrRrcSapProvider
Interface to the FFR algorithm instance.
Definition: lte-enb-rrc.h:1395
LteRrcSap::NonCriticalExtensionConfiguration BuildNonCriticalExtentionConfigurationCa()
bool m_carriersConfigured
are carriers configured
Definition: lte-enb-rrc.h:1580
LteRrcSap::RrcConnectionReconfiguration BuildRrcConnectionReconfiguration()
Ptr< LteSignalingRadioBearerInfo > m_srb0
The Srb0 attribute.
Definition: lte-enb-rrc.h:483
void DoRecvRrcConnectionRequest(uint16_t rnti, LteRrcSap::RrcConnectionRequest msg)
Part of the RRC protocol.
void SetSrsConfigurationIndex(uint16_t srsConfIndex)
Set the SRS configuration index and do the necessary reconfiguration.
void DoTriggerHandover(uint16_t rnti, uint16_t targetCellId)
Trigger handover function.
TracedCallback< uint64_t, uint16_t, uint16_t > m_connectionEstablishedTrace
The ConnectionEstablished trace source.
Definition: lte-enb-rrc.h:1556
std::set< uint8_t > m_componentCarrierMeasIds
List of measurement identities which are intended for component carrier management purposes...
Definition: lte-enb-rrc.h:1449
Parameters of the HANDOVER PREPARATION FAILURE message.
Definition: epc-x2-sap.h:262
void(* HandoverStartTracedCallback)(const uint64_t imsi, const uint16_t cellId, const uint16_t rnti, const uint16_t targetCid)
TracedCallback signature for handover start events.
Definition: lte-enb-rrc.h:1017
uint32_t m_ulEarfcn
Uplink E-UTRA Absolute Radio Frequency Channel Number.
Definition: lte-enb-rrc.h:1420
uint8_t CellToComponentCarrierId(uint16_t cellId)
convert the cell id to component carrier id
void DoPathSwitchRequestAcknowledge(EpcEnbS1SapUser::PathSwitchRequestAcknowledgeParameters params)
Path switch request acknowledge function.
void(* ReceiveReportTracedCallback)(const uint64_t imsi, const uint16_t cellId, const uint16_t rnti, const LteRrcSap::MeasurementReport report)
TracedCallback signature for receive measurement report events.
Definition: lte-enb-rrc.h:1031
RrcConnectionReconfiguration structure.
Definition: lte-rrc-sap.h:829
Parameters of the SN STATUS TRANSFER message.
Definition: epc-x2-sap.h:276
std::set< uint8_t > m_ffrMeasIds
List of measurement identities which are intended for FFR purpose.
Definition: lte-enb-rrc.h:1447
Service Access Point (SAP) offered by the eNodeB RRC instance to the ANR instance.
Definition: lte-anr-sap.h:97
RrcConnectionReconfigurationCompleted structure.
Definition: lte-rrc-sap.h:844
uint8_t Drbid2Lcid(uint8_t drbid)
void SetLteCcmRrcSapProvider(LteCcmRrcSapProvider *s)
set the Component Carrier Management SAP this RRC should interact with
void SendData(uint8_t bid, Ptr< Packet > p)
Send a data packet over the appropriate Data Radio Bearer.
Definition: lte-enb-rrc.cc:699
std::set< uint8_t > m_handoverMeasIds
List of measurement identities which are intended for handover purpose.
Definition: lte-enb-rrc.h:1443
void(* StateTracedCallback)(const uint64_t imsi, const uint16_t cellId, const uint16_t rnti, const State oldState, const State newState)
TracedCallback signature for state transition events.
Definition: lte-enb-rrc.h:368
uint8_t m_componentCarrierId
ID of the primary CC for this UE.
Definition: lte-enb-rrc.h:501
RrcConnectionSetupCompleted structure.
Definition: lte-rrc-sap.h:698
void DoRecvUeContextRelease(EpcX2SapUser::UeContextReleaseParams params)
Receive UE context release function.
uint8_t m_lastAllocatedDrbid
last allocated Data Radio Bearer ID
Definition: lte-enb-rrc.h:472
uint8_t Bid2Lcid(uint8_t bid)
uint16_t m_sourceX2apId
source X2 ap ID
Definition: lte-enb-rrc.h:522
RrcConnectionReestablishmentRequest structure.
Definition: lte-rrc-sap.h:851
std::map< uint32_t, X2uTeidInfo > m_x2uTeidInfoMap
TEID, RNTI, DRBID.
Definition: lte-enb-rrc.h:1459
TracedCallback< uint64_t, uint16_t, uint16_t, LteRrcSap::MeasurementReport > m_recvMeasurementReportTrace
The RecvMeasurementReport trace source.
Definition: lte-enb-rrc.h:1576
virtual ~UeManager(void)
Definition: lte-enb-rrc.cc:301
uint8_t m_rsrpFilterCoefficient
The RsrpFilterCoefficient attribute.
Definition: lte-enb-rrc.h:1505
LteCcmRrcSapUser * m_ccmRrcSapUser
Receive API calls from the LteEnbComponentCarrierManager instance.
Definition: lte-enb-rrc.h:1383
Part of the RRC protocol.
Definition: lte-rrc-sap.h:1063
uint8_t DoAddUeMeasReportConfigForAnr(LteRrcSap::ReportConfigEutra reportConfig)
Add UE measure report config for ANR function.
void SetupDataRadioBearer(EpsBearer bearer, uint8_t bearerId, uint32_t gtpTeid, Ipv4Address transportLayerAddress)
Setup a new data radio bearer, including both the configuration within the eNB and the necessary RRC ...
Definition: lte-enb-rrc.cc:365
void RemoveDataRadioBearerInfo(uint8_t drbid)
remove the LteDataRadioBearerInfo corresponding to a bearer being released
static TypeId GetTypeId(void)
Get the type ID.
Definition: lte-enb-rrc.cc:319
void RecvSnStatusTransfer(EpcX2SapUser::SnStatusTransferParams params)
Take the necessary actions in response to the reception of an X2 SN STATUS TRANSFER message...
Definition: lte-enb-rrc.cc:819
EpcX2SapProvider * m_x2SapProvider
Interface to send messages to neighbour eNodeB over the X2 interface.
Definition: lte-enb-rrc.h:1370
Every class exported by the ns3 library is enclosed in the ns3 namespace.
Parameters of the RESOURCE STATUS UPDATE message.
Definition: epc-x2-sap.h:314
Manages all the radio bearer information possessed by the ENB RRC for a single UE.
Definition: lte-enb-rrc.h:72
LteRrcSap::RadioResourceConfigDedicated BuildRadioResourceConfigDedicated()
LteCcmRrcSapUser * GetLteCcmRrcSapUser()
Get the Component Carrier Management SAP offered by this RRC.
State
The state of the UeManager at the eNB RRC.
Definition: lte-enb-rrc.h:84
EventId m_handoverLeavingTimeout
Time limit before a handover leaving timeout occurs.
Definition: lte-enb-rrc.h:560
void SetLteAnrSapProvider(LteAnrSapProvider *s)
set the ANR SAP this RRC should interact with
Parameters of the UE CONTEXT RELEASE message.
Definition: epc-x2-sap.h:290
Parameters of the HANDOVER REQUEST ACKNOWLEDGE message.
Definition: epc-x2-sap.h:246
void RecvRrcConnectionSetupCompleted(LteRrcSap::RrcConnectionSetupCompleted msg)
Implement the LteEnbRrcSapProvider::RecvRrcConnectionSetupCompleted interface.
Definition: lte-enb-rrc.cc:910
std::list< uint8_t > m_drbsToBeStarted
DRBS to be started.
Definition: lte-enb-rrc.h:525
void DoReceivePdcpSdu(LtePdcpSapUser::ReceivePdcpSduParameters params)
Receive PDCP SDU function.
TracedCallback< uint64_t, uint16_t, uint16_t, uint16_t > m_handoverStartTrace
The HandoverStart trace source.
Definition: lte-enb-rrc.h:1566
std::vector< EpcX2Sap::ErabToBeSetupItem > GetErabList()
Definition: lte-enb-rrc.cc:757
void ScheduleRrcConnectionReconfiguration()
schedule an RRC Connection Reconfiguration procedure with the UE
Definition: lte-enb-rrc.cc:549
These service primitives of this part of the X2 SAP are provided by the RRC entity and issued by the ...
Definition: epc-x2-sap.h:406
LteAnrSapUser * GetLteAnrSapUser()
Get the ANR SAP offered by this RRC.
LtePdcpSpecificLtePdcpSapUser class.
Definition: lte-pdcp-sap.h:132
PathSwitchRequestAcknowledgeParameters structure.
Parameters for [re]configuring the UE.
Time m_systemInformationPeriodicity
The SystemInformationPeriodicity attribute.
Definition: lte-enb-rrc.h:1475
LteEnbRrcSapProvider * GetLteEnbRrcSapProvider()
uint8_t m_defaultTransmissionMode
The DefaultTransmissionMode attribute.
Definition: lte-enb-rrc.h:1465
void DoRecvResourceStatusUpdate(EpcX2SapUser::ResourceStatusUpdateParams params)
Receive resource status update function.
Service Access Point (SAP) offered by the eNodeB RRC instance to the Frequency Reuse algorithm instan...
void DoRecvUeData(EpcX2SapUser::UeDataParams params)
Receive UE data function.
uint64_t GetImsi(void) const
void PrepareHandover(uint16_t cellId)
Start the handover preparation and send the handover request.
Definition: lte-enb-rrc.cc:582
void DoSendReleaseDataRadioBearer(uint64_t imsi, uint16_t rnti, uint8_t bearerId)
This function acts as an interface to trigger Release indication messages towards eNB and EPC...
Definition: lte-enb-rrc.cc:539
uint8_t DoAddUeMeasReportConfigForHandover(LteRrcSap::ReportConfigEutra reportConfig)
Add UE measure report config for handover function.
uint16_t GetRnti(void) const
void RecvRrcConnectionReestablishmentComplete(LteRrcSap::RrcConnectionReestablishmentComplete msg)
Implement the LteEnbRrcSapProvider::RecvRrcConnectionReestablishmentComplete interface.
EpcEnbS1SapUser * m_s1SapUser
Interface to receive messages from core network over the S1 protocol.
Definition: lte-enb-rrc.h:1408
std::set< uint16_t > m_ueSrsConfigurationIndexSet
UE SRS configuration index set.
Definition: lte-enb-rrc.h:1480
void SetSrsPeriodicity(uint32_t p)
virtual void DoDispose(void)
Destructor implementation.
TypeId GetRlcType(EpsBearer bearer)
bool m_configured
True if ConfigureCell() has been completed.
Definition: lte-enb-rrc.h:1416
void HandoverJoiningTimeout(uint16_t rnti)
Method triggered when a UE is expected to join the cell for a handover but does not do so in a reason...
Ipv4 addresses are stored in host order in this class.
Definition: ipv4-address.h:40
std::vector< LteEnbCmacSapUser * > m_cmacSapUser
Receive API calls from the eNodeB MAC instance.
Definition: lte-enb-rrc.h:1373
LteAnrSapUser * m_anrSapUser
Receive API calls from the ANR instance.
Definition: lte-enb-rrc.h:1388
EventId m_connectionSetupTimeout
Time limit before a connection setup timeout occurs.
Definition: lte-enb-rrc.h:540
std::vector< LteRrcSap::SystemInformationBlockType1 > m_sib1
The System Information Block Type 1 that is currently broadcasted over BCH.
Definition: lte-enb-rrc.h:1429
Template for the implementation of the LteEnbRrcSapProvider as a member of an owner class of type C t...
Definition: lte-rrc-sap.h:1605
bool m_pendingRrcConnectionReconfiguration
pending RRC connection reconfiguration
Definition: lte-enb-rrc.h:513
Service Access Point (SAP) offered by the ANR instance to the eNodeB RRC instance.
Definition: lte-anr-sap.h:37
void DoRrcConfigurationUpdateInd(LteEnbCmacSapUser::UeConfig params)
RRC configuration update indication function.
An identifier for simulation events.
Definition: event-id.h:53
void DoSetPdschConfigDedicated(uint16_t rnti, LteRrcSap::PdschConfigDedicated pa)
Set PDSCH config dedicated function.
LteEpsBearerToRlcMapping_t
Identifies how EPS Bearer parameters are mapped to different RLC types.
Definition: lte-enb-rrc.h:984
uint8_t DoAddUeMeasReportConfigForFfr(LteRrcSap::ReportConfigEutra reportConfig)
Add UE measure report config for FFR function.
bool m_reconfigureUes
reconfigure UEs?
Definition: lte-enb-rrc.h:1482
Service Access Point (SAP) offered by the Component Carrier Manager (CCM) instance to the eNodeB RRC ...
void DoRecvHandoverPreparationFailure(EpcX2SapUser::HandoverPreparationFailureParams params)
Receive handover preparation failure function.
Service Access Point (SAP) offered by the handover algorithm instance to the eNodeB RRC instance...
void StartDataRadioBearers()
Start the data radio bearers that have been previously recorded to be started using RecordDataRadioBe...
Definition: lte-enb-rrc.cc:480
Service Access Point (SAP) offered by the PDCP entity to the RRC entity See 3GPP 36.323 Packet Data Convergence Protocol (PDCP) specification.
Definition: lte-pdcp-sap.h:68
EpcEnbS1SapUser * GetS1SapUser()
void RecvRrcConnectionReestablishmentRequest(LteRrcSap::RrcConnectionReestablishmentRequest msg)
Implement the LteEnbRrcSapProvider::RecvRrcConnectionReestablishmentRequest interface.
LteRrcSap::PhysicalConfigDedicated m_physicalConfigDedicated
physical config dedicated
Definition: lte-enb-rrc.h:505
std::map< uint16_t, Ptr< UeManager > > m_ueMap
The UeMap attribute.
Definition: lte-enb-rrc.h:1434
void ConfigureCarriers(std::map< uint8_t, Ptr< ComponentCarrierEnb >> ccPhyConf)
Configure carriers.
LteFfrRrcSapUser * GetLteFfrRrcSapUser()
Get the FFR SAP offered by this RRC.
CompleteSetupUeParameters structure.
Definition: lte-rrc-sap.h:1186
Parameters of the LOAD INFORMATION message.
Definition: epc-x2-sap.h:303
std::vector< LteEnbCphySapUser * > m_cphySapUser
Receive API calls from the eNodeB PHY instances.
Definition: lte-enb-rrc.h:1411
void RecvRrcConnectionRequest(LteRrcSap::RrcConnectionRequest msg)
Implement the LteEnbRrcSapProvider::RecvRrcConnectionRequest interface.
Definition: lte-enb-rrc.cc:857
RrcConnectionReestablishmentComplete structure.
Definition: lte-rrc-sap.h:865
LteCcmRrcSapProvider * m_ccmRrcSapProvider
Interface to the LteEnbComponentCarrierManager instance.
Definition: lte-enb-rrc.h:1385
Service Access Point (SAP) offered by the MAC to the RLC See Femto Forum MAC Scheduler Interface Spec...
Definition: lte-mac-sap.h:36
std::map< uint8_t, Ptr< LteDataRadioBearerInfo > > m_drbMap
The DataRadioBearerMap attribute.
Definition: lte-enb-rrc.h:478
TracedCallback< uint64_t, uint16_t, uint16_t > m_connectionReconfigurationTrace
The ConnectionReconfiguration trace source.
Definition: lte-enb-rrc.h:1561
uint8_t GetLogicalChannelPriority(EpsBearer bearer)
Service Access Point (SAP) offered by the eNodeB RRC instance to the component carrier manager (CCM) ...
uint8_t GetNewRrcTransactionIdentifier()
void DoRecvSnStatusTransfer(EpcX2SapUser::SnStatusTransferParams params)
Receive SN status transfer function.
LteEnbCphySapUser * GetLteEnbCphySapUser()
void ConnectionRejectedTimeout(uint16_t rnti)
Method triggered a while after sending RRC Connection Rejected.
uint32_t GetSrsPeriodicity() const
Ptr< LteDataRadioBearerInfo > GetDataRadioBearerInfo(uint8_t drbid)
Template for the implementation of the LteAnrSapUser as a member of an owner class of type C to which...
Definition: lte-anr-sap.h:205
Time m_handoverJoiningTimeoutDuration
The HandoverJoiningTimeoutDuration attribute.
Definition: lte-enb-rrc.h:1539
uint16_t m_lastAllocatedConfigurationIndex
last allocated configuration index
Definition: lte-enb-rrc.h:1481
void HandoverLeavingTimeout(uint16_t rnti)
Method triggered when a UE is expected to leave a cell for a handover but no feedback is received in ...
LteHandoverManagementSapProvider * m_handoverManagementSapProvider
Interface to the handover algorithm instance.
Definition: lte-enb-rrc.h:1380
A base class which provides memory management and object aggregation.
Definition: object.h:87
std::set< uint8_t > m_anrMeasIds
List of measurement identities which are intended for ANR purpose.
Definition: lte-enb-rrc.h:1445
void DoRecvRrcConnectionReestablishmentRequest(uint16_t rnti, LteRrcSap::RrcConnectionReestablishmentRequest msg)
Part of the RRC protocol.
void SetPdschConfigDedicated(LteRrcSap::PdschConfigDedicated pdschConfigDedicated)
Configure PdschConfigDedicated (i.e.
Service Access Point (SAP) offered by the eNB MAC to the eNB RRC See Femto Forum MAC Scheduler Interf...
NonCriticalExtensionConfiguration structure.
Definition: lte-rrc-sap.h:822
Service Access Point (SAP) offered by the UE PHY to the UE RRC for control purposes.
void RemoveUe(uint16_t rnti)
remove a UE from the cell
PdschConfigDedicated structure.
Definition: lte-rrc-sap.h:154
State m_state
The current UeManager state.
Definition: lte-enb-rrc.h:509
void DoRecvMeasurementReport(uint16_t rnti, LteRrcSap::MeasurementReport msg)
Part of the RRC protocol.
void CmacUeConfigUpdateInd(LteEnbCmacSapUser::UeConfig cmacParams)
CMAC UE config update indication function.
Parameters of the UE DATA primitive.
Definition: epc-x2-sap.h:328
enum LteEpsBearerToRlcMapping_t m_epsBearerToRlcMapping
The EpsBearerToRlcMapping attribute.
Definition: lte-enb-rrc.h:1470
uint32_t m_dlEarfcn
Downlink E-UTRA Absolute Radio Frequency Channel Number.
Definition: lte-enb-rrc.h:1418
void DoSendLoadInformation(EpcX2Sap::LoadInformationParams params)
Send load information function.
void RecvMeasurementReport(LteRrcSap::MeasurementReport msg)
Implement the LteEnbRrcSapProvider::RecvMeasurementReport interface.
a unique identifier for an interface.
Definition: type-id.h:58
uint16_t m_targetCellId
target cell ID
Definition: lte-enb-rrc.h:524
uint16_t DoAllocateTemporaryCellRnti(uint8_t componentCarrierId)
Allocate temporary cell RNTI function.
uint8_t Bid2Drbid(uint8_t bid)
void SetS1SapProvider(EpcEnbS1SapProvider *s)
Set the S1 SAP Provider.
uint8_t Lcid2Drbid(uint8_t lcid)
EventId m_connectionRequestTimeout
Time limit before a connection request timeout occurs.
Definition: lte-enb-rrc.h:534
LteAnrSapProvider * m_anrSapProvider
Interface to the ANR instance.
Definition: lte-enb-rrc.h:1390
uint16_t AddUe(UeManager::State state, uint8_t componentCarrierId)
Allocate a new RNTI for a new UE.
Service Access Point (SAP) offered by the eNodeB RRC instance to the handover algorithm instance...
void DoDataRadioBearerSetupRequest(EpcEnbS1SapUser::DataRadioBearerSetupRequestParameters params)
Data radio beaerer setup request function.
std::vector< LteFfrRrcSapUser * > m_ffrRrcSapUser
Receive API calls from the FFR algorithm instance.
Definition: lte-enb-rrc.h:1393
void DoRecvLoadInformation(EpcX2SapUser::LoadInformationParams params)
Receive load information function.
void RecvHandoverRequestAck(EpcX2SapUser::HandoverRequestAckParams params)
take the necessary actions in response to the reception of an X2 HANDOVER REQUEST ACK message ...
Definition: lte-enb-rrc.cc:638
bool SendData(Ptr< Packet > p)
Enqueue an IP data packet on the proper bearer for downlink transmission.
EventId m_handoverJoiningTimeout
Time limit before a handover joining timeout occurs.
Definition: lte-enb-rrc.h:553
void CompleteSetupUe(LteEnbRrcSapProvider::CompleteSetupUeParameters params)
Implement the LteEnbRrcSapProvider::CompleteSetupUe interface.
Definition: lte-enb-rrc.cc:849
RadioResourceConfigDedicated structure.
Definition: lte-rrc-sap.h:278
virtual void DoInitialize()
Initialize() implementation.
Definition: lte-enb-rrc.cc:163
LteRrcSap::MeasConfig m_ueMeasConfig
List of measurement configuration which are active in every UE attached to this eNodeB instance...
Definition: lte-enb-rrc.h:1440
void DoRecvHandoverRequestAck(EpcX2SapUser::HandoverRequestAckParams params)
Receive handover request acknowledge function.
void DoRecvHandoverRequest(EpcX2SapUser::HandoverRequestParams params)
Receive handover request function.