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;
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 */
Ptr< MobilityModel > m_mobility
the mobility model
void SetCellId(uint16_t cellId)
Set cell ID.
Smart pointer class similar to boost::intrusive_ptr.
Definition: ptr.h:73
Abstract base class for Spectrum-aware PHY layers.
Definition: spectrum-phy.h:45
void SetChannel(Ptr< SpectrumChannel > c)
Set the channel attached to this device.
Ptr< NetDevice > GetDevice() const
Get the associated NetDevice instance.
void SetRxSpectrumModel(Ptr< const SpectrumModel > model)
Set receive spectrum model.
Forward calls to a chain of Callback.
virtual void DoDispose()
Destructor implementation.
Ptr< AntennaModel > GetRxAntenna()
Get the AntennaModel used by the NetDevice for reception.
Ptr< SpectrumChannel > m_channel
the channel
Ptr< AntennaModel > m_antenna
the antenna model
static TypeId GetTypeId(void)
Get the type ID.
Ptr< const SpectrumModel > GetRxSpectrumModel() const
void SetMobility(Ptr< MobilityModel > m)
Set the mobility model associated with this device.
Every class exported by the ns3 library is enclosed in the ns3 namespace.
TracedCallback< Ptr< const SpectrumValue > > m_rxStart
receive start trace callback function
Ptr< NetDevice > m_device
the device
Ptr< MobilityModel > GetMobility()
Get the associated MobilityModel instance.
Ptr< const SpectrumModel > m_rxSpectrumModel
the spectrum model
a unique identifier for an interface.
Definition: type-id.h:58
The LteSimpleSpectrumPhy models the physical layer of LTE This class is used to test Frequency Reuse ...
void StartRx(Ptr< SpectrumSignalParameters > params)
Notify the SpectrumPhy instance of an incoming signal.
void SetDevice(Ptr< NetDevice > d)
Set the associated NetDevice instance.