5G-LENA nr-v3.1-69-g2dd513a7
The 5G/NR module for the ns-3 simulator
|
A Channel access manager that sees the channel always free for transmitting. More...
#include "nr-ch-access-manager.h"
Public Member Functions | |
NrAlwaysOnAccessManager () | |
NrAlwaysOnAccessManager constructor. | |
~NrAlwaysOnAccessManager () override | |
destructor | |
void | Cancel () override |
Cancel a previously invoked request for accessing the channel. | |
void | RequestAccess () override |
RequestAccess. | |
void | SetAccessDeniedCallback (const AccessDeniedCallback &cb) override |
Set Access-Denied Callback. | |
void | SetAccessGrantedCallback (const AccessGrantedCallback &cb) override |
Set Access-Granted Callback. | |
Public Member Functions inherited from ns3::NrChAccessManager | |
NrChAccessManager () | |
ChannelAccessManager constructor. | |
~NrChAccessManager () override | |
~ChannelAccessManager | |
Time | GetGrantDuration () const |
Get grant duration time. | |
Ptr< NrGnbMac > | GetNrGnbMac () |
Getter for MAC instance to which is connected this channel access manager. | |
Ptr< NrSpectrumPhy > | GetNrSpectrumPhy () |
Getter for spectrum phy instance to which is connected this channel access manager. | |
void | SetGrantDuration (Time grantDuration) |
Set duration of grant for transmission. | |
virtual void | SetNrGnbMac (Ptr< NrGnbMac > mac) |
Set MAC instance for this channel access manager. | |
virtual void | SetNrSpectrumPhy (Ptr< NrSpectrumPhy > spectrumPhy) |
Set spectrum phy instance for this channel access manager. | |
Static Public Member Functions | |
static TypeId | GetTypeId () |
Get the type ID. | |
Static Public Member Functions inherited from ns3::NrChAccessManager | |
static TypeId | GetTypeId () |
Get the type ID. | |
Additional Inherited Members | |
Public Types inherited from ns3::NrChAccessManager | |
typedef std::function< void()> | AccessDeniedCallback |
A function that signal that the channel is denied and the request should be retried. | |
typedef std::function< void(const Time &time)> | AccessGrantedCallback |
A function that signal that the channel has been earned. | |
A Channel access manager that sees the channel always free for transmitting.
This channel access manager is installed by default in NR instances.
This is the CAM that is created by default. However, if you want to set it manually, you can invoke the helper function before installing the gnb:
nrHelper->SetGnbChannelAccessManagerTypeId (NrAlwaysOnAccessManager::GetTypeId()); ... nrHelper->InstallGnb ...
or the UE-side:
nrHelper->SetUeChannelAccessManagerTypeId (NrAlwaysOnAccessManager::GetTypeId()); ... nrHelper->InstallUe ...
The type of the channel access manager cannot be changed after the helper has installed the UE or the GNB node.
Introspection did not find any typical Config paths.
No Attributes are defined for this type.
No TraceSources are defined for this type.
Size of this type is 104 bytes (on a 64-bit architecture).
Definition at line 169 of file nr-ch-access-manager.h.
ns3::NrAlwaysOnAccessManager::NrAlwaysOnAccessManager | ( | ) |
NrAlwaysOnAccessManager constructor.
Definition at line 97 of file nr-ch-access-manager.cc.
|
override |
destructor
Definition at line 103 of file nr-ch-access-manager.cc.
|
overridevirtual |
Cancel a previously invoked request for accessing the channel.
Implements ns3::NrChAccessManager.
Definition at line 135 of file nr-ch-access-manager.cc.
|
static |
Get the type ID.
Definition at line 88 of file nr-ch-access-manager.cc.
Referenced by ns3::NrHelper::NrHelper().
|
overridevirtual |
RequestAccess.
When the channel is granted, the callback set with SetAccessGrantedCallback() will be called.
Implements ns3::NrChAccessManager.
Definition at line 109 of file nr-ch-access-manager.cc.
|
overridevirtual |
Set Access-Denied Callback.
cb | the callback to invoke when the channel access is denied |
Implements ns3::NrChAccessManager.
Definition at line 127 of file nr-ch-access-manager.cc.
|
overridevirtual |
Set Access-Granted Callback.
cb | the callback to invoke when the channel access is granted |
Implements ns3::NrChAccessManager.
Definition at line 120 of file nr-ch-access-manager.cc.