A Discrete-Event Network Simulator
Home
Tutorials ▼
English
Portuguese
Docs ▼
Wiki
Manual
Models
Develop ▼
API
Bugs
API
src
lte
test
lte-simple-spectrum-phy.h
Go to the documentation of this file.
1
/* -*- Mode: C++; c-file-style: "gnu"; indent-tabs-mode:nil; -*- */
2
/*
3
* Copyright (c) 2014 Piotr Gawlowicz
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: Piotr Gawlowicz <gawlowicz.p@gmail.com>
19
*
20
*/
21
22
#ifndef LTE_SIMPLE_SPECTRUM_PHY_H
23
#define LTE_SIMPLE_SPECTRUM_PHY_H
24
25
#include <ns3/event-id.h>
26
#include <ns3/spectrum-value.h>
27
#include <ns3/mobility-model.h>
28
#include <ns3/net-device.h>
29
#include <ns3/spectrum-phy.h>
30
#include <ns3/spectrum-channel.h>
31
#include <ns3/traced-callback.h>
32
33
namespace
ns3
{
34
47
class
LteSimpleSpectrumPhy
:
public
SpectrumPhy
48
{
49
50
public
:
51
LteSimpleSpectrumPhy
();
52
virtual
~LteSimpleSpectrumPhy
();
53
58
static
TypeId
GetTypeId
(
void
);
59
// inherited from Object
60
virtual
void
DoDispose
();
61
62
// inherited from SpectrumPhy
63
void
SetChannel
(
Ptr<SpectrumChannel>
c);
64
void
SetMobility
(
Ptr<MobilityModel>
m);
65
void
SetDevice
(
Ptr<NetDevice>
d);
66
Ptr<MobilityModel>
GetMobility
();
67
Ptr<NetDevice>
GetDevice
()
const
;
68
Ptr<const SpectrumModel>
GetRxSpectrumModel
()
const
;
69
Ptr<AntennaModel>
GetRxAntenna
();
70
void
StartRx
(
Ptr<SpectrumSignalParameters>
params);
71
76
void
SetRxSpectrumModel
(
Ptr<const SpectrumModel>
model);
77
82
void
SetCellId
(uint16_t cellId);
83
84
private
:
85
Ptr<MobilityModel>
m_mobility
;
86
Ptr<AntennaModel>
m_antenna
;
87
Ptr<NetDevice>
m_device
;
88
Ptr<SpectrumChannel>
m_channel
;
89
Ptr<const SpectrumModel>
m_rxSpectrumModel
;
90
91
uint16_t
m_cellId
;
92
93
TracedCallback< Ptr<const SpectrumValue>
>
m_rxStart
;
94
};
95
96
97
98
99
100
101
}
102
103
#endif
/* LTE_SIMPLE_SPECTRUM_PHY_H */
ns3::LteSimpleSpectrumPhy::m_mobility
Ptr< MobilityModel > m_mobility
the mobility model
Definition:
lte-simple-spectrum-phy.h:85
ns3::LteSimpleSpectrumPhy::m_cellId
uint16_t m_cellId
the cell ID
Definition:
lte-simple-spectrum-phy.h:91
ns3::LteSimpleSpectrumPhy::SetCellId
void SetCellId(uint16_t cellId)
Set cell ID.
Definition:
lte-simple-spectrum-phy.cc:163
ns3::Ptr
Smart pointer class similar to boost::intrusive_ptr.
Definition:
ptr.h:73
ns3::SpectrumPhy
Abstract base class for Spectrum-aware PHY layers.
Definition:
spectrum-phy.h:45
ns3::LteSimpleSpectrumPhy::SetChannel
void SetChannel(Ptr< SpectrumChannel > c)
Set the channel attached to this device.
Definition:
lte-simple-spectrum-phy.cc:108
ns3::LteSimpleSpectrumPhy::GetDevice
Ptr< NetDevice > GetDevice() const
Get the associated NetDevice instance.
Definition:
lte-simple-spectrum-phy.cc:76
ns3::LteSimpleSpectrumPhy::SetRxSpectrumModel
void SetRxSpectrumModel(Ptr< const SpectrumModel > model)
Set receive spectrum model.
Definition:
lte-simple-spectrum-phy.cc:156
ns3::TracedCallback
Forward calls to a chain of Callback.
Definition:
traced-callback.h:62
ns3::LteSimpleSpectrumPhy::DoDispose
virtual void DoDispose()
Destructor implementation.
Definition:
lte-simple-spectrum-phy.cc:50
ns3::LteSimpleSpectrumPhy::LteSimpleSpectrumPhy
LteSimpleSpectrumPhy()
Definition:
lte-simple-spectrum-phy.cc:39
ns3::LteSimpleSpectrumPhy::GetRxAntenna
Ptr< AntennaModel > GetRxAntenna()
Get the AntennaModel used by the NetDevice for reception.
Definition:
lte-simple-spectrum-phy.cc:122
ns3::LteSimpleSpectrumPhy::~LteSimpleSpectrumPhy
virtual ~LteSimpleSpectrumPhy()
Definition:
lte-simple-spectrum-phy.cc:45
ns3::LteSimpleSpectrumPhy::m_channel
Ptr< SpectrumChannel > m_channel
the channel
Definition:
lte-simple-spectrum-phy.h:88
ns3::LteSimpleSpectrumPhy::m_antenna
Ptr< AntennaModel > m_antenna
the antenna model
Definition:
lte-simple-spectrum-phy.h:86
ns3::LteSimpleSpectrumPhy::GetTypeId
static TypeId GetTypeId(void)
Get the type ID.
Definition:
lte-simple-spectrum-phy.cc:61
ns3::LteSimpleSpectrumPhy::GetRxSpectrumModel
Ptr< const SpectrumModel > GetRxSpectrumModel() const
Definition:
lte-simple-spectrum-phy.cc:115
ns3::LteSimpleSpectrumPhy::SetMobility
void SetMobility(Ptr< MobilityModel > m)
Set the mobility model associated with this device.
Definition:
lte-simple-spectrum-phy.cc:100
ns3
Every class exported by the ns3 library is enclosed in the ns3 namespace.
ns3::LteSimpleSpectrumPhy::m_rxStart
TracedCallback< Ptr< const SpectrumValue > > m_rxStart
receive start trace callback function
Definition:
lte-simple-spectrum-phy.h:93
ns3::LteSimpleSpectrumPhy::m_device
Ptr< NetDevice > m_device
the device
Definition:
lte-simple-spectrum-phy.h:87
ns3::LteSimpleSpectrumPhy::GetMobility
Ptr< MobilityModel > GetMobility()
Get the associated MobilityModel instance.
Definition:
lte-simple-spectrum-phy.cc:84
ns3::LteSimpleSpectrumPhy::m_rxSpectrumModel
Ptr< const SpectrumModel > m_rxSpectrumModel
the spectrum model
Definition:
lte-simple-spectrum-phy.h:89
ns3::TypeId
a unique identifier for an interface.
Definition:
type-id.h:58
ns3::LteSimpleSpectrumPhy
The LteSimpleSpectrumPhy models the physical layer of LTE This class is used to test Frequency Reuse ...
Definition:
lte-simple-spectrum-phy.h:47
ns3::LteSimpleSpectrumPhy::StartRx
void StartRx(Ptr< SpectrumSignalParameters > params)
Notify the SpectrumPhy instance of an incoming signal.
Definition:
lte-simple-spectrum-phy.cc:128
ns3::LteSimpleSpectrumPhy::SetDevice
void SetDevice(Ptr< NetDevice > d)
Set the associated NetDevice instance.
Definition:
lte-simple-spectrum-phy.cc:92
Generated on Wed Nov 7 2018 10:02:03 for ns-3 by
1.8.14