A Discrete-Event Network Simulator
API
Loading...
Searching...
No Matches
he-6ghz-band-capabilities.h
Go to the documentation of this file.
1/*
2 * Copyright (c) 2024
3 *
4 * This program is free software; you can redistribute it and/or modify
5 * it under the terms of the GNU General Public License version 2 as
6 * published by the Free Software Foundation;
7 *
8 * This program is distributed in the hope that it will be useful,
9 * but WITHOUT ANY WARRANTY; without even the implied warranty of
10 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
11 * GNU General Public License for more details.
12 *
13 * You should have received a copy of the GNU General Public License
14 * along with this program; if not, write to the Free Software
15 * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
16 *
17 * Author: Rami Abdallah <abdallah.rami@gmail.com>
18 */
19
20#ifndef HE_6GHZ_BAND_CAPABILITIES_H
21#define HE_6GHZ_BAND_CAPABILITIES_H
22
23#include "ns3/wifi-information-element.h"
24
25namespace ns3
26{
27
28/**
29 * \ingroup wifi
30 *
31 * The HE 6 GHz Band Capabilities (IEEE 802.11ax-2021 9.4.2.263)
32 */
34{
35 public:
37
38 WifiInformationElementId ElementId() const override;
40 void Print(std::ostream& os) const override;
41
42 /// Capabilities Information field
44 {
45 uint8_t m_minMpduStartSpacing : 3; ///< Minimum MPDU Start Spacing
46 uint8_t m_maxAmpduLengthExponent : 3; ///< Maximum A-MPDU Length Exponent (can
47 ///< also be set via convenient methods)
48 uint8_t m_maxMpduLength : 2; ///< Maximum MPDU Length (can also
49 ///< be set via convenient methods)
50 uint8_t : 1; ///< Reserved Bits
51 uint8_t m_smPowerSave : 2; ///< SM Power Save
52 uint8_t m_rdResponder : 1; ///< RD Responder
53 uint8_t m_rxAntennaPatternConsistency : 1; ///< Receive Antenna Pattern Consistency
54 uint8_t m_txAntennaPatternConsistency : 1; ///< Transmit Antenna Pattern Consistency
55 uint8_t : 2; ///< Reserved Bits
56 };
57
58 CapabilitiesInfo m_capabilitiesInfo; ///< capabilities field
59
60 /**
61 * Set the maximum AMPDU length.
62 *
63 * \param maxAmpduLength 2^(13 + x) - 1, x in the range 0 to 7
64 */
65 void SetMaxAmpduLength(uint32_t maxAmpduLength);
66 /**
67 * Return the maximum A-MPDU length.
68 *
69 * \return the maximum A-MPDU length in bytes
70 */
72
73 /**
74 * Set the maximum MPDU length.
75 *
76 * \param length the maximum MPDU length (3895, 7991 or 11454)
77 */
78 void SetMaxMpduLength(uint16_t length);
79 /**
80 * Get the maximum MPDU length.
81 *
82 * \return the maximum MPDU length in bytes
83 */
84 uint16_t GetMaxMpduLength() const;
85
86 private:
87 uint16_t GetInformationFieldSize() const override;
88 void SerializeInformationField(Buffer::Iterator start) const override;
89 uint16_t DeserializeInformationField(Buffer::Iterator start, uint16_t length) override;
90};
91
92} // namespace ns3
93
94#endif /* HE_6GHZ_BAND_CAPABILITY_H */
iterator in a Buffer instance
Definition: buffer.h:100
The HE 6 GHz Band Capabilities (IEEE 802.11ax-2021 9.4.2.263)
uint16_t GetInformationFieldSize() const override
Length of serialized information (i.e., the length of the body of the IE, not including the Element I...
uint32_t GetMaxAmpduLength() const
Return the maximum A-MPDU length.
uint16_t DeserializeInformationField(Buffer::Iterator start, uint16_t length) override
Deserialize information (i.e., the body of the IE, not including the Element ID and length octets)
void SetMaxAmpduLength(uint32_t maxAmpduLength)
Set the maximum AMPDU length.
void Print(std::ostream &os) const override
Generate human-readable form of IE.
WifiInformationElementId ElementIdExt() const override
Get the wifi information element ID extension.
void SerializeInformationField(Buffer::Iterator start) const override
Serialize information (i.e., the body of the IE, not including the Element ID and length octets)
uint16_t GetMaxMpduLength() const
Get the maximum MPDU length.
CapabilitiesInfo m_capabilitiesInfo
capabilities field
WifiInformationElementId ElementId() const override
Get the wifi information element ID.
void SetMaxMpduLength(uint16_t length)
Set the maximum MPDU length.
Information element, as defined in 802.11-2007 standard.
Every class exported by the ns3 library is enclosed in the ns3 namespace.
uint8_t WifiInformationElementId
This type is used to represent an Information Element ID.
uint8_t m_maxAmpduLengthExponent
Maximum A-MPDU Length Exponent (can also be set via convenient methods)
uint8_t m_maxMpduLength
Maximum MPDU Length (can also be set via convenient methods)
uint8_t m_minMpduStartSpacing
Minimum MPDU Start Spacing.
uint8_t m_rxAntennaPatternConsistency
Receive Antenna Pattern Consistency.
uint8_t m_txAntennaPatternConsistency
Transmit Antenna Pattern Consistency.