A Discrete-Event Network Simulator
API
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 
48 {
49 
50 public:
52  virtual ~LteSimpleSpectrumPhy ();
53 
58  static TypeId GetTypeId (void);
59  // inherited from Object
60  virtual void DoDispose ();
61 
62  // inherited from SpectrumPhy
65  void SetDevice (Ptr<NetDevice> d);
67  Ptr<NetDevice> GetDevice () const;
69  Ptr<Object> GetAntenna () const;
71 
77 
82  void SetCellId (uint16_t cellId);
83 
84 private:
90 
91  uint16_t m_cellId;
92 
94 };
95 
96 
97 
98 
99 
100 
101 }
102 
103 #endif /* LTE_SIMPLE_SPECTRUM_PHY_H */
The LteSimpleSpectrumPhy models the physical layer of LTE This class is used to test Frequency Reuse ...
void SetDevice(Ptr< NetDevice > d)
Set the associated NetDevice instance.
Ptr< const SpectrumModel > GetRxSpectrumModel() const
Ptr< SpectrumChannel > m_channel
the channel
Ptr< MobilityModel > GetMobility() const
Get the associated MobilityModel instance.
void SetChannel(Ptr< SpectrumChannel > c)
Set the channel attached to this device.
void SetRxSpectrumModel(Ptr< const SpectrumModel > model)
Set receive spectrum model.
static TypeId GetTypeId(void)
Get the type ID.
Ptr< NetDevice > GetDevice() const
Get the associated NetDevice instance.
Ptr< AntennaModel > m_antenna
the antenna model
TracedCallback< Ptr< const SpectrumValue > > m_rxStart
receive start trace callback function
Ptr< Object > GetAntenna() const
Get the AntennaModel used by this SpectrumPhy instance for transmission and/or reception.
Ptr< NetDevice > m_device
the device
Ptr< const SpectrumModel > m_rxSpectrumModel
the spectrum model
virtual void DoDispose()
Destructor implementation.
void SetMobility(Ptr< MobilityModel > m)
Set the mobility model associated with this device.
Ptr< MobilityModel > m_mobility
the mobility model
void SetCellId(uint16_t cellId)
Set cell ID.
void StartRx(Ptr< SpectrumSignalParameters > params)
Notify the SpectrumPhy instance of an incoming signal.
Smart pointer class similar to boost::intrusive_ptr.
Definition: ptr.h:74
Abstract base class for Spectrum-aware PHY layers.
Definition: spectrum-phy.h:47
Forward calls to a chain of Callback.
a unique identifier for an interface.
Definition: type-id.h:59
Every class exported by the ns3 library is enclosed in the ns3 namespace.