A Discrete-Event Network Simulator
API
Loading...
Searching...
No Matches
lte-ue-cmac-sap.h
Go to the documentation of this file.
1/*
2 * Copyright (c) 2011 Centre Tecnologic de Telecomunicacions de Catalunya (CTTC)
3 *
4 * SPDX-License-Identifier: GPL-2.0-only
5 *
6 * Author: Nicola Baldo <nbaldo@cttc.es>
7 */
8
9#ifndef LTE_UE_CMAC_SAP_H
10#define LTE_UE_CMAC_SAP_H
11
12#include <ns3/packet.h>
13
14namespace ns3
15{
16
17class LteMacSapUser;
18
19/**
20 * Service Access Point (SAP) offered by the UE MAC to the UE RRC
21 *
22 * This is the MAC SAP Provider, i.e., the part of the SAP that contains the MAC methods called by
23 * the RRC
24 */
26{
27 public:
28 virtual ~LteUeCmacSapProvider();
29
30 /// RachConfig structure
32 {
33 uint8_t numberOfRaPreambles; ///< number of RA preambles
34 uint8_t preambleTransMax; ///< preamble transmit maximum
35 uint8_t raResponseWindowSize; ///< RA response window size
36 uint8_t connEstFailCount; ///< the counter value for T300 timer expiration
37 };
38
39 /**
40 * Configure RACH function
41 *
42 * \param rc the RACH config
43 */
44 virtual void ConfigureRach(RachConfig rc) = 0;
45
46 /**
47 * tell the MAC to start a contention-based random access procedure,
48 * e.g., to perform RRC connection establishment
49 *
50 */
52
53 /**
54 * tell the MAC to start a non-contention-based random access
55 * procedure, e.g., as a consequence of handover
56 *
57 * \param rnti
58 * \param rapId Random Access Preamble Identifier
59 * \param prachMask
60 */
62 uint8_t rapId,
63 uint8_t prachMask) = 0;
64
65 /// LogicalChannelConfig structure
67 {
68 uint8_t priority; ///< priority
69 uint16_t prioritizedBitRateKbps; ///< prioritize bit rate Kbps
70 uint16_t bucketSizeDurationMs; ///< bucket size duration ms
71 uint8_t logicalChannelGroup; ///< logical channel group
72 };
73
74 /**
75 * add a new Logical Channel (LC)
76 *
77 * \param lcId the ID of the LC
78 * \param lcConfig the LC configuration provided by the RRC
79 * \param msu the corresponding LteMacSapUser
80 */
81 virtual void AddLc(uint8_t lcId, LogicalChannelConfig lcConfig, LteMacSapUser* msu) = 0;
82
83 /**
84 * remove an existing LC
85 *
86 * \param lcId
87 */
88 virtual void RemoveLc(uint8_t lcId) = 0;
89
90 /**
91 * reset the MAC
92 *
93 */
94 virtual void Reset() = 0;
95
96 /**
97 *
98 * \param rnti the cell-specific UE identifier
99 */
100 virtual void SetRnti(uint16_t rnti) = 0;
101
102 /**
103 * \brief Notify MAC about the successful RRC connection
104 * establishment.
105 */
106 virtual void NotifyConnectionSuccessful() = 0;
107
108 /**
109 * \brief A method call by UE RRC to communicate the IMSI to the UE MAC
110 * \param imsi the IMSI of the UE
111 */
112 virtual void SetImsi(uint64_t imsi) = 0;
113};
114
115/**
116 * Service Access Point (SAP) offered by the UE MAC to the UE RRC
117 *
118 * This is the MAC SAP User, i.e., the part of the SAP that contains the RRC methods called by the
119 * MAC
120 */
122{
123 public:
124 virtual ~LteUeCmacSapUser();
125
126 /**
127 *
128 *
129 * \param rnti the T-C-RNTI, which will eventually become the C-RNTI after contention resolution
130 */
131 virtual void SetTemporaryCellRnti(uint16_t rnti) = 0;
132
133 /**
134 * Notify the RRC that the MAC Random Access procedure completed successfully
135 *
136 */
138
139 /**
140 * Notify the RRC that the MAC Random Access procedure failed
141 *
142 */
143 virtual void NotifyRandomAccessFailed() = 0;
144};
145
146} // namespace ns3
147
148#endif // LTE_UE_CMAC_SAP_H
Service Access Point (SAP) offered by the MAC to the RLC See Femto Forum MAC Scheduler Interface Spec...
Definition lte-mac-sap.h:85
Service Access Point (SAP) offered by the UE MAC to the UE RRC.
virtual void NotifyConnectionSuccessful()=0
Notify MAC about the successful RRC connection establishment.
virtual void SetRnti(uint16_t rnti)=0
virtual void RemoveLc(uint8_t lcId)=0
remove an existing LC
virtual void AddLc(uint8_t lcId, LogicalChannelConfig lcConfig, LteMacSapUser *msu)=0
add a new Logical Channel (LC)
virtual void SetImsi(uint64_t imsi)=0
A method call by UE RRC to communicate the IMSI to the UE MAC.
virtual void ConfigureRach(RachConfig rc)=0
Configure RACH function.
virtual void StartContentionBasedRandomAccessProcedure()=0
tell the MAC to start a contention-based random access procedure, e.g., to perform RRC connection est...
virtual void StartNonContentionBasedRandomAccessProcedure(uint16_t rnti, uint8_t rapId, uint8_t prachMask)=0
tell the MAC to start a non-contention-based random access procedure, e.g., as a consequence of hando...
virtual void Reset()=0
reset the MAC
Service Access Point (SAP) offered by the UE MAC to the UE RRC.
virtual void NotifyRandomAccessFailed()=0
Notify the RRC that the MAC Random Access procedure failed.
virtual void NotifyRandomAccessSuccessful()=0
Notify the RRC that the MAC Random Access procedure completed successfully.
virtual void SetTemporaryCellRnti(uint16_t rnti)=0
Every class exported by the ns3 library is enclosed in the ns3 namespace.
uint16_t prioritizedBitRateKbps
prioritize bit rate Kbps
uint16_t bucketSizeDurationMs
bucket size duration ms
uint8_t logicalChannelGroup
logical channel group
uint8_t raResponseWindowSize
RA response window size.
uint8_t connEstFailCount
the counter value for T300 timer expiration
uint8_t preambleTransMax
preamble transmit maximum
uint8_t numberOfRaPreambles
number of RA preambles