author | CTTC |
Thu, 10 Mar 2011 18:15:26 +0100 | |
changeset 7886 | b65c16d4da83 |
parent 6852 | 8f1a53d3f6ca |
permissions | -rw-r--r-- |
6705 | 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> |
|
7886 | 19 |
* Author: Marco Miozzo <marco.miozzo@cttc.es> : Update to FF API Architecture |
6705 | 20 |
*/ |
21 |
||
22 |
#ifndef ENB_NET_DEVICE_H |
|
23 |
#define ENB_NET_DEVICE_H |
|
24 |
||
25 |
#include "lte-net-device.h" |
|
26 |
#include "ns3/event-id.h" |
|
27 |
#include "ns3/mac48-address.h" |
|
28 |
#include "ns3/traced-callback.h" |
|
29 |
#include "ns3/nstime.h" |
|
30 |
#include "ns3/log.h" |
|
31 |
#include "lte-phy.h" |
|
32 |
#include <vector> |
|
33 |
||
34 |
namespace ns3 { |
|
35 |
||
36 |
class Packet; |
|
37 |
class PacketBurst; |
|
38 |
class Node; |
|
39 |
class LtePhy; |
|
7886 | 40 |
class EnbLtePhy; |
41 |
class LteEnbMac; |
|
42 |
class LteEnbRrc; |
|
43 |
class RrFfMacScheduler; |
|
6705 | 44 |
|
45 |
||
46 |
/** |
|
47 |
* The eNodeB device implementation |
|
48 |
*/ |
|
49 |
class EnbNetDevice : public LteNetDevice |
|
50 |
{ |
|
51 |
public: |
|
52 |
static TypeId GetTypeId (void); |
|
53 |
||
54 |
EnbNetDevice (void); |
|
55 |
/** |
|
56 |
* \brief Create eNB net device |
|
57 |
* \param node the network node |
|
58 |
* \param phy the physical object attache dto it |
|
59 |
*/ |
|
7886 | 60 |
EnbNetDevice (Ptr<Node> node, Ptr<EnbLtePhy> phy); |
6705 | 61 |
|
62 |
virtual ~EnbNetDevice (void); |
|
6710
3cd651349cb6
lte examples now passing valgrind tests
Nicola Baldo <nbaldo@cttc.es>
parents:
6705
diff
changeset
|
63 |
virtual void DoDispose (void); |
6705 | 64 |
|
65 |
/** |
|
66 |
* \brief Initialize all parameters of this device |
|
67 |
*/ |
|
68 |
void InitEnbNetDevice (void); |
|
69 |
||
70 |
/** |
|
7886 | 71 |
* \return a pointer to the MAC |
6705 | 72 |
*/ |
7886 | 73 |
Ptr<LteEnbMac> GetMac (void); |
6705 | 74 |
|
75 |
/** |
|
7886 | 76 |
* \return a pointer to the physical layer. |
6705 | 77 |
*/ |
7886 | 78 |
Ptr<EnbLtePhy> GetPhy (void) const; |
6705 | 79 |
|
80 |
||
81 |
||
7886 | 82 |
Ptr<LteEnbRrc> GetRrc (); |
6705 | 83 |
|
84 |
/** |
|
85 |
* \brief Send the PDCCH ideal mesages under an |
|
86 |
* ideal control channel |
|
87 |
*/ |
|
88 |
void SendIdealPdcchMessage (void); |
|
89 |
||
90 |
||
7886 | 91 |
/** |
92 |
* |
|
93 |
* \return the Cell Identifier of this eNB |
|
94 |
*/ |
|
95 |
uint16_t GetCellId (); |
|
6705 | 96 |
|
97 |
private: |
|
98 |
bool DoSend (Ptr<Packet> packet, |
|
99 |
const Mac48Address& source, |
|
100 |
const Mac48Address& dest, |
|
101 |
uint16_t protocolNumber); |
|
102 |
||
103 |
void DoReceive (Ptr<Packet> p); |
|
104 |
||
7886 | 105 |
// Ptr<UeManager> m_ueManager; |
106 |
||
107 |
Ptr<LteEnbMac> m_mac; |
|
108 |
||
109 |
Ptr<EnbLtePhy> m_phy; |
|
6705 | 110 |
|
7886 | 111 |
Ptr<LteEnbRrc> m_rrc; |
112 |
||
113 |
Ptr<RrFfMacScheduler> m_scheduler; |
|
114 |
||
115 |
uint16_t m_cellId; /**< Cell Identifer. Part of the CGI, see TS 29.274, section 8.21.1 */ |
|
116 |
||
117 |
static uint16_t m_cellIdCounter; |
|
6705 | 118 |
}; |
119 |
||
120 |
} // namespace ns3 |
|
121 |
||
122 |
#endif /* ENB_NET_DEVICE_H */ |