A Discrete-Event Network Simulator
Home
Tutorials ▼
English
Portuguese
Docs ▼
Wiki
Manual
Models
Develop ▼
API
Bugs
API
Main Page
Related Pages
Modules
Namespaces
Classes
Files
File List
File Members
All
Classes
Namespaces
Files
Functions
Variables
Typedefs
Enumerations
Enumerator
Properties
Friends
Macros
Groups
Pages
ff-mac-common.h
Go to the documentation of this file.
1
/* -*- Mode:C++; c-file-style:"gnu"; indent-tabs-mode:nil; -*- */
2
/*
3
* Copyright (c) 2011 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
* Author: Manuel Requena <manuel.requena@cttc.es>
19
*/
20
21
#ifndef FF_MAC_COMMON_H
22
#define FF_MAC_COMMON_H
23
24
#include <ns3/simple-ref-count.h>
25
#include <ns3/ptr.h>
26
#include <vector>
27
28
32
#define MAX_SCHED_CFG_LIST 10
33
#define MAX_LC_LIST 10
34
35
#define MAX_RACH_LIST 30
36
#define MAX_DL_INFO_LIST 30
37
#define MAX_BUILD_DATA_LIST 30
38
#define MAX_BUILD_RAR_LIST 10
39
#define MAX_BUILD_BC_LIST 3
40
#define MAX_UL_INFO_LIST 30
41
#define MAX_DCI_LIST 30
42
#define MAX_PHICH_LIST 30
43
#define MAX_TB_LIST 2
44
#define MAX_RLC_PDU_LIST 30
45
#define MAX_NR_LCG 4
46
#define MAX_MBSFN_CONFIG 5
47
#define MAX_SI_MSG_LIST 32
48
#define MAX_SI_MSG_SIZE 65535
49
50
#define MAX_CQI_LIST 30
51
#define MAX_UE_SELECTED_SB 6
52
#define MAX_HL_SB 25
53
#define MAX_SINR_RB_LIST 100
54
#define MAX_SR_LIST 30
55
#define MAX_MAC_CE_LIST 30
56
57
namespace
ns3 {
58
59
enum
Result_e
60
{
61
SUCCESS
,
62
FAILURE
63
};
64
65
enum
SetupRelease_e
66
{
67
setup
,
68
release
69
};
70
71
enum
CeBitmap_e
72
{
73
TA
,
74
DRX
,
75
CR
76
};
77
78
enum
NormalExtended_e
79
{
80
normal
,
81
extended
82
};
83
84
88
struct
DlDciListElement_s
89
{
90
uint16_t
m_rnti
;
91
uint32_t
m_rbBitmap
;
92
uint8_t
m_rbShift
;
93
uint8_t
m_resAlloc
;
94
std::vector <uint16_t>
m_tbsSize
;
95
std::vector <uint8_t>
m_mcs
;
96
std::vector <uint8_t>
m_ndi
;
97
std::vector <uint8_t>
m_rv
;
98
uint8_t
m_cceIndex
;
99
uint8_t
m_aggrLevel
;
100
uint8_t
m_precodingInfo
;
101
enum
Format_e
102
{
103
ONE
,
ONE_A
,
ONE_B
,
ONE_C
,
ONE_D
,
TWO
,
TWO_A
,
TWO_B
104
}
m_format
;
105
uint8_t
m_tpc
;
106
uint8_t
m_harqProcess
;
107
uint8_t
m_dai
;
108
enum
VrbFormat_e
109
{
110
VRB_DISTRIBUTED
,
111
VRB_LOCALIZED
112
}
m_vrbFormat
;
113
bool
m_tbSwap
;
114
bool
m_spsRelease
;
115
bool
m_pdcchOrder
;
116
uint8_t
m_preambleIndex
;
117
uint8_t
m_prachMaskIndex
;
118
enum
Ngap_e
119
{
120
GAP1
,
GAP2
121
}
m_nGap
;
122
uint8_t
m_tbsIdx
;
123
uint8_t
m_dlPowerOffset
;
124
uint8_t
m_pdcchPowerOffset
;
125
};
126
130
struct
UlDciListElement_s
131
{
132
uint16_t
m_rnti
;
133
uint8_t
m_rbStart
;
134
uint8_t
m_rbLen
;
135
uint16_t
m_tbSize
;
136
uint8_t
m_mcs
;
137
uint8_t
m_ndi
;
138
uint8_t
m_cceIndex
;
139
uint8_t
m_aggrLevel
;
140
uint8_t
m_ueTxAntennaSelection
;
141
bool
m_hopping
;
142
uint8_t
m_n2Dmrs
;
143
int8_t
m_tpc
;
144
bool
m_cqiRequest
;
145
uint8_t
m_ulIndex
;
146
uint8_t
m_dai
;
147
uint8_t
m_freqHopping
;
148
int8_t
m_pdcchPowerOffset
;
149
};
150
154
struct
VendorSpecificValue
:
public
SimpleRefCount
<VendorSpecificValue>
155
{
156
virtual
~VendorSpecificValue
();
157
158
};
159
163
struct
VendorSpecificListElement_s
164
{
165
uint32_t
m_type
;
166
uint32_t
m_length
;
167
Ptr<VendorSpecificValue>
m_value
;
168
};
169
173
struct
LogicalChannelConfigListElement_s
174
{
175
uint8_t
m_logicalChannelIdentity
;
176
uint8_t
m_logicalChannelGroup
;
177
178
enum
Direction_e
179
{
180
DIR_UL
,
181
DIR_DL
,
182
DIR_BOTH
183
}
m_direction
;
184
185
enum
QosBearerType_e
186
{
187
QBT_NON_GBR
,
188
QBT_GBR
189
}
m_qosBearerType
;
190
191
uint8_t
m_qci
;
192
uint64_t
m_eRabMaximulBitrateUl
;
193
uint64_t
m_eRabMaximulBitrateDl
;
194
uint64_t
m_eRabGuaranteedBitrateUl
;
195
uint64_t
m_eRabGuaranteedBitrateDl
;
196
};
197
201
struct
RachListElement_s
202
{
203
uint16_t
m_rnti
;
204
uint16_t
m_estimatedSize
;
205
};
206
210
struct
PhichListElement_s
211
{
212
uint16_t
m_rnti
;
213
enum
Phich_e
214
{
215
ACK
,
NACK
216
}
m_phich
;
217
};
218
222
struct
RlcPduListElement_s
223
{
224
uint8_t
m_logicalChannelIdentity
;
225
uint16_t
m_size
;
226
};
227
231
struct
BuildDataListElement_s
232
{
233
uint16_t
m_rnti
;
234
struct
DlDciListElement_s
m_dci
;
235
std::vector <enum CeBitmap_e>
m_ceBitmap
;
236
std::vector < std::vector <struct RlcPduListElement_s> >
m_rlcPduList
;
237
};
238
242
struct
BuildRarListElement_s
243
{
244
uint16_t
m_rnti
;
245
uint32_t
m_grant
;
246
struct
DlDciListElement_s
m_dci
;
247
};
248
252
struct
BuildBroadcastListElement_s
253
{
254
enum
Type_e
255
{
256
BCCH
,
PCCH
257
}
m_type
;
258
uint8_t
m_index
;
259
struct
DlDciListElement_s
m_dci
;
260
};
261
265
struct
UlInfoListElement_s
266
{
267
uint16_t
m_rnti
;
268
std::vector <uint16_t>
m_ulReception
;
269
enum
ReceptionStatus_e
270
{
271
Ok
,
NotOk
,
NotValid
272
}
m_receptionStatus
;
273
uint8_t
m_tpc
;
274
};
275
279
struct
SrListElement_s
280
{
281
uint16_t
m_rnti
;
282
};
283
287
struct
MacCeValue_u
288
{
289
uint8_t
m_phr
;
290
uint8_t
m_crnti
;
291
std::vector <uint8_t>
m_bufferStatus
;
292
};
293
297
struct
MacCeListElement_s
298
{
299
uint16_t
m_rnti
;
300
enum
MacCeType_e
301
{
302
BSR
,
PHR
,
CRNTI
303
}
m_macCeType
;
304
struct
MacCeValue_u
m_macCeValue
;
305
};
306
310
struct
DrxConfig_s
311
{
312
uint8_t
m_onDurationTimer
;
313
uint16_t
m_drxInactivityTimer
;
314
uint16_t
m_drxRetransmissionTimer
;
315
uint16_t
m_longDrxCycle
;
316
uint16_t
m_longDrxCycleStartOffset
;
317
uint16_t
m_shortDrxCycle
;
318
uint8_t
m_drxShortCycleTimer
;
319
};
320
324
struct
SpsConfig_s
325
{
326
uint16_t
m_semiPersistSchedIntervalUl
;
327
uint16_t
m_semiPersistSchedIntervalDl
;
328
uint8_t
m_numberOfConfSpsProcesses
;
329
uint8_t
m_n1PucchAnPersistentListSize
;
330
std::vector <uint16_t>
m_n1PucchAnPersistentList
;
331
uint8_t
m_implicitReleaseAfter
;
332
};
333
337
struct
SrConfig_s
338
{
339
enum
SetupRelease_e
m_action
;
340
uint8_t
m_schedInterval
;
341
uint8_t
m_dsrTransMax
;
342
};
343
347
struct
CqiConfig_s
348
{
349
enum
SetupRelease_e
m_action
;
350
uint16_t
m_cqiSchedInterval
;
351
uint8_t
m_riSchedInterval
;
352
};
353
357
struct
UeCapabilities_s
358
{
359
bool
m_halfDuplex
;
360
bool
m_intraSfHopping
;
361
bool
m_type2Sb1
;
362
uint8_t
m_ueCategory
;
363
bool
m_resAllocType1
;
364
};
365
369
struct
SiMessageListElement_s
370
{
371
uint16_t
m_periodicity
;
372
uint16_t
m_length
;
373
};
374
378
struct
SiConfiguration_s
379
{
380
uint16_t
m_sfn
;
381
uint16_t
m_sib1Length
;
382
uint8_t
m_siWindowLength
;
383
std::vector <struct SiMessageListElement_s>
m_siMessageList
;
384
};
385
389
struct
DlInfoListElement_s
390
{
391
uint16_t
m_rnti
;
392
uint8_t
m_harqProcessId
;
393
enum
HarqStatus_e
394
{
395
ACK
,
NACK
,
DTX
396
};
397
std::vector <enum HarqStatus_e>
m_harqStatus
;
398
};
399
403
struct
BwPart_s
404
{
405
uint8_t
m_bwPartIndex
;
406
uint8_t
m_sb
;
407
uint8_t
m_cqi
;
408
};
409
413
struct
HigherLayerSelected_s
414
{
415
uint8_t
m_sbPmi
;
416
std::vector <uint8_t>
m_sbCqi
;
417
};
418
422
struct
UeSelected_s
423
{
424
std::vector <uint8_t>
m_sbList
;
425
uint8_t
m_sbPmi
;
426
std::vector <uint8_t>
m_sbCqi
;
427
};
428
432
struct
SbMeasResult_s
433
{
434
struct
UeSelected_s
m_ueSelected
;
435
std::vector <struct HigherLayerSelected_s>
m_higherLayerSelected
;
436
struct
BwPart_s
m_bwPart
;
437
};
438
442
struct
CqiListElement_s
443
{
444
uint16_t
m_rnti
;
445
uint8_t
m_ri
;
446
enum
CqiType_e
447
{
448
P10
,
P11
,
P20
,
P21
,
A12
,
A22
,
A20
,
A30
,
A31
449
}
m_cqiType
;
450
std::vector <uint8_t>
m_wbCqi
;
451
uint8_t
m_wbPmi
;
452
453
struct
SbMeasResult_s
m_sbMeasResult
;
454
};
455
459
struct
UlCqi_s
460
{
461
std::vector <uint16_t>
m_sinr
;
462
enum
Type_e
463
{
464
SRS
,
465
PUSCH
,
466
PUCCH_1
,
467
PUCCH_2
,
468
PRACH
469
}
m_type
;
470
};
471
475
struct
PagingInfoListElement_s
476
{
477
uint8_t
m_pagingIndex
;
478
uint16_t
m_pagingMessageSize
;
479
uint8_t
m_pagingSubframe
;
480
};
481
482
}
// namespace ns3
483
484
#endif
/* FF_MAC_COMMON_H */
src
lte
model
ff-mac-common.h
Generated on Fri Dec 21 2012 19:00:39 for ns-3 by
1.8.1.2