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
lte-ue-phy.h
Go to the documentation of this file.
1
/* -*- Mode:C++; c-file-style:"gnu"; indent-tabs-mode:nil; -*- */
2
/*
3
* Copyright (c) 2010 TELEMATICS LAB, DEE - Politecnico di Bari
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: Giuseppe Piro <g.piro@poliba.it>
19
* Author: Marco Miozzo <mmiozzo@cttc.es>
20
*/
21
22
#ifndef LTE_UE_PHY_H
23
#define LTE_UE_PHY_H
24
25
26
#include <ns3/lte-phy.h>
27
#include <ns3/ff-mac-common.h>
28
29
#include <ns3/lte-control-messages.h>
30
#include <ns3/lte-amc.h>
31
#include <ns3/lte-ue-phy-sap.h>
32
#include <ns3/ptr.h>
33
#include <ns3/lte-amc.h>
34
35
36
namespace
ns3 {
37
38
class
PacketBurst;
39
class
LteNetDevice;
40
class
LteEnbPhy;
41
47
class
LteUePhy
:
public
LtePhy
48
{
49
50
friend
class
UeMemberLteUePhySapProvider
;
51
52
public
:
56
LteUePhy
();
57
63
LteUePhy
(
Ptr<LteSpectrumPhy>
dlPhy,
Ptr<LteSpectrumPhy>
ulPhy);
64
65
virtual
~LteUePhy
();
66
67
// inherited from Object
68
static
TypeId
GetTypeId
(
void
);
69
virtual
void
DoStart
(
void
);
70
virtual
void
DoDispose
(
void
);
71
76
LteUePhySapProvider
*
GetLteUePhySapProvider
();
77
82
void
SetLteUePhySapUser
(
LteUePhySapUser
* s);
83
84
88
void
SetTxPower
(
double
pow);
89
93
double
GetTxPower
()
const
;
97
void
SetNoiseFigure
(
double
pow);
98
102
double
GetNoiseFigure
()
const
;
103
107
uint8_t
GetMacChDelay
(
void
)
const
;
108
113
virtual
void
DoSendMacPdu
(
Ptr<Packet>
p);
114
119
virtual
Ptr<SpectrumValue>
CreateTxPowerSpectralDensity
();
120
125
void
SetSubChannelsForTransmission
(std::vector <int> mask);
130
std::vector <int>
GetSubChannelsForTransmission
(
void
);
131
136
void
SetSubChannelsForReception
(std::vector <int> mask);
141
std::vector <int>
GetSubChannelsForReception
(
void
);
142
143
149
Ptr<DlCqiLteControlMessage>
CreateDlCqiFeedbackMessage
(
const
SpectrumValue
& sinr);
150
151
152
153
// inherited from LtePhy
154
virtual
void
GenerateCtrlCqiReport
(
const
SpectrumValue
& sinr);
155
virtual
void
GenerateDataCqiReport
(
const
SpectrumValue
& sinr);
156
157
virtual
void
DoSendLteControlMessage
(
Ptr<LteControlMessage>
msg);
158
virtual
void
ReceiveLteControlMessageList
(
std::list
<
Ptr<LteControlMessage>
>);
159
160
virtual
void
DoSetTransmissionMode
(uint8_t txMode);
161
virtual
void
DoSetSrsConfigurationIndex
(uint16_t srcCi);
162
163
164
165
166
170
void
PhyPduReceived
(
Ptr<Packet>
p);
171
172
179
void
SubframeIndication
(uint32_t frameNo, uint32_t subframeNo);
180
181
185
void
SetRnti
(uint16_t rnti);
186
187
193
void
SetEnbCellId
(uint16_t cellId);
194
198
void
SendSrs
();
199
200
201
202
203
private
:
204
205
void
SetTxMode1Gain
(
double
gain);
206
void
SetTxMode2Gain
(
double
gain);
207
void
SetTxMode3Gain
(
double
gain);
208
void
SetTxMode4Gain
(
double
gain);
209
void
SetTxMode5Gain
(
double
gain);
210
void
SetTxMode6Gain
(
double
gain);
211
void
SetTxMode7Gain
(
double
gain);
212
void
SetTxModeGain
(uint8_t txMode,
double
gain);
213
214
void
QueueSubChannelsForTransmission
(std::vector <int> rbMap);
215
216
std::vector <int>
m_subChannelsForTransmission
;
217
std::vector <int>
m_subChannelsForReception
;
218
219
std::vector< std::vector <int> >
m_subChannelsForTransmissionQueue
;
220
221
222
Ptr<LteAmc>
m_amc
;
223
224
Time
m_p10CqiPeriocity
;
225
Time
m_p10CqiLast
;
226
228
// NOTE defines a periodicity for academic studies
229
Time
m_a30CqiPeriocity
;
230
Time
m_a30CqiLast
;
231
232
LteUePhySapProvider
*
m_uePhySapProvider
;
233
LteUePhySapUser
*
m_uePhySapUser
;
234
235
uint16_t
m_rnti
;
236
237
uint16_t
m_enbCellId
;
238
239
uint8_t
m_transmissionMode
;
240
std::vector <double>
m_txModeGain
;
241
242
uint16_t
m_srsPeriodicity
;
243
uint16_t
m_srsCounter
;
244
245
};
246
247
248
}
249
250
#endif
/* LTE_UE_PHY_H */
src
lte
model
lte-ue-phy.h
Generated on Fri Dec 21 2012 19:00:40 for ns-3 by
1.8.1.2