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
All
Classes
Namespaces
Files
Functions
Variables
Typedefs
Enumerations
Enumerator
Friends
Groups
Pages
lte-common.h
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
* Author: Marco Miozzo <marco.miozzo@cttc.es>
20
*/
21
#ifndef LTE_COMMON_H
22
#define LTE_COMMON_H
23
24
#include "ns3/uinteger.h"
25
#include <cmath>
26
27
// see 36.213 section 8
28
#define UL_PUSCH_TTIS_DELAY 4
29
30
#define HARQ_PERIOD 7
31
32
namespace
ns3 {
33
34
35
struct
LteFlowId_t
36
{
37
uint16_t m_rnti;
38
uint8_t m_lcId;
39
40
public
:
41
LteFlowId_t
();
42
LteFlowId_t
(
const
uint16_t a,
const
uint8_t b);
43
44
friend
bool
operator == (
const
LteFlowId_t
&a,
const
LteFlowId_t
&b);
45
friend
bool
operator < (
const
LteFlowId_t
&a,
const
LteFlowId_t
&b);
46
};
47
48
struct
ImsiLcidPair_t
49
{
50
uint64_t m_imsi;
51
uint8_t m_lcId;
52
53
public
:
54
ImsiLcidPair_t
();
55
ImsiLcidPair_t
(
const
uint64_t a,
const
uint8_t b);
56
57
friend
bool
operator == (
const
ImsiLcidPair_t
&a,
const
ImsiLcidPair_t
&b);
58
friend
bool
operator < (
const
ImsiLcidPair_t
&a,
const
ImsiLcidPair_t
&b);
59
};
60
64
struct
LteUeConfig_t
65
{
66
uint16_t m_rnti;
70
bool
m_reconfigureFlag
;
74
uint8_t
m_transmissionMode
;
78
uint16_t
m_srsConfigurationIndex
;
79
80
public
:
81
LteUeConfig_t
();
82
83
friend
bool
operator == (
const
LteUeConfig_t
&a,
const
LteUeConfig_t
&b);
84
friend
bool
operator < (
const
LteUeConfig_t
&a,
const
LteUeConfig_t
&b);
85
};
86
87
88
class
LteFfConverter
89
{
90
91
public
:
92
static
uint16_t double2fpS11dot3 (
double
val);
93
static
double
fpS11dot3toDouble (uint16_t val);
94
static
double
getMinFpS11dot3Value ();
95
96
//static const double MIN_FP_S11DOT3_VALUE = -4096;
97
98
99
};
100
101
class
BufferSizeLevelBsr
102
{
103
104
public
:
105
static
uint32_t BsrId2BufferSize (uint8_t val);
106
static
uint8_t BufferSize2BsrId (uint32_t val);
107
108
static
int
m_bufferSizeLevelBsr[64];
109
110
111
};
112
113
class
TransmissionModesLayers
114
{
115
public
:
116
static
uint8_t TxMode2LayerNum (uint8_t txMode);
117
};
118
119
120
struct
PhyTransmissionStatParameters
121
{
122
int64_t m_timestamp;
// in millisecond
123
uint16_t m_cellId;
124
uint64_t m_imsi;
125
uint16_t m_rnti;
126
uint8_t m_txMode;
127
uint8_t m_layer;
128
uint8_t m_mcs;
129
uint16_t m_size;
130
uint8_t m_rv;
131
uint8_t m_ndi;
132
};
133
134
135
struct
PhyReceptionStatParameters
136
{
137
int64_t m_timestamp;
// in millisecond
138
uint16_t m_cellId;
139
uint64_t m_imsi;
140
uint16_t m_rnti;
141
uint8_t m_txMode;
142
uint8_t m_layer;
143
uint8_t m_mcs;
144
uint16_t m_size;
145
uint8_t m_rv;
146
uint8_t m_ndi;
147
uint8_t m_correctness;
148
};
149
150
151
};
// namespace ns3
152
153
154
#endif
/* LTE_COMMON_H_ */
ns3::TransmissionModesLayers
Definition:
lte-common.h:113
ns3::LteFfConverter
Definition:
lte-common.h:88
ns3::ImsiLcidPair_t
Definition:
lte-common.h:48
ns3::LteUeConfig_t::m_reconfigureFlag
bool m_reconfigureFlag
Definition:
lte-common.h:70
ns3::PhyReceptionStatParameters
Definition:
lte-common.h:135
ns3::LteUeConfig_t::m_srsConfigurationIndex
uint16_t m_srsConfigurationIndex
Definition:
lte-common.h:78
ns3::LteUeConfig_t::m_transmissionMode
uint8_t m_transmissionMode
Definition:
lte-common.h:74
ns3::LteUeConfig_t
Parameters for configuring the UE.
Definition:
lte-common.h:64
ns3::LteFlowId_t
Definition:
lte-common.h:35
ns3::PhyTransmissionStatParameters
Definition:
lte-common.h:120
ns3::BufferSizeLevelBsr
Definition:
lte-common.h:101
src
lte
model
lte-common.h
Generated on Sun Mar 16 2014 11:25:06 for ns-3 by
1.8.6