A Discrete-Event Network Simulator
API
he-operation.h
Go to the documentation of this file.
1 /* -*- Mode: C++; c-file-style: "gnu"; indent-tabs-mode:nil; -*- */
2 /*
3  * Copyright (c) 2017 Sébastien Deronne
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: Sébastien Deronne <sebastien.deronne@gmail.com>
19  */
20 
21 #ifndef HE_OPERATION_H
22 #define HE_OPERATION_H
23 
25 
26 namespace ns3 {
27 
38 {
39 public:
40  HeOperation ();
46  void SetHeSupported (uint8_t hesupported);
47 
53  void SetHeOperationParameters (uint32_t ctrl);
61  void SetMaxHeMcsPerNss (uint8_t nss, uint8_t maxHeMcs);
62 
68  uint32_t GetHeOperationParameters (void) const;
74  uint32_t GetBasicHeMcsAndNssSet (void) const;
75 
87  uint8_t GetInformationFieldSize () const;
101  uint8_t DeserializeInformationField (Buffer::Iterator start, uint8_t length);
118  uint16_t GetSerializedSize () const;
119 
120 
121 private:
122  //HE Operation Parameters fields
123  uint8_t m_bssColor;
125  uint8_t m_twtRequired;
131  uint8_t m_dualBeacon;
132 
133  //Basic HE-MCS and NSS Set
135 
136  //TODO: VHT Operation Information subfields not defined in the standard yet.
137 
139  uint8_t m_heSupported;
140 };
141 
142 std::ostream &operator << (std::ostream &os, const HeOperation &HeOperation);
143 std::istream &operator >> (std::istream &is, HeOperation &HeOperation);
144 
146 
147 } //namespace ns3
148 
149 #endif /* HE_OPERATION_H */
std::istream & operator>>(std::istream &is, Angles &a)
initialize a struct Angles from input
Definition: angles.cc:48
void SetHeSupported(uint8_t hesupported)
Set the HE supported information element.
Definition: he-operation.cc:47
uint8_t m_txBssidIndicator
TX BSSID indicator.
Definition: he-operation.h:129
uint8_t m_heSupported
This is used to decide whether this element should be added to the frame or not.
Definition: he-operation.h:139
def start()
Definition: core.py:1790
uint8_t m_maxBssidIndicator
max BSSID indicator
Definition: he-operation.h:128
uint32_t m_basicHeMcsAndNssSet
basic HE MCS NSS set
Definition: he-operation.h:134
uint8_t m_twtRequired
TWT required.
Definition: he-operation.h:125
iterator in a Buffer instance
Definition: buffer.h:98
void SetMaxHeMcsPerNss(uint8_t nss, uint8_t maxHeMcs)
Set the Basic HE-MCS and NSS field in the HE Operation information element by specifying the tuple (n...
Definition: he-operation.cc:91
Information element, as defined in 802.11-2007 standardThe IEEE 802.11 standard includes the notion o...
uint32_t GetBasicHeMcsAndNssSet(void) const
Return the Basic HE-MCS And Nss field in the HE Operation information element.
Definition: he-operation.cc:98
void SetHeOperationParameters(uint32_t ctrl)
Set the HE Operation Parameters field in the HE Operation information element.
Definition: he-operation.cc:61
void SerializeInformationField(Buffer::Iterator start) const
Serialize the information field.
uint8_t DeserializeInformationField(Buffer::Iterator start, uint8_t length)
Deserialize the information field.
std::ostream & operator<<(std::ostream &os, const Angles &a)
print a struct Angles to output
Definition: angles.cc:42
uint32_t GetHeOperationParameters(void) const
Return the HE Operation Parameters field in the HE Operation information element. ...
Definition: he-operation.cc:75
Every class exported by the ns3 library is enclosed in the ns3 namespace.
uint8_t GetInformationFieldSize() const
Return the information field size.
Definition: he-operation.cc:53
uint8_t m_dualBeacon
Dual Beacon.
Definition: he-operation.h:131
uint8_t m_bssColorDisabled
BSS color disabled.
Definition: he-operation.h:130
Buffer::Iterator Serialize(Buffer::Iterator start) const
This information element is a bit special in that it is only included if the STA is a HE STA...
uint8_t m_defaultPEDuration
default PE duration
Definition: he-operation.h:124
uint8_t m_bssColor
BSS color.
Definition: he-operation.h:123
uint8_t WifiInformationElementId
This type is used to represent an Information Element ID.
The HE Operation Information ElementThis class knows how to serialise and deserialise the HE Operatio...
Definition: he-operation.h:37
uint16_t GetSerializedSize() const
Return the serialized size of this HE Operations IE.
uint8_t m_partialBssColor
partial BSS color
Definition: he-operation.h:127
WifiInformationElementId ElementId() const
Return the element ID.
Definition: he-operation.cc:41
#define ATTRIBUTE_HELPER_HEADER(type)
Declare the attribute value, accessor and checkers for class type.
uint16_t m_heDurationBasedRtsThreshold
HE duration based RTS threshold.
Definition: he-operation.h:126