A Discrete-Event Network Simulator
API
ctrl-headers.h
Go to the documentation of this file.
1 /* -*- Mode:C++; c-file-style:"gnu"; indent-tabs-mode:nil; -*- */
2 /*
3  * Copyright (c) 2009 MIRKO BANCHI
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: Mirko Banchi <mk.banchi@gmail.com>
19  */
20 
21 #ifndef CTRL_HEADERS_H
22 #define CTRL_HEADERS_H
23 
24 #include <list>
25 #include <vector>
26 #include "ns3/header.h"
27 #include "block-ack-type.h"
28 #include "ns3/he-ru.h"
29 #include "ns3/mac48-address.h"
30 
31 namespace ns3 {
32 
33 class WifiTxVector;
34 enum AcIndex : uint8_t;
35 
49 {
50 public:
57  static TypeId GetTypeId (void);
58  TypeId GetInstanceTypeId (void) const;
59  void Print (std::ostream &os) const;
60  uint32_t GetSerializedSize (void) const;
61  void Serialize (Buffer::Iterator start) const;
63 
69  void SetHtImmediateAck (bool immediateAck);
75  void SetType (BlockAckReqType type);
81  void SetTidInfo (uint8_t tid);
88  void SetStartingSequence (uint16_t seq);
89 
96  bool MustSendHtImmediateAck (void) const;
102  BlockAckReqType GetType (void) const;
108  uint8_t GetTidInfo (void) const;
114  uint16_t GetStartingSequence (void) const;
122  bool IsBasic (void) const;
130  bool IsCompressed (void) const;
137  bool IsExtendedCompressed (void) const;
144  bool IsMultiTid (void) const;
145 
151  uint16_t GetStartingSequenceControl (void) const;
152 
153 
154 private:
161  void SetStartingSequenceControl (uint16_t seqControl);
167  uint16_t GetBarControl (void) const;
173  void SetBarControl (uint16_t bar);
174 
183  uint16_t m_tidInfo;
184  uint16_t m_startingSeq;
185 };
186 
187 
201 {
202 public:
209  static TypeId GetTypeId (void);
210  TypeId GetInstanceTypeId (void) const;
211  void Print (std::ostream &os) const;
212  uint32_t GetSerializedSize (void) const;
213  void Serialize (Buffer::Iterator start) const;
215 
221  void SetHtImmediateAck (bool immediateAck);
227  void SetType (BlockAckType type);
237  void SetTidInfo (uint8_t tid, std::size_t index = 0);
247  void SetStartingSequence (uint16_t seq, std::size_t index = 0);
248 
255  bool MustSendHtImmediateAck (void) const;
261  BlockAckType GetType (void) const;
271  uint8_t GetTidInfo (std::size_t index = 0) const;
280  uint16_t GetStartingSequence (std::size_t index = 0) const;
287  bool IsBasic (void) const;
294  bool IsCompressed (void) const;
301  bool IsExtendedCompressed (void) const;
308  bool IsMultiTid (void) const;
315  bool IsMultiSta (void) const;
316 
324  void SetAid11 (uint16_t aid, std::size_t index);
332  uint16_t GetAid11 (std::size_t index) const;
340  void SetAckType (bool type, std::size_t index);
348  bool GetAckType (std::size_t index) const;
357  void SetUnassociatedStaAddress (const Mac48Address& ra, std::size_t index);
366  Mac48Address GetUnassociatedStaAddress (std::size_t index) const;
373  std::size_t GetNPerAidTidInfoSubfields (void) const;
382  std::vector<uint32_t> FindPerAidTidInfoWithAid (uint16_t aid) const;
383 
392  void SetReceivedPacket (uint16_t seq, std::size_t index = 0);
400  void SetReceivedFragment (uint16_t seq, uint8_t frag);
411  bool IsPacketReceived (uint16_t seq, std::size_t index = 0) const;
422  bool IsFragmentReceived (uint16_t seq, uint8_t frag) const;
423 
432  uint16_t GetStartingSequenceControl (std::size_t index = 0) const;
441  void SetStartingSequenceControl (uint16_t seqControl, std::size_t index = 0);
450  const std::vector<uint8_t>& GetBitmap (std::size_t index = 0) const;
451 
456  void ResetBitmap (std::size_t index = 0);
457 
458 
459 private:
465  uint16_t GetBaControl (void) const;
471  void SetBaControl (uint16_t ba);
472 
481  Buffer::Iterator SerializeBitmap (Buffer::Iterator start, std::size_t index = 0) const;
490  Buffer::Iterator DeserializeBitmap (Buffer::Iterator start, std::size_t index = 0);
491 
507  uint16_t IndexInBitmap (uint16_t seq, std::size_t index = 0) const;
508 
518  bool IsInBitmap (uint16_t seq, std::size_t index = 0) const;
519 
528  uint16_t m_tidInfo;
529 
539  {
540  uint16_t m_aidTidInfo;
541  uint16_t m_startingSeq;
544  std::vector<uint8_t> m_bitmap;
546  };
548 
549  std::vector<BaInfoInstance> m_baInfo;
550 };
551 
552 
557 enum TriggerFrameType : uint8_t
558 {
559  BASIC_TRIGGER = 0, // Basic
560  BFRP_TRIGGER = 1, // Beamforming Report Poll
561  MU_BAR_TRIGGER = 2, // Multi-User Block Ack Request
562  MU_RTS_TRIGGER = 3, // Multi-User Request To Send
563  BSRP_TRIGGER = 4, // Buffer Status Report Poll
564  GCR_MU_BAR_TRIGGER = 5, // Groupcast with Retries MU-BAR
565  BQRP_TRIGGER = 6, // Bandwidth Query Report Poll
566  NFRP_TRIGGER = 7 // NDP Feedback Report Poll
567 };
568 
569 
579 {
580 public:
586  CtrlTriggerUserInfoField (uint8_t triggerType);
603  void Print (std::ostream &os) const;
609  uint32_t GetSerializedSize (void) const;
631  TriggerFrameType GetType (void) const;
639  void SetAid12 (uint16_t aid);
645  uint16_t GetAid12 (void) const;
652  bool HasRaRuForAssociatedSta (void) const;
659  bool HasRaRuForUnassociatedSta (void) const;
665  void SetRuAllocation (HeRu::RuSpec ru);
671  HeRu::RuSpec GetRuAllocation (void) const;
677  void SetUlFecCodingType (bool ldpc);
683  bool GetUlFecCodingType (void) const;
689  void SetUlMcs (uint8_t mcs);
695  uint8_t GetUlMcs (void) const;
701  void SetUlDcm (bool dcm);
707  bool GetUlDcm (void) const;
716  void SetSsAllocation (uint8_t startingSs, uint8_t nSs);
722  uint8_t GetStartingSs (void) const;
728  uint8_t GetNss (void) const;
737  void SetRaRuInformation (uint8_t nRaRu, bool moreRaRu);
744  uint8_t GetNRaRus (void) const;
752  bool GetMoreRaRu (void) const;
757  void SetUlTargetRssiMaxTxPower (void);
764  void SetUlTargetRssi (int8_t dBm);
772  bool IsUlTargetRssiMaxTxPower (void) const;
779  int8_t GetUlTargetRssi (void) const;
787  void SetBasicTriggerDepUserInfo (uint8_t spacingFactor, uint8_t tidLimit, AcIndex prefAc);
794  uint8_t GetMpduMuSpacingFactor (void) const;
801  uint8_t GetTidAggregationLimit (void) const;
808  AcIndex GetPreferredAc (void) const;
829 
830 private:
831  uint16_t m_aid12;
832  uint8_t m_ruAllocation;
834  uint8_t m_ulMcs;
835  bool m_ulDcm;
836  union
837  {
838  struct
839  {
840  uint8_t startingSs;
841  uint8_t nSs;
842  } ssAllocation;
843  struct
844  {
845  uint8_t nRaRu;
846  bool moreRaRu;
847  } raRuInformation;
848  } m_bits26To31;
849  uint8_t m_ulTargetRssi;
850  uint8_t m_triggerType;
853 };
854 
855 
879 class CtrlTriggerHeader : public Header
880 {
881 public:
898  CtrlTriggerHeader (TriggerFrameType type, const WifiTxVector& txVector);
911  static TypeId GetTypeId (void);
912  TypeId GetInstanceTypeId (void) const;
913  void Print (std::ostream &os) const;
914  uint32_t GetSerializedSize (void) const;
915  void Serialize (Buffer::Iterator start) const;
917 
923  void SetType (TriggerFrameType type);
929  TriggerFrameType GetType (void) const;
935  const char * GetTypeString (void) const;
942  static const char * GetTypeString (TriggerFrameType type);
949  bool IsBasic (void) const;
956  bool IsBfrp (void) const;
963  bool IsMuBar (void) const;
970  bool IsMuRts (void) const;
977  bool IsBsrp (void) const;
984  bool IsGcrMuBar (void) const;
991  bool IsBqrp (void) const;
998  bool IsNfrp (void) const;
1004  void SetUlLength (uint16_t len);
1010  uint16_t GetUlLength (void) const;
1019  WifiTxVector GetHeTbTxVector (uint16_t staId) const;
1025  void SetMoreTF (bool more);
1031  bool GetMoreTF (void) const;
1037  void SetCsRequired (bool cs);
1043  bool GetCsRequired (void) const;
1049  void SetUlBandwidth (uint16_t bw);
1055  uint16_t GetUlBandwidth (void) const;
1066  void SetGiAndLtfType (uint16_t guardInterval, uint8_t ltfType);
1072  uint16_t GetGuardInterval (void) const;
1078  uint8_t GetLtfType (void) const;
1084  void SetApTxPower (int8_t power);
1091  int8_t GetApTxPower (void) const;
1097  void SetUlSpatialReuse (uint16_t sr);
1103  uint16_t GetUlSpatialReuse (void) const;
1111 
1129 
1131  typedef std::list<CtrlTriggerUserInfoField>::const_iterator ConstIterator;
1132 
1134  typedef std::list<CtrlTriggerUserInfoField>::iterator Iterator;
1135 
1141  ConstIterator begin (void) const;
1147  ConstIterator end (void) const;
1153  Iterator begin (void);
1159  Iterator end (void);
1165  std::size_t GetNUserInfoFields (void) const;
1176  ConstIterator FindUserInfoWithAid (ConstIterator start, uint16_t aid12) const;
1185  ConstIterator FindUserInfoWithAid (uint16_t aid12) const;
1232  bool IsValid (void) const;
1233 
1234 private:
1238  uint8_t m_triggerType;
1239  uint16_t m_ulLength;
1240  bool m_moreTF;
1242  uint8_t m_ulBandwidth;
1243  uint8_t m_giAndLtfType;
1244  uint8_t m_apTxPower;
1245  uint16_t m_ulSpatialReuse;
1246 
1249  std::list<CtrlTriggerUserInfoField> m_userInfoFields;
1250 };
1251 
1252 } //namespace ns3
1253 
1254 #endif /* CTRL_HEADERS_H */
Protocol header serialization and deserialization.
Definition: header.h:42
CtrlTriggerUserInfoField(uint8_t triggerType)
Constructor.
TypeId GetInstanceTypeId(void) const
Get the most derived TypeId for this Object.
Definition: ctrl-headers.cc:59
ConstIterator FindUserInfoWithRaRuUnassociated(void) const
Get a const iterator pointing to the first User Info field found which allocates a Random Access RU f...
uint8_t m_ulBandwidth
UL BW subfield.
bool GetCsRequired(void) const
Get the CS Required subfield of the Common Info field.
bool IsUlTargetRssiMaxTxPower(void) const
Return true if the UL Target RSSI subfield indicates to the station to transmit an HE TB PPDU respons...
const std::vector< uint8_t > & GetBitmap(std::size_t index=0) const
Return a const reference to the bitmap from the BlockAck response header.
void SetType(TriggerFrameType type)
Set the Trigger frame type.
uint8_t nRaRu
Number of Random Access RUs.
Definition: ctrl-headers.h:845
void SetAckType(bool type, std::size_t index)
For Multi-STA Block Acks, set the Ack Type subfield of the Per AID TID Info subfield identified by th...
const char * GetTypeString(void) const
Return a string corresponding to the Trigger Frame type.
uint16_t GetBaControl(void) const
Return the Block Ack control.
Headers for Trigger frames.
Definition: ctrl-headers.h:879
uint8_t m_ulTargetRssi
Expected receive signal power.
Definition: ctrl-headers.h:849
This class mimics the TXVECTOR which is to be passed to the PHY in order to define the parameters whi...
void SetMoreTF(bool more)
Set the More TF subfield of the Common Info field.
uint8_t m_ulMcs
MCS to be used by the addressed station.
Definition: ctrl-headers.h:834
uint8_t GetNRaRus(void) const
Get the number of contiguous RUs for Random Access.
struct ns3::CtrlTriggerUserInfoField::@72::@73 ssAllocation
Used when AID12 is neither 0 nor 2045.
uint8_t m_triggerType
Common Info field.
uint16_t m_aid12
Association ID of the addressed station.
Definition: ctrl-headers.h:831
AcIndex
This enumeration defines the Access Categories as an enumeration with values corresponding to the AC ...
Definition: qos-utils.h:58
bool IsInBitmap(uint16_t seq, std::size_t index=0) const
Check if sequence number seq can be acknowledged in the bitmap.
CtrlBAckRequestHeader m_muBarTriggerDependentUserInfo
MU-BAR variant of Trigger Dependent User Info subfield.
Definition: ctrl-headers.h:852
bool IsMuRts(void) const
Check if this is a MU-RTS Trigger frame.
uint8_t startingSs
Starting spatial stream.
Definition: ctrl-headers.h:840
def start()
Definition: core.py:1855
uint32_t GetSerializedSize(void) const
void SetGiAndLtfType(uint16_t guardInterval, uint8_t ltfType)
Set the GI And LTF Type subfield of the Common Info field.
uint8_t GetUlMcs(void) const
Get the UL MCS subfield, which indicates the MCS of the solicited HE TB PPDU.
bool GetUlFecCodingType(void) const
Get the UL FEC Coding Type subfield, which indicates whether BCC or LDPC is used. ...
uint8_t m_apTxPower
Tx Power used by AP to transmit the Trigger Frame.
void Print(std::ostream &os) const
Print the content of this User Info field.
void SetReceivedPacket(uint16_t seq, std::size_t index=0)
Record in the bitmap that the packet with the given sequence number was received. ...
void SetBarControl(uint16_t bar)
Set the Block Ack control.
bool HasRaRuForUnassociatedSta(void) const
Check if this User Info field allocates a Random Access RU for stations not associated with the AP th...
uint16_t GetAid12(void) const
Get the value of the AID12 subfield.
bool IsValid(void) const
Check the validity of this Trigger frame.
std::list< CtrlTriggerUserInfoField > m_userInfoFields
List of User Info fields.
uint16_t GetAid11(std::size_t index) const
For Multi-STA Block Acks, get the AID11 subfield of the Per AID TID Info subfield identified by the g...
uint32_t GetSerializedSize(void) const
Get the expected size of this User Info field.
void SetRaRuInformation(uint8_t nRaRu, bool moreRaRu)
Set the RA-RU Information subfield, which is present when the AID12 subfield is 0 or 2045...
void SetHtImmediateAck(bool immediateAck)
Enable or disable HT immediate Ack.
void SetUlTargetRssi(int8_t dBm)
Set the UL Target RSSI subfield to indicate the expected receive signal power in dBm.
std::vector< BaInfoInstance > m_baInfo
BA Information field.
Definition: ctrl-headers.h:549
uint8_t m_basicTriggerDependentUserInfo
Basic Trigger variant of Trigger Dependent User Info subfield.
Definition: ctrl-headers.h:851
std::list< CtrlTriggerUserInfoField >::const_iterator ConstIterator
User Info fields list const iterator.
std::size_t GetNPerAidTidInfoSubfields(void) const
For Multi-STA Block Acks, get the number of Per AID TID Info subfields included in this Block Ack...
bool IsGcrMuBar(void) const
Check if this is a Groupcast with Retries (GCR) MU-BAR Trigger frame.
bool GetMoreTF(void) const
Get the More TF subfield of the Common Info field.
void SetCsRequired(bool cs)
Set the CS Required subfield of the Common Info field.
The different BlockAckRequest variants.
void SetUnassociatedStaAddress(const Mac48Address &ra, std::size_t index)
For Multi-STA Block Acks, set the RA subfield of the Per AID TID Info subfield (with AID11 subfield e...
void SetUlFecCodingType(bool ldpc)
Set the UL FEC Coding Type subfield, which indicates whether BCC or LDPC is used. ...
bool m_baAckPolicy
The LSB bit of the BA control field is used only for the HT (High Throughput) delayed block ack confi...
Definition: ctrl-headers.h:526
void Serialize(Buffer::Iterator start) const
void SetAid11(uint16_t aid, std::size_t index)
For Multi-STA Block Acks, set the AID11 subfield of the Per AID TID Info subfield identified by the g...
bool IsExtendedCompressed(void) const
Check if the current BA policy is Extended Compressed Block Ack.
uint8_t m_triggerType
Trigger frame type.
Definition: ctrl-headers.h:850
uint16_t GetStartingSequenceControl(std::size_t index=0) const
Return the value of the Starting Sequence Control subfield.
Mac48Address m_ra
RA subfield (address of an unassociated station) for Multi-STA; reserved for other variants...
Definition: ctrl-headers.h:545
CtrlTriggerUserInfoField & operator=(const CtrlTriggerUserInfoField &userInfo)
Copy assignment operator.
uint8_t GetStartingSs(void) const
Get the starting spatial stream.
bool IsBasic(void) const
Check if the current BA policy is Basic Block Ack.
iterator in a Buffer instance
Definition: buffer.h:98
uint8_t GetTidInfo(void) const
Return the Traffic ID (TID).
void SetMuBarTriggerDepUserInfo(const CtrlBAckRequestHeader &bar)
Set the Trigger Dependent User Info subfield for the MU-BAR variant of Trigger frames, which includes a BAR Control subfield and a BAR Information subfield.
void SetBasicTriggerDepUserInfo(uint8_t spacingFactor, uint8_t tidLimit, AcIndex prefAc)
Set the Trigger Dependent User Info subfield for Basic Trigger frames.
uint32_t GetSerializedSize(void) const
static TypeId GetTypeId(void)
Get the type ID.
bool m_csRequired
Carrier Sense required.
TypeId GetInstanceTypeId(void) const
Get the most derived TypeId for this Object.
bool IsCompressed(void) const
Check if the current BA policy is Compressed Block Ack.
bool MustSendHtImmediateAck(void) const
Check if the current Ack Policy is immediate.
uint16_t m_startingSeq
Block Ack Starting Sequence Control subfield.
Definition: ctrl-headers.h:543
TriggerFrameType
The different Trigger frame types.
Definition: ctrl-headers.h:557
bool GetMoreRaRu(void) const
Return true if more RA-RUs are allocated in subsequent Trigger frames that are sent before the end of...
RU Specification.
Definition: he-ru.h:64
uint8_t GetMpduMuSpacingFactor(void) const
Get the MPDU MU spacing factor.
void SetUlTargetRssiMaxTxPower(void)
Set the UL Target RSSI subfield to indicate to the station to transmit an HE TB PPDU response at its ...
uint16_t GetGuardInterval(void) const
Get the guard interval duration (in nanoseconds) of the solicited HE TB PPDU.
bool m_ulDcm
whether or not to use Dual Carrier Modulation
Definition: ctrl-headers.h:835
bool m_moreTF
True if a subsequent Trigger frame follows.
void SetType(BlockAckReqType type)
Set the BlockAckRequest type.
bool m_barAckPolicy
The LSB bit of the BAR control field is used only for the HT (High Throughput) delayed block ack conf...
Definition: ctrl-headers.h:181
uint16_t GetStartingSequence(std::size_t index=0) const
For Block Ack variants other than Multi-STA Block Ack, get the starting sequence number.
std::vector< uint32_t > FindPerAidTidInfoWithAid(uint16_t aid) const
For Multi-STA Block Acks, get the indices of the Per AID TID Info subfields carrying the given AID in...
void Print(std::ostream &os) const
Definition: ctrl-headers.cc:65
void SetStartingSequence(uint16_t seq, std::size_t index=0)
For Block Ack variants other than Multi-STA Block Ack, set the starting sequence number to the given ...
uint16_t IndexInBitmap(uint16_t seq, std::size_t index=0) const
This function is used to correctly index in both bitmap and compressed bitmap, one bit or one block o...
uint16_t m_startingSeq
starting seq
Definition: ctrl-headers.h:184
uint8_t GetLtfType(void) const
Get the LTF type of the solicited HE TB PPDU.
void SetAid12(uint16_t aid)
Set the AID12 subfield, which carries the 12 LSBs of the AID of the station for which this User Info ...
void Print(std::ostream &os) const
bool HasRaRuForAssociatedSta(void) const
Check if this User Info field allocates a Random Access RU for stations associated with the AP that t...
CtrlTriggerHeader & operator=(const CtrlTriggerHeader &trigger)
Copy assignment operator.
BlockAckReqType m_barType
BAR type.
Definition: ctrl-headers.h:182
const CtrlBAckRequestHeader & GetMuBarTriggerDepUserInfo(void) const
Get the Trigger Dependent User Info subfield for the MU-BAR variant of Trigger frames, which includes a BAR Control subfield and a BAR Information subfield.
bool IsMultiSta(void) const
Check if the BlockAck frame variant is Multi-STA Block Ack.
Headers for BlockAck response.
Definition: ctrl-headers.h:200
uint32_t GetSerializedSize(void) const
Definition: ctrl-headers.cc:71
static TypeId GetTypeId(void)
Get the type ID.
Definition: ctrl-headers.cc:48
uint32_t Deserialize(Buffer::Iterator start)
uint16_t m_tidInfo
TID info (reserved if Multi-STA Block Ack)
Definition: ctrl-headers.h:528
bool IsCompressed(void) const
Check if the current Ack Policy is Compressed Block Ack and not multi-TID.
bool IsExtendedCompressed(void) const
Check if the current Ack Policy is Extended Compressed Block Ack.
Buffer::Iterator Deserialize(Buffer::Iterator start)
Deserialize the User Info field from the given buffer.
TriggerFrameType GetType(void) const
Get the Trigger Frame type.
BlockAckReqType GetType(void) const
Return the BlockAckRequest type.
void SetStartingSequenceControl(uint16_t seqControl, std::size_t index=0)
Set the Starting Sequence Control subfield with the given sequence control value. ...
uint16_t GetUlBandwidth(void) const
Get the bandwidth of the solicited HE TB PPDU.
uint32_t Deserialize(Buffer::Iterator start)
void ResetBitmap(std::size_t index=0)
Reset the bitmap to 0.
bool IsNfrp(void) const
Check if this is a NDP Feedback Report Poll Trigger frame.
void SetTidInfo(uint8_t tid)
Set Traffic ID (TID).
ConstIterator begin(void) const
Get a const iterator pointing to the first User Info field in the list.
Every class exported by the ns3 library is enclosed in the ns3 namespace.
Mac48Address GetUnassociatedStaAddress(std::size_t index) const
For Multi-STA Block Acks, get the RA subfield of the Per AID TID Info subfield (with AID11 subfield e...
bool moreRaRu
More RA-RU in subsequent Trigger frames.
Definition: ctrl-headers.h:846
static TypeId GetTypeId(void)
Get the type ID.
void SetType(BlockAckType type)
Set the block ack type.
uint8_t GetTidInfo(std::size_t index=0) const
For Block Ack variants other than Multi-STA Block Ack, get the TID_INFO subfield of the BA Control fi...
bool IsMultiTid(void) const
Check if the current Ack Policy has Multi-TID Block Ack.
an EUI-48 address
Definition: mac48-address.h:43
bool IsBasic(void) const
Check if the current Ack Policy is Basic Block Ack (i.e.
uint16_t GetStartingSequence(void) const
Return the starting sequence number.
void SetUlBandwidth(uint16_t bw)
Set the bandwidth of the solicited HE TB PPDU.
uint8_t m_ruAllocation
RU Allocation.
Definition: ctrl-headers.h:832
BlockAckType m_baType
BA type.
Definition: ctrl-headers.h:527
uint8_t nSs
Number of spatial streams.
Definition: ctrl-headers.h:841
The following structure can hold the BA Information field for the Basic and Compressed variants...
Definition: ctrl-headers.h:538
uint8_t GetTidAggregationLimit(void) const
Get the TID Aggregation Limit.
bool IsBqrp(void) const
Check if this is a Bandwidth Query Report Poll Trigger frame.
ConstIterator FindUserInfoWithRaRuAssociated(void) const
Get a const iterator pointing to the first User Info field found which allocates a Random Access RU f...
User Info field of Trigger frames.
Definition: ctrl-headers.h:578
uint8_t GetNss(void) const
Get the number of spatial streams.
bool IsFragmentReceived(uint16_t seq, uint8_t frag) const
Check if the packet with the given sequence number and fragment number was acknowledged in this Block...
std::size_t GetNUserInfoFields(void) const
Get the number of User Info fields in this Trigger Frame.
void SetUlSpatialReuse(uint16_t sr)
Set the UL Spatial Reuse subfield of the Common Info field.
void SetReceivedFragment(uint16_t seq, uint8_t frag)
Set the bitmap that the packet with the given sequence number and fragment number was received...
TypeId GetInstanceTypeId(void) const
Get the most derived TypeId for this Object.
bool IsMuBar(void) const
Check if this is a MU-BAR Trigger frame.
bool IsBsrp(void) const
Check if this is a Buffer Status Report Poll Trigger frame.
TriggerFrameType GetType(void) const
Get the type of the Trigger Frame this User Info field belongs to.
void SetApTxPower(int8_t power)
Set the AP TX Power subfield of the Common Info field.
void SetRuAllocation(HeRu::RuSpec ru)
Set the RU Allocation subfield according to the specified RU.
void SetStartingSequenceControl(uint16_t seqControl)
Set the starting sequence control with the given sequence control value.
uint16_t GetBarControl(void) const
Return the Block Ack control.
The different BlockAck variants.
bool GetAckType(std::size_t index) const
For Multi-STA Block Acks, get the Ack Type subfield of the Per AID TID Info subfield identified by th...
bool GetUlDcm(void) const
Get the UL DCM subfield, which indicates whether or not DCM is used.
CtrlTriggerHeader GetCommonInfoField(void) const
Get a copy of the Common Info field of this Trigger frame.
void SetSsAllocation(uint8_t startingSs, uint8_t nSs)
Set the SS Allocation subfield, which is present when the AID12 subfield is neither 0 nor 2045...
CtrlTriggerUserInfoField & AddUserInfoField(void)
Append a new User Info field to this Trigger frame and return a non-const reference to it...
uint32_t Deserialize(Buffer::Iterator start)
Buffer::Iterator SerializeBitmap(Buffer::Iterator start, std::size_t index=0) const
Serialize bitmap to the given buffer.
uint16_t m_tidInfo
TID info.
Definition: ctrl-headers.h:183
std::list< CtrlTriggerUserInfoField >::iterator Iterator
User Info fields list iterator.
bool IsMultiTid(void) const
Check if the current BA policy is Multi-TID Block Ack.
Buffer::Iterator DeserializeBitmap(Buffer::Iterator start, std::size_t index=0)
Deserialize bitmap from the given buffer.
void SetHtImmediateAck(bool immediateAck)
Enable or disable HT immediate Ack.
void Print(std::ostream &os) const
Buffer::Iterator Serialize(Buffer::Iterator start) const
Serialize the User Info field to the given buffer.
ConstIterator FindUserInfoWithAid(ConstIterator start, uint16_t aid12) const
Get a const iterator pointing to the first User Info field found (starting from the one pointed to by...
WifiTxVector GetHeTbTxVector(uint16_t staId) const
Get the TX vector that the station with the given STA-ID will use to send the HE TB PPDU solicited by...
std::vector< uint8_t > m_bitmap
block ack bitmap
Definition: ctrl-headers.h:544
BlockAckType GetType(void) const
Return the block ack type ID.
bool IsBfrp(void) const
Check if this is a Beamforming Report Poll Trigger frame.
uint8_t m_giAndLtfType
GI And LTF Type subfield.
uint16_t GetUlSpatialReuse(void) const
Get the UL Spatial Reuse subfield of the Common Info field.
struct ns3::CtrlTriggerUserInfoField::@72::@74 raRuInformation
Used when AID12 is 0 or 2045.
void SetUlMcs(uint8_t mcs)
Set the UL MCS subfield, which indicates the MCS of the solicited HE TB PPDU.
void Serialize(Buffer::Iterator start) const
Definition: ctrl-headers.cc:93
void SetUlLength(uint16_t len)
Set the UL Length subfield of the Common Info field.
int8_t GetApTxPower(void) const
Get the power value (dBm) indicated by the AP TX Power subfield of the Common Info field...
ConstIterator end(void) const
Get a const iterator indicating past-the-last User Info field in the list.
uint16_t GetUlLength(void) const
Get the UL Length subfield of the Common Info field.
bool IsPacketReceived(uint16_t seq, std::size_t index=0) const
Check if the packet with the given sequence number was acknowledged in this BlockAck response...
Headers for BlockAckRequest.
Definition: ctrl-headers.h:48
a unique identifier for an interface.
Definition: type-id.h:58
void SetStartingSequence(uint16_t seq)
Set the starting sequence number from the given raw sequence control field.
union ns3::CtrlTriggerUserInfoField::@72 m_bits26To31
Fields occupying bits 26-31 in the User Info field.
uint16_t GetStartingSequenceControl(void) const
Return the starting sequence control.
bool MustSendHtImmediateAck(void) const
Check if the current Ack Policy is immediate.
HeRu::RuSpec GetRuAllocation(void) const
Get the RU specified by the RU Allocation subfield.
bool IsBasic(void) const
Check if this is a Basic Trigger frame.
~CtrlTriggerUserInfoField()
Destructor.
uint16_t m_ulLength
Value for the L-SIG Length field.
void SetTidInfo(uint8_t tid, std::size_t index=0)
For Block Ack variants other than Multi-STA Block Ack, set the TID_INFO subfield of the BA Control fi...
uint16_t m_ulSpatialReuse
Value for the Spatial Reuse field in HE-SIG-A.
uint16_t m_aidTidInfo
Reserved for Basic and Compressed Per TID Info subfield for Multi-TID AID TID Info subfield for Multi...
Definition: ctrl-headers.h:540
AcIndex GetPreferredAc(void) const
Get the Preferred AC subfield.
bool m_ulFecCodingType
UL FEC Coding Type.
Definition: ctrl-headers.h:833
void SetUlDcm(bool dcm)
Set the UL DCM subfield, which indicates whether or not DCM is used.
void SetBaControl(uint16_t ba)
Set the Block Ack control.
void Serialize(Buffer::Iterator start) const
int8_t GetUlTargetRssi(void) const
Get the expected receive signal power for the solicited HE TB PPDU.