5G-LENA nr-v3.3-120-gdac69c56
The 5G/NR module for the ns-3 simulator
Loading...
Searching...
No Matches
bandwidth-part-gnb.h
1// Copyright (c) 2017 Centre Tecnologic de Telecomunicacions de Catalunya (CTTC)
2//
3// SPDX-License-Identifier: GPL-2.0-only
4
5#ifndef COMPONENT_CARRIER_GNB_H
6#define COMPONENT_CARRIER_GNB_H
7
8#include "nr-component-carrier.h"
9#include "nr-gnb-phy.h"
10
11#include "ns3/nstime.h"
12#include "ns3/object.h"
13
14namespace ns3
15{
16
17class NrGnbMac;
18class NrMacScheduler;
19
27{
28 public:
33 static TypeId GetTypeId();
34
36
37 ~BandwidthPartGnb() override;
38
42 Ptr<NrGnbPhy> GetPhy();
43
47 Ptr<NrGnbMac> GetMac();
48
52 Ptr<NrMacScheduler> GetScheduler();
53
58 void SetPhy(Ptr<NrGnbPhy> s);
63 void SetMac(Ptr<NrGnbMac> s);
64
69 void SetNrMacScheduler(Ptr<NrMacScheduler> s);
70
71 void SetDlBandwidth(uint16_t bw) override
72 {
73 m_dlBandwidth = bw;
74 }
75
76 void SetUlBandwidth(uint16_t bw) override
77 {
78 m_ulBandwidth = bw;
79 }
80
89 void SetAsPrimary(bool primaryCarrier);
90
95 uint16_t GetCellId() const;
96
101 void SetCellId(uint16_t cellId);
102
103 protected:
107 void DoDispose() override;
108
109 private:
110 Ptr<NrGnbPhy> m_phy;
111 Ptr<NrGnbMac> m_mac;
112 Ptr<NrMacScheduler> m_scheduler;
113 uint16_t m_cellId{0};
114};
115
116} // namespace ns3
117
118#endif /* COMPONENT_CARRIER_H */
GNB bandwidth part representation.
void DoDispose() override
DoDispose method inherited from Object.
void SetPhy(Ptr< NrGnbPhy > s)
void SetUlBandwidth(uint16_t bw) override
Ptr< NrMacScheduler > GetScheduler()
void SetNrMacScheduler(Ptr< NrMacScheduler > s)
void SetCellId(uint16_t cellId)
void SetDlBandwidth(uint16_t bw) override
void SetAsPrimary(bool primaryCarrier)
Set this bandwidth part as primary.
void SetMac(Ptr< NrGnbMac > s)
static TypeId GetTypeId()
Get the type ID.
uint16_t m_dlBandwidth
downlink bandwidth in RBs *‍/
uint16_t m_ulBandwidth
uplink bandwidth in RBs *‍/