A Discrete-Event Network Simulator
API
Loading...
Searching...
No Matches
lte-control-messages.h
Go to the documentation of this file.
1/*
2 * Copyright (c) 2010 TELEMATICS LAB, DEE - Politecnico di Bari
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: Giuseppe Piro <g.piro@poliba.it>
18 * Author: Marco Miozzo <marco.miozzo@cttc.es>
19 */
20
21#ifndef LTE_CONTROL_MESSAGES_H
22#define LTE_CONTROL_MESSAGES_H
23
24#include "ff-mac-common.h"
25#include "lte-rrc-sap.h"
26
27#include <ns3/ptr.h>
28#include <ns3/simple-ref-count.h>
29
30#include <list>
31
32namespace ns3
33{
34
35class LteNetDevice;
36
44class LteControlMessage : public SimpleRefCount<LteControlMessage>
45{
46 public:
56 {
58 UL_DCI, // Downlink/Uplink Data Control Indicator
60 UL_CQI, // Downlink/Uplink Channel Quality Indicator
61 BSR, // Buffer Status Report
62 DL_HARQ, // UL HARQ feedback
63 RACH_PREAMBLE, // Random Access Preamble
64 RAR, // Random Access Response
65 MIB, // Master Information Block
66 SIB1, // System Information Block Type 1
67 };
68
70 virtual ~LteControlMessage();
71
76 void SetMessageType(MessageType type);
82
83 private:
85};
86
87// -----------------------------------------------------------------------
88
95{
96 public:
98 ~DlDciLteControlMessage() override;
99
104 void SetDci(DlDciListElement_s dci);
105
110 const DlDciListElement_s& GetDci();
111
112 private:
114};
115
116// ---------------------------------------------------------------------------
117
124{
125 public:
127 ~UlDciLteControlMessage() override;
128
133 void SetDci(UlDciListElement_s dci);
134
139 const UlDciListElement_s& GetDci();
140
141 private:
143};
144
145// ---------------------------------------------------------------------------
146
153{
154 public:
156 ~DlCqiLteControlMessage() override;
157
162 void SetDlCqi(CqiListElement_s dlcqi);
163
169
170 private:
172};
173
174// ---------------------------------------------------------------------------
175
182{
183 public:
185 ~BsrLteControlMessage() override;
186
191 void SetBsr(MacCeListElement_s bsr);
192
198
199 private:
201};
202
203// ---------------------------------------------------------------------------
204
211{
212 public:
215
221
227
228 private:
230};
231
232// ---------------------------------------------------------------------------
233
240{
241 public:
243
249 void SetRapId(uint32_t rapid);
250
255 uint32_t GetRapId() const;
256
257 private:
259};
260
261// ---------------------------------------------------------------------------
262
269{
270 public:
272
277 void SetRaRnti(uint16_t raRnti);
278
283 uint16_t GetRaRnti() const;
284
289 struct Rar
290 {
291 uint8_t rapId;
293 };
294
300 void AddRar(Rar rar);
301
306 std::list<Rar>::const_iterator RarListBegin() const;
307
312 std::list<Rar>::const_iterator RarListEnd() const;
313
314 private:
315 std::list<Rar> m_rarList;
316 uint16_t m_raRnti;
317};
318
319// ---------------------------------------------------------------------------
320
333{
334 public:
339
345
351
352 private:
354
355}; // end of class MibLteControlMessage
356
357// ---------------------------------------------------------------------------
358
371{
372 public:
377
383
389
390 private:
392
393}; // end of class Sib1LteControlMessage
394
395} // namespace ns3
396
397#endif // LTE_CONTROL_MESSAGES_H
The uplink BsrLteControlMessage defines the specific extension of the CE element for reporting the bu...
MacCeListElement_s m_bsr
BSR.
MacCeListElement_s GetBsr()
Get BSR information.
void SetBsr(MacCeListElement_s bsr)
add a BSR feedback record into the message.
The downlink CqiLteControlMessage defines an ideal list of feedback about the channel quality sent by...
CqiListElement_s m_dlCqi
DL CQI.
void SetDlCqi(CqiListElement_s dlcqi)
add a DL-CQI feedback record into the message.
CqiListElement_s GetDlCqi()
Get DL cqi information.
The Downlink Data Control Indicator messages defines the RB allocation for the users in the downlink.
const DlDciListElement_s & GetDci()
Get dic information.
void SetDci(DlDciListElement_s dci)
add a DCI into the message
DlDciListElement_s m_dci
DCI.
The downlink DlHarqFeedbackLteControlMessage defines the specific messages for transmitting the DL HA...
void SetDlHarqFeedback(DlInfoListElement_s m)
add a DL HARQ feedback record into the message.
DlInfoListElement_s GetDlHarqFeedback()
Get DL HARQ information.
DlInfoListElement_s m_dlInfoListElement
DL info list element.
The LteControlMessage provides a basic implementations for control messages (such as PDCCH allocation...
MessageType GetMessageType()
Get the type of the message.
MessageType m_type
message type
MessageType
The type of the message NOTE: The messages sent by UE are filtered by the LteEnbPhy::ReceiveLteContro...
void SetMessageType(MessageType type)
Set the type of the message.
Abstract model for broadcasting the Master Information Block (MIB) within the control channel (BCCH).
MibLteControlMessage()
Create a new instance of MIB control message.
void SetMib(LteRrcSap::MasterInformationBlock mib)
Replace the MIB content of this control message.
LteRrcSap::MasterInformationBlock m_mib
MIB.
LteRrcSap::MasterInformationBlock GetMib() const
Retrieve the MIB content from this control message.
abstract model for the Random Access Preamble
void SetRapId(uint32_t rapid)
Set the Random Access Preamble Identifier (RAPID), see 3GPP TS 36.321 6.2.2.
abstract model for the MAC Random Access Response message
std::list< Rar >::const_iterator RarListEnd() const
std::list< Rar >::const_iterator RarListBegin() const
std::list< Rar > m_rarList
RAR list.
void SetRaRnti(uint16_t raRnti)
void AddRar(Rar rar)
add a RAR to the MAC PDU, see 3GPP TS 36.321 6.2.3
Abstract model for broadcasting the System Information Block Type 1 (SIB1) within the control channel...
void SetSib1(LteRrcSap::SystemInformationBlockType1 sib1)
Replace the SIB1 content of this control message.
LteRrcSap::SystemInformationBlockType1 m_sib1
SIB1.
LteRrcSap::SystemInformationBlockType1 GetSib1() const
Retrieve the SIB1 content from this control message.
Sib1LteControlMessage()
Create a new instance of SIB1 control message.
A template-based reference counting class.
The Uplink Data Control Indicator messages defines the RB allocation for the users in the uplink.
void SetDci(UlDciListElement_s dci)
add a DCI into the message
const UlDciListElement_s & GetDci()
Get dic information.
UlDciListElement_s m_dci
DCI.
Every class exported by the ns3 library is enclosed in the ns3 namespace.
See section 4.3.10 buildRARListElement.
See section 4.3.24 cqiListElement.
See section 4.3.1 dlDciListElement.
Definition: ff-mac-common.h:93
See section 4.3.23 dlInfoListElement.
MasterInformationBlock structure.
Definition: lte-rrc-sap.h:622
SystemInformationBlockType1 structure.
Definition: lte-rrc-sap.h:629
See section 4.3.14 macCEListElement.
a MAC RAR and the corresponding RAPID subheader
BuildRarListElement_s rarPayload
RAR payload.
See section 4.3.2 ulDciListElement.