A Discrete-Event Network Simulator
API
lte-ue-net-device.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  * Nicola Baldo <nbaldo@cttc.es>
20  * Modified by:
21  * Danilo Abrignani <danilo.abrignani@unibo.it> (Carrier Aggregation - GSoC 2015)
22  * Biljana Bojovic <biljana.bojovic@cttc.es> (Carrier Aggregation)
23  */
24 
25 #ifndef LTE_UE_NET_DEVICE_H
26 #define LTE_UE_NET_DEVICE_H
27 
28 #include "ns3/lte-net-device.h"
29 #include "ns3/event-id.h"
30 #include "ns3/traced-callback.h"
31 #include "ns3/nstime.h"
32 #include "ns3/lte-phy.h"
33 #include "ns3/eps-bearer.h"
34 #include "ns3/component-carrier-ue.h"
35 #include <vector>
36 #include <map>
37 
38 namespace ns3 {
39 
40 class Packet;
41 class PacketBurst;
42 class Node;
43 class LtePhy;
44 class LteUePhy;
45 class LteEnbNetDevice;
46 class LteUeMac;
47 class LteUeRrc;
48 class EpcUeNas;
49 class EpcTft;
50 class LteUeComponentCarrierManager;
51 
57 {
58 
59 public:
64  static TypeId GetTypeId (void);
65 
66  LteUeNetDevice (void);
67  virtual ~LteUeNetDevice (void);
68  virtual void DoDispose ();
69 
70 
71  // inherited from NetDevice
72  virtual bool Send (Ptr<Packet> packet, const Address& dest, uint16_t protocolNumber);
73 
78  Ptr<LteUeMac> GetMac (void) const;
79 
84  Ptr<LteUeRrc> GetRrc () const;
85 
90  Ptr<LteUePhy> GetPhy (void) const;
91 
96  Ptr<EpcUeNas> GetNas (void) const;
97 
103 
108  uint64_t GetImsi () const;
109 
116  uint32_t GetDlEarfcn () const;
117 
124  void SetDlEarfcn (uint32_t earfcn);
125 
130  uint32_t GetCsgId () const;
131 
143  void SetCsgId (uint32_t csgId);
144 
150 
156 
161  void SetCcMap (std::map< uint8_t, Ptr<ComponentCarrierUe> > ccm);
162 
167  std::map< uint8_t, Ptr<ComponentCarrierUe> > GetCcMap (void);
168 
169 
170 
171 protected:
172  // inherited from Object
173  virtual void DoInitialize (void);
174 
175 
176 private:
178 
188  void UpdateConfig ();
189 
191 
195 
196  uint64_t m_imsi;
197 
198  uint32_t m_dlEarfcn;
200  uint32_t m_csgId;
201 
202  std::map < uint8_t, Ptr<ComponentCarrierUe> > m_ccMap;
203 
204 }; // end of class LteUeNetDevice
205 
206 } // namespace ns3
207 
208 #endif /* LTE_UE_NET_DEVICE_H */
Ptr< LteUeRrc > m_rrc
the RRC
virtual ~LteUeNetDevice(void)
uint32_t GetCsgId() const
Returns the CSG ID the UE is currently a member of.
Ptr< EpcUeNas > GetNas(void) const
Get the NAS.
std::map< uint8_t, Ptr< ComponentCarrierUe > > GetCcMap(void)
Get the ComponentCarrier Map for the UE.
Ptr< LteEnbNetDevice > m_targetEnb
target ENB
uint64_t m_imsi
the IMSI
uint32_t m_csgId
the CSG ID
std::map< uint8_t, Ptr< ComponentCarrierUe > > m_ccMap
CC map.
a polymophic address class
Definition: address.h:90
Ptr< EpcUeNas > m_nas
the NAS
static TypeId GetTypeId(void)
Get the type ID.
virtual void DoDispose()
Destructor implementation.
uint64_t GetImsi() const
Get the IMSI.
void SetTargetEnb(Ptr< LteEnbNetDevice > enb)
Set the target eNB where the UE is registered.
virtual void DoInitialize(void)
Initialize() implementation.
Every class exported by the ns3 library is enclosed in the ns3 namespace.
void SetCsgId(uint32_t csgId)
Enlist the UE device as a member of a particular CSG.
uint32_t m_dlEarfcn
downlink carrier frequency
void SetDlEarfcn(uint32_t earfcn)
Ptr< LteUePhy > GetPhy(void) const
Get the Phy.
Ptr< LteUeComponentCarrierManager > GetComponentCarrierManager(void) const
Get the componentn carrier manager.
Ptr< LteEnbNetDevice > GetTargetEnb(void)
Get the target eNB where the UE is registered.
uint32_t GetDlEarfcn() const
void SetCcMap(std::map< uint8_t, Ptr< ComponentCarrierUe > > ccm)
Set the ComponentCarrier Map for the UE.
Ptr< LteUeMac > GetMac(void) const
Get the MAC.
Ptr< LteUeRrc > GetRrc() const
Get the RRC.
void UpdateConfig()
Propagate attributes and configuration to sub-modules.
LteNetDevice provides basic implementation for all LTE network devices.
virtual bool Send(Ptr< Packet > packet, const Address &dest, uint16_t protocolNumber)
a unique identifier for an interface.
Definition: type-id.h:58
bool m_isConstructed
is constructed?
Ptr< LteUeComponentCarrierManager > m_componentCarrierManager
the component carrier manager
The LteUeNetDevice class implements the UE net device.