lora-device-address-generator.h
Go to the documentation of this file.
1 /* -*- Mode:C++; c-file-style:"gnu"; indent-tabs-mode:nil; -*- */
2 /*
3  * Copyright (c) 2017 University of Padova
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: Davide Magrin <magrinda@dei.unipd.it>
19  *
20  * Modified by: Bastien Tauran <bastien.tauran@viveris.fr>
21  */
22 
23 #ifndef LORA_DEVICE_ADDRESS_GENERATOR_H
24 #define LORA_DEVICE_ADDRESS_GENERATOR_H
25 
26 #include <ns3/lora-device-address.h>
27 #include <ns3/object.h>
28 
29 namespace ns3
30 {
31 
35 class LoraDeviceAddressGenerator : public Object
36 {
37  public:
38  static TypeId GetTypeId(void);
39 
49  LoraDeviceAddressGenerator(const uint8_t nwkId = 0, const uint32_t nwkAddr = 0);
50 
60 
72 
83 
84  private:
87 };
88 } // namespace ns3
89 #endif
This class generates sequential LoraDeviceAddress instances.
NwkID m_currentNwkId
The current Network Id value.
LoraDeviceAddress GetNextAddress(void)
Get the LoraDeviceAddress that will be allocated upon a call to NextAddress.
NwkAddr m_currentNwkAddr
The current Network Address value.
LoraDeviceAddress NextNetwork(void)
Get the first address from the next network.
LoraDeviceAddressGenerator(const uint8_t nwkId=0, const uint32_t nwkAddr=0)
Initialise the base NwkID and the first NwkAddr to be used by the generator.
LoraDeviceAddress NextAddress(void)
Allocate the next LoraDeviceAddress.
This class represents the device address of a LoraWAN End Device.
Class representing the Network Address component of a LoraDeviceAddress (25 bits)
Class representing the NetworkId component of a LoraDeviceAddress (7 bits).
SatArqSequenceNumber is handling the sequence numbers for the ARQ process.