satellite-random-access-container-conf.h
Go to the documentation of this file.
1 /* -*- Mode:C++; c-file-style:"gnu"; indent-tabs-mode:nil; -*- */
2 /*
3  * Copyright (c) 2014 Magister Solutions Ltd.
4  * Copyright (c) 2018 CNES
5  *
6  * This program is free software; you can redistribute it and/or modify
7  * it under the terms of the GNU General Public License version 2 as
8  * published by the Free Software Foundation;
9  *
10  * This program is distributed in the hope that it will be useful,
11  * but WITHOUT ANY WARRANTY; without even the implied warranty of
12  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
13  * GNU General Public License for more details.
14  *
15  * You should have received a copy of the GNU General Public License
16  * along with this program; if not, write to the Free Software
17  * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
18  *
19  * Author: Frans Laakso <frans.laakso@magister.fi>
20  * Author: Mathias Ettinger <mettinger@toulouse.viveris.fr>
21  */
22 
23 #ifndef SATELLITE_RANDOM_ACCESS_CONF_H
24 #define SATELLITE_RANDOM_ACCESS_CONF_H
25 
29 
30 #include <ns3/object.h>
31 #include <ns3/simulator.h>
32 #include <ns3/uinteger.h>
33 
34 #include <map>
35 
36 namespace ns3
37 {
38 
47 class SatRandomAccessConf : public Object
48 {
49  public:
54 
58  SatRandomAccessConf(Ptr<SatLowerLayerServiceConf> llsConf,
59  Ptr<SatSuperframeSeq> m_superframeSeq);
60 
64  virtual ~SatRandomAccessConf();
65 
70  static TypeId GetTypeId(void);
71 
77  Ptr<SatRandomAccessAllocationChannel> GetAllocationChannelConfiguration(
78  uint32_t allocationChannel);
79 
85  {
87  }
88 
95  uint32_t controlRandomizationIntervalInMilliSeconds)
96  {
98  controlRandomizationIntervalInMilliSeconds;
99  }
100 
106  {
108  }
109 
115  uint32_t GetAllocationChannelConfigurationId(uint32_t allocationChannel);
116 
122  {
124  }
125 
131  {
133  }
134 
139 
140  private:
144  std::map<uint32_t, Ptr<SatRandomAccessAllocationChannel>> m_allocationChannelConf;
145 
150 
156 
161 
166 
171 };
172 
173 } // namespace ns3
174 
175 #endif /* SATELLITE_RANDOM_ACCESS_CONF_H */
Class for random access configuration.
uint32_t m_allocationChannelCount
Number of available allocation channels.
void SetSlottedAlohaControlRandomizationIntervalInMilliSeconds(uint32_t controlRandomizationIntervalInMilliSeconds)
Function for setting the Slotted ALOHA control randomization interval.
uint32_t GetSlottedAlohaControlRandomizationIntervalInMilliSeconds()
Function for getting the Slotted ALOHA control randomization interval.
uint32_t GetAllocationChannelConfigurationId(uint32_t allocationChannel)
Function for retrieving the configuration ID of a given allocation channel.
uint32_t GetSlottedAlohaSignalingOverheadInBytes()
Function for getting the Slotted ALOHA signaling overhead in bytes.
uint32_t m_slottedAlohaControlRandomizationIntervalInMilliSeconds
Slotted ALOHA control randomization interval in milliseconds.
std::vector< uint32_t > m_configurationIdPerAllocationChannel
Mapping between an allocation channel and its associated configuration index.
void DoSlottedAlohaVariableSanityCheck()
Function for checking the Slotted ALOHA variable sanity.
uint32_t GetCrdsaSignalingOverheadInBytes()
Function for getting the CRDSA signaling overhead in bytes.
static TypeId GetTypeId(void)
NS-3 type id function.
Ptr< SatRandomAccessAllocationChannel > GetAllocationChannelConfiguration(uint32_t allocationChannel)
Function for returning the allocation channel specific RA configuration.
uint32_t m_crdsaSignalingOverheadInBytes
Defines the size of the CRDSA signaling overhead in bytes.
uint32_t GetNumOfAllocationChannelsConfigurations()
Function for getting the number of available allocation channels configurations.
uint32_t m_slottedAlohaSignalingOverheadInBytes
Defines the size of the Slotted ALOHA signaling overhead in bytes.
std::map< uint32_t, Ptr< SatRandomAccessAllocationChannel > > m_allocationChannelConf
Map containing the allocation channel configurations.
SatArqSequenceNumber is handling the sequence numbers for the ARQ process.