|
A Discrete-Event Network Simulator
|
API
|
Go to the documentation of this file.
30 #include <ns3/object.h>
31 #include <ns3/packet.h>
32 #include <ns3/lte-ue-cmac-sap.h>
33 #include <ns3/lte-pdcp-sap.h>
34 #include <ns3/lte-as-sap.h>
35 #include <ns3/lte-ue-cphy-sap.h>
36 #include <ns3/lte-rrc-sap.h>
37 #include <ns3/traced-callback.h>
38 #include "ns3/component-carrier-ue.h"
39 #include <ns3/lte-ue-ccm-rrc-sap.h>
46 #define MAX_NO_CC 5 // this is the maximum number of carrier components allowed by 3GPP up to R13
334 (uint64_t imsi, uint16_t cellId);
344 (uint64_t imsi, uint16_t cellId, uint16_t rnti);
356 (uint64_t imsi, uint16_t cellId, uint16_t rnti, uint16_t otherCid);
368 (uint64_t imsi, uint16_t cellId, uint16_t rnti,
391 (uint64_t imsi, uint16_t rnti, uint16_t cellId, std::string type, uint16_t count);
403 (uint64_t imsi, uint16_t cellId, uint16_t rnti, uint8_t count);
643 bool useLayer3Filtering);
662 bool useLayer3Filtering, uint16_t componentCarrierId);
813 std::map <uint8_t, Ptr<LteDataRadioBearerInfo> >
m_drbMap;
1047 bool reportOnLeave);
1350 #endif // LTE_UE_RRC_H
uint16_t GetPreviousCellId() const
Get the previous cell id.
a unique identifier for an interface.
store information on active signaling radio bearer instance
void DoSetCsgWhiteList(uint32_t csgId)
Set CSG white list function.
LteAsSapProvider * m_asSapProvider
AS SAP provider.
TracedCallback< Ptr< LteUeRrc >, std::list< LteRrcSap::SCellToAddMod > > m_sCarrierConfiguredTrace
The SCarrierConfigured trace source.
void DoNotifyOutOfSync()
Do notify out of sync function.
void DoResetSyncIndicationCounter()
Do reset sync indication counter function.
TracedCallback< uint64_t, uint16_t, uint16_t, State, State > m_stateTransitionTrace
The StateTransition trace source.
TracedCallback< uint64_t, uint16_t, uint16_t, uint16_t > m_sib1ReceivedTrace
The Sib1Received trace source.
Template for the implementation of the LteAsSapProvider as a member of an owner class of type C to wh...
Service Access Point (SAP) offered by the MAC to the RLC See Femto Forum MAC Scheduler Interface Spec...
LteRrcSap::QuantityConfig quantityConfig
quantity config
EventId m_radioLinkFailureDetected
Time limit (given by m_t310) before the radio link is considered to have failed.
RrcConnectionRelease structure.
An identifier for simulation events.
void(* StateTracedCallback)(uint64_t imsi, uint16_t cellId, uint16_t rnti, State oldState, State newState)
TracedCallback signature for state transition events.
uint16_t m_cellId
The CellId attribute.
LteAsSapProvider * GetAsSapProvider()
Part of the RRC protocol.
LteMacSapProvider * m_macSapProvider
MAC SAP provider.
State
The states of the UE RRC entity.
Part of the RRC protocol.
friend class UeRrcMemberLteEnbCmacSapUser
allow UeRrcMemberLteEnbCmacSapUser class friend access
std::map< uint8_t, LteRrcSap::MeasObjectToAddMod > measObjectList
measure object list
Every class exported by the ns3 library is enclosed in the ns3 namespace.
LtePdcpSapUser * m_drbPdcpSapUser
DRB PDCP SAP user.
LtePdcpSpecificLtePdcpSapUser class.
void DoDisconnect()
Disconnect function.
Ptr< LteSignalingRadioBearerInfo > m_srb1
The Srb1 attribute.
uint8_t GetDlBandwidth() const
void SaveScellUeMeasurements(uint16_t cellId, double rsrp, double rsrq, bool useLayer3Filtering, uint16_t componentCarrierId)
keep the given measurement result as the latest measurement figures, to be utilised by UE RRC functio...
Time MicroSeconds(uint64_t value)
Construct a Time in the indicated unit.
bool m_hasReceivedMib
True if MIB was received for the current cell.
VarMeasConfig m_varMeasConfig
Includes the accumulated configuration of the measurements to be performed by the UE.
Template for the implementation of the LteUeCphySapUser as a member of an owner class of type C to wh...
TracedCallback< uint64_t, uint16_t > m_initialCellSelectionEndErrorTrace
The InitialCellSelectionEndError trace source.
void(* SCarrierConfiguredTracedCallback)(Ptr< LteUeRrc >, std::list< LteRrcSap::SCellToAddMod >)
TracedCallback signature for secondary carrier configuration events.
bool m_useRlcSm
True if RLC SM is to be used, false if RLC UM/AM are to be used.
bool m_hasReceivedSib2
True if SIB2 was received for the current cell.
std::map< uint16_t, MeasValues > m_storedMeasValues
Internal storage of the latest measurement results from all detected detected cells,...
Represents a single triggered event from a measurement identity which reporting criteria have been fu...
uint16_t m_numberOfComponentCarriers
The number of component carriers.
TracedCallback< uint64_t, uint16_t, uint16_t, uint16_t > m_mibReceivedTrace
The MibReceived trace source.
uint32_t m_dlEarfcn
Downlink carrier frequency.
LteUeCmacSapUser * GetLteUeCmacSapUser()
This function is overloaded to maintain backward compatibility.
CompleteSetupParameters structure.
virtual ~LteUeRrc()
Destructor.
EventId periodicReportTimer
periodic report timer
LteUeRrcSapProvider * m_rrcSapProvider
RRC SAP provider.
Service Access Point (SAP) offered by the UE PHY to the UE RRC for control purposes.
void DoSetNumberOfComponentCarriers(uint16_t noOfComponentCarriers)
RRC CCM SAP USER Method.
RrcConnectionReject structure.
void(* ImsiCidRntiCountTracedCallback)(uint64_t imsi, uint16_t cellId, uint16_t rnti, uint8_t count)
TracedCallback signature for imsi, cellId, rnti and counter for random access events.
uint8_t measId
The measurement identity which raised the trigger.
void DoRecvSystemInformation(LteRrcSap::SystemInformation msg)
Part of the RRC protocol.
TracedCallback< uint64_t, uint16_t, uint16_t, std::string, uint8_t > m_phySyncDetectionTrace
The 'PhySyncDetection' trace source.
uint32_t m_csgWhiteList
List of CSG ID which this UE entity has access to.
RrcConnectionSetup structure.
Parameters for LtePdcpSapUser::ReceivePdcpSdu.
uint16_t m_dlBandwidth
Downlink bandwidth in RBs.
uint32_t GetUlEarfcn() const
TracedCallback< uint64_t, uint16_t, uint16_t, uint16_t > m_handoverStartTrace
The HandoverStart trace source.
Includes the accumulated configuration of the measurements to be performed by the UE.
void InitializeSap(void)
Initiaize SAP.
TracedCallback< uint64_t, uint16_t, uint16_t > m_handoverEndErrorTrace
The HandoverEndError trace source.
void StorePreviousCellId(uint16_t cellId)
Store the previous cell id.
TracedCallback< uint64_t, uint16_t, uint16_t > m_randomAccessSuccessfulTrace
The RandomAccessSuccessful trace source.
Time m_t310
The 'T310' attribute.
std::map< uint8_t, VarMeasReport > m_varMeasReportList
The list of active reporting entries, indexed by the measurement identity which triggered the reporti...
static TypeId GetTypeId(void)
Get the type ID.
std::map< uint8_t, Ptr< LteDataRadioBearerInfo > > m_drbMap
The DataRadioBearerMap attribute.
std::vector< LteUeCmacSapProvider * > m_cmacSapProvider
UE CMac SAP provider.
std::vector< LteUeCphySapProvider * > m_cphySapProvider
UE CPhy SAP provider.
LteUeCcmRrcSapUser * m_ccmRrcSapUser
CCM RRC SAP user.
bool m_connectionPending
True if a connection request by upper layers is pending.
uint32_t numberOfReportsSent
number of reports sent
Ptr< LteSignalingRadioBearerInfo > m_srb1Old
SRB1 configuration before RRC connection reconfiguration.
uint16_t m_previousCellId
the cell id of the previous cell UE was attached to
void EvaluateCellForSelection()
Performs cell selection evaluation to the current serving cell.
void DoNotifyInSync()
Do notify in sync function.
bool m_hasReceivedSib1
True if SIB1 was received for the current cell.
double rsrq
Measured RSRQ in dB.
void DoCompleteSetup(LteUeRrcSapProvider::CompleteSetupParameters params)
Part of the RRC protocol.
Smart pointer class similar to boost::intrusive_ptr.
LteUeCphySapUser * GetLteUeCphySapUser()
LteUeCcmRrcSapUser * GetLteCcmRrcSapUser()
Get the Component Carrier Management SAP offered by this RRC.
void VarMeasReportListAdd(uint8_t measId, ConcernedCells_t enteringCells)
Compose a new reporting entry of the given measurement identity, insert it into m_varMeasReportList,...
void DoStartCellSelection(uint32_t dlEarfcn)
Start cell selection function.
@ CONNECTED_REESTABLISHING
PdschConfigDedicated structure.
std::list< LteRrcSap::SCellToAddMod > m_sCellToAddModList
Secondary carriers.
uint32_t GetDlEarfcn() const
void DoForceCampedOnEnb(uint16_t cellId, uint32_t dlEarfcn)
Force camped on ENB function.
TracedCallback< uint64_t, uint16_t, uint16_t > m_srb1CreatedTrace
The Srb1Created trace source.
This abstract base class defines the API to interact with the Radio Link Control (LTE_RLC) in LTE,...
UeMemberLteUeCmacSapUser class.
void SetUseRlcSm(bool val)
TracedCallback< uint64_t, uint16_t, uint16_t > m_connectionReconfigurationTrace
The ConnectionReconfiguration trace source.
void VarMeasReportListClear(uint8_t measId)
Remove the reporting entry of the given measurement identity from m_varMeasReportList.
std::map< uint16_t, std::map< uint8_t, MeasValues > > m_storedMeasValuesPerCarrier
Stored measure values per carrier.
std::map< uint8_t, std::list< PendingTrigger_t > > m_enteringTriggerQueue
List of triggers that were raised because entering condition have been true, but are still delayed fr...
LteRrcSap::SystemInformationBlockType1 m_lastSib1
Stored content of the last SIB1 received.
void ApplyRadioResourceConfigDedicated(LteRrcSap::RadioResourceConfigDedicated rrcd)
Apply radio resource config dedicated.
void SetLteUeCphySapProvider(LteUeCphySapProvider *s)
set the CPHY SAP this RRC should use to interact with the PHY
uint8_t m_noOfSyncIndications
number of in-sync or out-of-sync indications coming from PHY layer
Service Access Point (SAP) offered by the UE RRC to the UE CCM.
TracedCallback< uint64_t, uint16_t, uint16_t > m_connectionEstablishedTrace
The ConnectionEstablished trace source.
A base class which provides memory management and object aggregation.
RrcConnectionReestablishmentReject structure.
This class implements the Access Stratum (AS) Service Access Point (SAP), i.e., the interface between...
bool m_leaveConnectedMode
true if UE NAS ask UE RRC to leave connected mode, e.g., after RLF, i.e. T310 has expired
Template for the implementation of the LteUeRrcSapProvider as a member of an owner class of type C to...
uint16_t m_rnti
The C-RNTI attribute.
EventId timer
The pending reporting event, scheduled at the end of the time-to-trigger.
UeMeasurementsParameters structure.
void DoRecvMasterInformationBlock(uint16_t cellId, LteRrcSap::MasterInformationBlock msg)
Receive master information block function.
LteUeRrcSapUser * m_rrcSapUser
RRC SAP user.
void DoRecvRrcConnectionReestablishment(LteRrcSap::RrcConnectionReestablishment msg)
Part of the RRC protocol.
void SetLteMacSapProvider(LteMacSapProvider *s)
set the MAC SAP provider.
void DoRecvRrcConnectionSetup(LteRrcSap::RrcConnectionSetup msg)
Part of the RRC protocol.
void CancelLeavingTrigger(uint8_t measId)
Clear all the waiting triggers in m_leavingTriggerQueue which are associated with the given measureme...
uint16_t GetCellId() const
void LeaveConnectedMode()
Leave connected mode method Resets the UE back to an appropiate state depending on the nature of caus...
uint64_t GetImsi(void) const
Simulation virtual time values and global simulation resolution.
void SwitchToState(State s)
Switch the UE RRC to the given state.
RrcConnectionReestablishment structure.
void SetLteUeRrcSapUser(LteUeRrcSapUser *s)
set the RRC SAP this RRC should interact with
MemberLteUeCcmRrcSapUser class.
TracedCallback< uint64_t, uint16_t, uint16_t > m_handoverEndOkTrace
The HandoverEndOk trace source.
This class implements the Access Stratum (AS) Service Access Point (SAP), i.e., the interface between...
uint8_t m_connEstFailCount
the counter to count T300 timer expiration
uint8_t GetUlBandwidth() const
void DoRecvRrcConnectionReestablishmentReject(LteRrcSap::RrcConnectionReestablishmentReject msg)
Part of the RRC protocol.
store information on active data radio bearer instance
TracedCallback< uint64_t, uint16_t, uint16_t > m_radioLinkFailureTrace
The 'RadioLinkFailure' trace source.
void DoRecvRrcConnectionRelease(LteRrcSap::RrcConnectionRelease msg)
Part of the RRC protocol.
uint8_t m_connEstFailCountLimit
the counter value for T300 timer expiration received from the eNB
TracedCallback< uint64_t, uint16_t, uint16_t > m_sib2ReceivedTrace
The Sib2Received trace source.
QuantityConfig structure.
Service Access Point (SAP) offered by the UE PHY to the UE RRC for control purposes.
void StartConnection()
Start connection function.
void DisposeOldSrb1()
Dispose old SRB1.
uint16_t m_ulBandwidth
Uplink bandwidth in RBs.
TracedCallback< uint64_t, uint16_t, uint16_t, uint8_t > m_drbCreatedTrace
The DrbCreated trace source.
Represents a measurement result from a certain cell.
void DoRecvRrcConnectionReconfiguration(LteRrcSap::RrcConnectionReconfiguration msg)
Part of the RRC protocol.
static const Time UE_MEASUREMENT_REPORT_DELAY
Artificial delay of UE measurements procedure.
uint32_t m_ulEarfcn
Uplink carrier frequency.
void SetLteUeCmacSapProvider(LteUeCmacSapProvider *s)
set the CMAC SAP this RRC should interact with
uint8_t m_n310
The 'N310' attribute.
void(* CellSelectionTracedCallback)(uint64_t imsi, uint16_t cellId)
TracedCallback signature for imsi, cellId and rnti events.
std::set< uint16_t > cellsTriggeredList
note: only E-UTRA is supported.
void(* MibSibHandoverTracedCallback)(uint64_t imsi, uint16_t cellId, uint16_t rnti, uint16_t otherCid)
TracedCallback signature for MIBRecieved, Sib1Received and HandoverStart events.
void ConnectionTimeout()
Invoked after timer T300 expires, notifying upper layers that RRC connection establishment procedure ...
void DoNotifyRandomAccessFailed()
Notify random access failed function.
Service Access Point (SAP) offered by the UE MAC to the UE RRC.
ConcernedCells_t concernedCells
The list of cells responsible for this trigger.
TracedCallback< uint64_t, uint16_t > m_initialCellSelectionEndOkTrace
The InitialCellSelectionEndOk trace source.
void(* ImsiCidRntiTracedCallback)(uint64_t imsi, uint16_t cellId, uint16_t rnti)
TracedCallback signature for imsi, cellId and rnti events.
LteAsSapUser * m_asSapUser
AS SAP user.
Service Access Point (SAP) offered by the UE component carrier manager to the UE RRC.
std::map< uint8_t, std::list< PendingTrigger_t > > m_leavingTriggerQueue
List of triggers that were raised because leaving condition have been true, but are still delayed fro...
uint8_t m_n311
The 'N311' attribute.
std::set< uint16_t > m_acceptableCell
List of cell ID of acceptable cells for cell selection that have been detected.
uint8_t m_lastRrcTransactionIdentifier
last RRC transaction identifier
std::list< uint16_t > ConcernedCells_t
List of cell IDs which are responsible for a certain trigger.
void CancelEnteringTrigger(uint8_t measId)
Clear all the waiting triggers in m_enteringTriggerQueue which are associated with the given measurem...
TracedCallback< uint64_t, uint16_t, uint16_t > m_randomAccessErrorTrace
The RandomAccessError trace source.
uint8_t Bid2Drbid(uint8_t bid)
Bid 2 DR bid.
State m_state
The current UE RRC state.
TracedCallback< uint64_t, uint16_t, uint16_t, uint8_t > m_connectionTimeoutTrace
The ConnectionTimeout trace source.
void DoReportUeMeasurements(LteUeCphySapUser::UeMeasurementsParameters params)
Report UE measurements function.
RrcConnectionReconfiguration structure.
void ApplyMeasConfig(LteRrcSap::MeasConfig mc)
Update the current measurement configuration m_varMeasConfig.
void VarMeasReportListErase(uint8_t measId, ConcernedCells_t leavingCells, bool reportOnLeave)
Remove some cells from an existing reporting entry in m_varMeasReportList.
Service Access Point (SAP) offered by the UE MAC to the UE RRC.
std::vector< LteUeCphySapUser * > m_cphySapUser
UE CPhy SAP user.
std::map< uint16_t, MeasValues > m_storedScellMeasValues
Internal storage of the latest measurement results from all detected detected Secondary carrier compo...
LteUeRrcSapProvider * GetLteUeRrcSapProvider()
std::map< uint8_t, LteRrcSap::ReportConfigToAddMod > reportConfigList
report config list
EventId m_connectionTimeout
Invokes ConnectionEstablishmentTimeout() if RRC connection establishment procedure for this UE takes ...
void SaveUeMeasurements(uint16_t cellId, double rsrp, double rsrq, bool useLayer3Filtering)
Keep the given measurement result as the latest measurement figures, to be utilised by UE RRC functio...
void SendMeasurementReport(uint8_t measId)
Produce a proper measurement report from the given measurement identity's reporting entry in m_varMea...
std::vector< LteUeCmacSapUser * > m_cmacSapUser
UE CMac SAP user.
virtual void DoDispose(void)
Destructor implementation.
uint64_t m_imsi
The unique UE identifier.
double rsrp
Measured RSRP in dBm.
void DoSendData(Ptr< Packet > packet, uint8_t bid)
Send data function.
Time m_t300
The T300 attribute.
LteUeRrc()
create an RRC instance for use within an ue
void SetLteCcmRrcSapProvider(LteUeCcmRrcSapProvider *s)
set the Component Carrier Management SAP this RRC should interact with
void SetImsi(uint64_t imsi)
void DoSetTemporaryCellRnti(uint16_t rnti)
Set temporary cell rnti function.
void DoNotifyRandomAccessSuccessful()
Notify random access successful function.
NonCriticalExtensionConfiguration structure.
void ResetRlfParams()
Reset radio link failure parameters.
void DoReceivePdcpSdu(LtePdcpSapUser::ReceivePdcpSduParameters params)
Receive PDCP SDU function.
void DoRecvRrcConnectionReject(LteRrcSap::RrcConnectionReject msg)
Part of the RRC protocol.
std::map< uint8_t, LteRrcSap::MeasIdToAddMod > measIdList
measure ID list
Service Access Point (SAP) offered by the PDCP entity to the RRC entity See 3GPP 36....
void SetAsSapUser(LteAsSapUser *s)
Set the AS SAP user to interact with the NAS entity.
std::map< uint8_t, uint8_t > m_bid2DrbidMap
bid to DR bid map
RadioResourceConfigDedicated structure.
Ptr< LteSignalingRadioBearerInfo > m_srb0
The Srb0 attribute.
LteUeCcmRrcSapProvider * m_ccmRrcSapProvider
Interface to the LteUeComponentCarrierManage instance.
void DoRecvSystemInformationBlockType1(uint16_t cellId, LteRrcSap::SystemInformationBlockType1 msg)
Receive system information block type 1 function.
virtual void DoInitialize(void)
Initialize() implementation.
void(* PhySyncDetectionTracedCallback)(uint64_t imsi, uint16_t rnti, uint16_t cellId, std::string type, uint16_t count)
TracedCallback signature for in-sync and out-of-sync detection events.
void SynchronizeToStrongestCell()
Go through the list of measurement results, choose the one with the strongest RSRP,...
void ApplyRadioResourceConfigDedicatedSecondaryCarrier(LteRrcSap::NonCriticalExtensionConfiguration nonCec)
Apply radio resource config dedicated secondary carrier.
Represents a single measurement reporting entry., which includes information about a measurement for ...
void RadioLinkFailureDetected()
Radio link failure detected function.
LteRrcSap::PdschConfigDedicated m_pdschConfigDedicated
the PDSCH condig dedicated
void MeasurementReportTriggering(uint8_t measId)
Evaluate the reporting criteria of a measurement identity and invoke some reporting actions based on ...
void DoConnect()
Connect function.