src/wifi/model/wifi-mac-header.h
author Junling Bu <linlinjavaer@gmail.com>
Tue, 03 Dec 2013 11:25:59 -0800
changeset 10459 f2e90c12a44f
parent 10424 9d29c9a5ddcb
child 10483 e3a02ed14587
permissions -rw-r--r--
base implementation of the IEEE 802.11p standard
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
7385
10beb0e53130 standardize emacs c++ mode comments
Vedran Miletić <rivanvx@gmail.com>
parents: 7141
diff changeset
     1
/* -*- Mode:C++; c-file-style:"gnu"; indent-tabs-mode:nil; -*- */
1896
9861a16a8a1d build WifiMacHeader
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff changeset
     2
/*
4401
427cec7079f3 add amsdu field
Mirko Banchi <mk.banchi@gmail.com>
parents: 3660
diff changeset
     3
 * Copyright (c) 2006, 2009 INRIA
427cec7079f3 add amsdu field
Mirko Banchi <mk.banchi@gmail.com>
parents: 3660
diff changeset
     4
 * Copyright (c) 2009 MIRKO BANCHI
1896
9861a16a8a1d build WifiMacHeader
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff changeset
     5
 *
9861a16a8a1d build WifiMacHeader
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff changeset
     6
 * This program is free software; you can redistribute it and/or modify
9861a16a8a1d build WifiMacHeader
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff changeset
     7
 * it under the terms of the GNU General Public License version 2 as
9861a16a8a1d build WifiMacHeader
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff changeset
     8
 * published by the Free Software Foundation;
9861a16a8a1d build WifiMacHeader
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff changeset
     9
 *
9861a16a8a1d build WifiMacHeader
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff changeset
    10
 * This program is distributed in the hope that it will be useful,
9861a16a8a1d build WifiMacHeader
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff changeset
    11
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
9861a16a8a1d build WifiMacHeader
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff changeset
    12
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
9861a16a8a1d build WifiMacHeader
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff changeset
    13
 * GNU General Public License for more details.
9861a16a8a1d build WifiMacHeader
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff changeset
    14
 *
9861a16a8a1d build WifiMacHeader
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff changeset
    15
 * You should have received a copy of the GNU General Public License
9861a16a8a1d build WifiMacHeader
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff changeset
    16
 * along with this program; if not, write to the Free Software
9861a16a8a1d build WifiMacHeader
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff changeset
    17
 * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
9861a16a8a1d build WifiMacHeader
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff changeset
    18
 *
9861a16a8a1d build WifiMacHeader
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff changeset
    19
 * Author: Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
4401
427cec7079f3 add amsdu field
Mirko Banchi <mk.banchi@gmail.com>
parents: 3660
diff changeset
    20
 * Author: Mirko Banchi <mk.banchi@gmail.com>
1896
9861a16a8a1d build WifiMacHeader
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff changeset
    21
 */
9861a16a8a1d build WifiMacHeader
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff changeset
    22
#ifndef WIFI_MAC_HEADER_H
9861a16a8a1d build WifiMacHeader
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff changeset
    23
#define WIFI_MAC_HEADER_H
9861a16a8a1d build WifiMacHeader
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff changeset
    24
9861a16a8a1d build WifiMacHeader
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff changeset
    25
#include "ns3/header.h"
9861a16a8a1d build WifiMacHeader
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff changeset
    26
#include "ns3/mac48-address.h"
2022
33579d27ce2a try to simplify duration calculations
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents: 1978
diff changeset
    27
#include "ns3/nstime.h"
1896
9861a16a8a1d build WifiMacHeader
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff changeset
    28
#include <stdint.h>
9861a16a8a1d build WifiMacHeader
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff changeset
    29
9861a16a8a1d build WifiMacHeader
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff changeset
    30
namespace ns3 {
9861a16a8a1d build WifiMacHeader
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff changeset
    31
7141
072fb225b714 run check-style.py on src/wifi
Nicola Baldo <nicola@baldo.biz>
parents: 7139
diff changeset
    32
enum WifiMacType
072fb225b714 run check-style.py on src/wifi
Nicola Baldo <nicola@baldo.biz>
parents: 7139
diff changeset
    33
{
1896
9861a16a8a1d build WifiMacHeader
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff changeset
    34
  WIFI_MAC_CTL_RTS = 0,
9861a16a8a1d build WifiMacHeader
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff changeset
    35
  WIFI_MAC_CTL_CTS,
9861a16a8a1d build WifiMacHeader
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff changeset
    36
  WIFI_MAC_CTL_ACK,
9861a16a8a1d build WifiMacHeader
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff changeset
    37
  WIFI_MAC_CTL_BACKREQ,
9861a16a8a1d build WifiMacHeader
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff changeset
    38
  WIFI_MAC_CTL_BACKRESP,
10139
17a71cd49da3 partial 802.11n support
Ghada Badawy <gbadawy@gmail.com>
parents: 7385
diff changeset
    39
  WIFI_MAC_CTL_CTLWRAPPER,
1896
9861a16a8a1d build WifiMacHeader
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff changeset
    40
9861a16a8a1d build WifiMacHeader
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff changeset
    41
  WIFI_MAC_MGT_BEACON,
9861a16a8a1d build WifiMacHeader
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff changeset
    42
  WIFI_MAC_MGT_ASSOCIATION_REQUEST,
9861a16a8a1d build WifiMacHeader
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff changeset
    43
  WIFI_MAC_MGT_ASSOCIATION_RESPONSE,
9861a16a8a1d build WifiMacHeader
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff changeset
    44
  WIFI_MAC_MGT_DISASSOCIATION,
9861a16a8a1d build WifiMacHeader
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff changeset
    45
  WIFI_MAC_MGT_REASSOCIATION_REQUEST,
9861a16a8a1d build WifiMacHeader
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff changeset
    46
  WIFI_MAC_MGT_REASSOCIATION_RESPONSE,
9861a16a8a1d build WifiMacHeader
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff changeset
    47
  WIFI_MAC_MGT_PROBE_REQUEST,
9861a16a8a1d build WifiMacHeader
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff changeset
    48
  WIFI_MAC_MGT_PROBE_RESPONSE,
9861a16a8a1d build WifiMacHeader
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff changeset
    49
  WIFI_MAC_MGT_AUTHENTICATION,
9861a16a8a1d build WifiMacHeader
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff changeset
    50
  WIFI_MAC_MGT_DEAUTHENTICATION,
4692
f4cd995f1718 Review issue 88093: Minor changes in wifi module needed by 802.11s
Pavel Boyko <boyko@iitp.ru>
parents: 4401
diff changeset
    51
  WIFI_MAC_MGT_ACTION,
f4cd995f1718 Review issue 88093: Minor changes in wifi module needed by 802.11s
Pavel Boyko <boyko@iitp.ru>
parents: 4401
diff changeset
    52
  WIFI_MAC_MGT_ACTION_NO_ACK,
f4cd995f1718 Review issue 88093: Minor changes in wifi module needed by 802.11s
Pavel Boyko <boyko@iitp.ru>
parents: 4401
diff changeset
    53
  WIFI_MAC_MGT_MULTIHOP_ACTION,
1896
9861a16a8a1d build WifiMacHeader
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff changeset
    54
9861a16a8a1d build WifiMacHeader
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff changeset
    55
  WIFI_MAC_DATA,
9861a16a8a1d build WifiMacHeader
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff changeset
    56
  WIFI_MAC_DATA_CFACK,
9861a16a8a1d build WifiMacHeader
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff changeset
    57
  WIFI_MAC_DATA_CFPOLL,
9861a16a8a1d build WifiMacHeader
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff changeset
    58
  WIFI_MAC_DATA_CFACK_CFPOLL,
9861a16a8a1d build WifiMacHeader
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff changeset
    59
  WIFI_MAC_DATA_NULL,
9861a16a8a1d build WifiMacHeader
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff changeset
    60
  WIFI_MAC_DATA_NULL_CFACK,
9861a16a8a1d build WifiMacHeader
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff changeset
    61
  WIFI_MAC_DATA_NULL_CFPOLL,
9861a16a8a1d build WifiMacHeader
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff changeset
    62
  WIFI_MAC_DATA_NULL_CFACK_CFPOLL,
9861a16a8a1d build WifiMacHeader
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff changeset
    63
  WIFI_MAC_QOSDATA,
9861a16a8a1d build WifiMacHeader
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff changeset
    64
  WIFI_MAC_QOSDATA_CFACK,
9861a16a8a1d build WifiMacHeader
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff changeset
    65
  WIFI_MAC_QOSDATA_CFPOLL,
9861a16a8a1d build WifiMacHeader
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff changeset
    66
  WIFI_MAC_QOSDATA_CFACK_CFPOLL,
9861a16a8a1d build WifiMacHeader
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff changeset
    67
  WIFI_MAC_QOSDATA_NULL,
9861a16a8a1d build WifiMacHeader
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff changeset
    68
  WIFI_MAC_QOSDATA_NULL_CFPOLL,
9861a16a8a1d build WifiMacHeader
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff changeset
    69
  WIFI_MAC_QOSDATA_NULL_CFACK_CFPOLL,
9861a16a8a1d build WifiMacHeader
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff changeset
    70
};
9861a16a8a1d build WifiMacHeader
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff changeset
    71
7139
79dd02ed46ec doxygen wifi module grouping all wifi classes
Nicola Baldo <nbaldo@cttc.es>
parents: 6852
diff changeset
    72
/**
79dd02ed46ec doxygen wifi module grouping all wifi classes
Nicola Baldo <nbaldo@cttc.es>
parents: 6852
diff changeset
    73
 * \ingroup wifi
79dd02ed46ec doxygen wifi module grouping all wifi classes
Nicola Baldo <nbaldo@cttc.es>
parents: 6852
diff changeset
    74
 *
79dd02ed46ec doxygen wifi module grouping all wifi classes
Nicola Baldo <nbaldo@cttc.es>
parents: 6852
diff changeset
    75
 * Implements the IEEE 802.11 MAC header
79dd02ed46ec doxygen wifi module grouping all wifi classes
Nicola Baldo <nbaldo@cttc.es>
parents: 6852
diff changeset
    76
 */
7141
072fb225b714 run check-style.py on src/wifi
Nicola Baldo <nicola@baldo.biz>
parents: 7139
diff changeset
    77
class WifiMacHeader : public Header
1896
9861a16a8a1d build WifiMacHeader
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff changeset
    78
{
9861a16a8a1d build WifiMacHeader
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff changeset
    79
public:
7141
072fb225b714 run check-style.py on src/wifi
Nicola Baldo <nicola@baldo.biz>
parents: 7139
diff changeset
    80
  enum QosAckPolicy
072fb225b714 run check-style.py on src/wifi
Nicola Baldo <nicola@baldo.biz>
parents: 7139
diff changeset
    81
  {
4401
427cec7079f3 add amsdu field
Mirko Banchi <mk.banchi@gmail.com>
parents: 3660
diff changeset
    82
    NORMAL_ACK = 0,
427cec7079f3 add amsdu field
Mirko Banchi <mk.banchi@gmail.com>
parents: 3660
diff changeset
    83
    NO_ACK = 1,
427cec7079f3 add amsdu field
Mirko Banchi <mk.banchi@gmail.com>
parents: 3660
diff changeset
    84
    NO_EXPLICIT_ACK = 2,
427cec7079f3 add amsdu field
Mirko Banchi <mk.banchi@gmail.com>
parents: 3660
diff changeset
    85
    BLOCK_ACK = 3,
427cec7079f3 add amsdu field
Mirko Banchi <mk.banchi@gmail.com>
parents: 3660
diff changeset
    86
  };
7141
072fb225b714 run check-style.py on src/wifi
Nicola Baldo <nicola@baldo.biz>
parents: 7139
diff changeset
    87
072fb225b714 run check-style.py on src/wifi
Nicola Baldo <nicola@baldo.biz>
parents: 7139
diff changeset
    88
  enum AddressType
072fb225b714 run check-style.py on src/wifi
Nicola Baldo <nicola@baldo.biz>
parents: 7139
diff changeset
    89
  {
072fb225b714 run check-style.py on src/wifi
Nicola Baldo <nicola@baldo.biz>
parents: 7139
diff changeset
    90
    ADDR1,
4401
427cec7079f3 add amsdu field
Mirko Banchi <mk.banchi@gmail.com>
parents: 3660
diff changeset
    91
    ADDR2,
427cec7079f3 add amsdu field
Mirko Banchi <mk.banchi@gmail.com>
parents: 3660
diff changeset
    92
    ADDR3,
427cec7079f3 add amsdu field
Mirko Banchi <mk.banchi@gmail.com>
parents: 3660
diff changeset
    93
    ADDR4
427cec7079f3 add amsdu field
Mirko Banchi <mk.banchi@gmail.com>
parents: 3660
diff changeset
    94
  };
2643
2a3324f4dabe define a TypeId for each Header/Trailer.
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents: 2085
diff changeset
    95
1896
9861a16a8a1d build WifiMacHeader
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff changeset
    96
  WifiMacHeader ();
9861a16a8a1d build WifiMacHeader
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff changeset
    97
  ~WifiMacHeader ();
2643
2a3324f4dabe define a TypeId for each Header/Trailer.
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents: 2085
diff changeset
    98
2a3324f4dabe define a TypeId for each Header/Trailer.
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents: 2085
diff changeset
    99
  static TypeId GetTypeId (void);
2a3324f4dabe define a TypeId for each Header/Trailer.
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents: 2085
diff changeset
   100
  virtual TypeId GetInstanceTypeId (void) const;
2646
c1fef7686472 remove dead code.
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents: 2643
diff changeset
   101
  virtual void Print (std::ostream &os) const;
2643
2a3324f4dabe define a TypeId for each Header/Trailer.
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents: 2085
diff changeset
   102
  virtual uint32_t GetSerializedSize (void) const;
2a3324f4dabe define a TypeId for each Header/Trailer.
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents: 2085
diff changeset
   103
  virtual void Serialize (Buffer::Iterator start) const;
2a3324f4dabe define a TypeId for each Header/Trailer.
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents: 2085
diff changeset
   104
  virtual uint32_t Deserialize (Buffer::Iterator start);
1896
9861a16a8a1d build WifiMacHeader
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff changeset
   105
10424
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   106
  /**
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   107
   * Set Type/Subtype values for an association request header.
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   108
   */
1896
9861a16a8a1d build WifiMacHeader
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff changeset
   109
  void SetAssocReq (void);
10424
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   110
  /**
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   111
   * Set Type/Subtype values for an association response header.
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   112
   */
1896
9861a16a8a1d build WifiMacHeader
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff changeset
   113
  void SetAssocResp (void);
10424
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   114
  /**
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   115
   * Set Type/Subtype values for a probe request header.
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   116
   */
1896
9861a16a8a1d build WifiMacHeader
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff changeset
   117
  void SetProbeReq (void);
10424
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   118
  /**
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   119
   * Set Type/Subtype values for a probe response header.
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   120
   */
1896
9861a16a8a1d build WifiMacHeader
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff changeset
   121
  void SetProbeResp (void);
10424
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   122
  /**
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   123
   * Set Type/Subtype values for a beacon header.
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   124
   */
2085
72ec3b59f333 add WifiMacHeader::SetBeacon
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents: 2022
diff changeset
   125
  void SetBeacon (void);
10424
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   126
  /**
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   127
   * Set Type/Subtype values for a data packet with
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   128
   * no subtype equal to 0.
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   129
   */
1896
9861a16a8a1d build WifiMacHeader
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff changeset
   130
  void SetTypeData (void);
10424
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   131
  /**
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   132
   * Set Type/Subtype values for an action header.
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   133
   */
4692
f4cd995f1718 Review issue 88093: Minor changes in wifi module needed by 802.11s
Pavel Boyko <boyko@iitp.ru>
parents: 4401
diff changeset
   134
  void SetAction ();
10424
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   135
  /**
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   136
   * Set Type/Subtype values for a Block Ack Request header.
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   137
   */
5950
a09eebc83465 add support for block ack frames in WifiMacHeader
Mirko Banchi <mk.banchi@gmail.com>
parents: 5819
diff changeset
   138
  void SetBlockAckReq (void);
10424
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   139
  /**
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   140
   * Set Type/Subtype values for a Block Ack header.
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   141
   */
5950
a09eebc83465 add support for block ack frames in WifiMacHeader
Mirko Banchi <mk.banchi@gmail.com>
parents: 5819
diff changeset
   142
  void SetBlockAck (void);
7141
072fb225b714 run check-style.py on src/wifi
Nicola Baldo <nicola@baldo.biz>
parents: 7139
diff changeset
   143
  void SetMultihopAction ();
10424
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   144
  /**
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   145
   * Set the From DS bit in the Frame Control field.
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   146
   */
1896
9861a16a8a1d build WifiMacHeader
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff changeset
   147
  void SetDsFrom (void);
10424
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   148
  /**
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   149
   * Un-set the From DS bit in the Frame Control field.
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   150
   */
1896
9861a16a8a1d build WifiMacHeader
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff changeset
   151
  void SetDsNotFrom (void);
10424
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   152
  /**
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   153
   * Set the To DS bit in the Frame Control field.
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   154
   */
1896
9861a16a8a1d build WifiMacHeader
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff changeset
   155
  void SetDsTo (void);
10424
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   156
  /**
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   157
   * Un-set the To DS bit in the Frame Control field.
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   158
   */
1896
9861a16a8a1d build WifiMacHeader
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff changeset
   159
  void SetDsNotTo (void);
10424
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   160
  /**
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   161
   * Fill the Address 1 field with the given address.
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   162
   *
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   163
   * \param address the address to be used in the Address 1 field
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   164
   */
1896
9861a16a8a1d build WifiMacHeader
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff changeset
   165
  void SetAddr1 (Mac48Address address);
10424
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   166
  /**
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   167
   * Fill the Address 2 field with the given address.
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   168
   *
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   169
   * \param address the address to be used in the Address 2 field
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   170
   */
1896
9861a16a8a1d build WifiMacHeader
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff changeset
   171
  void SetAddr2 (Mac48Address address);
10424
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   172
  /**
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   173
   * Fill the Address 3 field with the given address.
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   174
   *
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   175
   * \param address the address to be used in the Address 3 field
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   176
   */
1896
9861a16a8a1d build WifiMacHeader
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff changeset
   177
  void SetAddr3 (Mac48Address address);
10424
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   178
  /**
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   179
   * Fill the Address 4 field with the given address.
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   180
   *
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   181
   * \param address the address to be used in the Address 4 field
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   182
   */
1896
9861a16a8a1d build WifiMacHeader
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff changeset
   183
  void SetAddr4 (Mac48Address address);
10424
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   184
  /**
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   185
   * Set Type/Subtype values with the correct values depending
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   186
   * on the given type.
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   187
   *
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   188
   * \param type the WifiMacType for the header
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   189
   */
4401
427cec7079f3 add amsdu field
Mirko Banchi <mk.banchi@gmail.com>
parents: 3660
diff changeset
   190
  void SetType (enum WifiMacType type);
10424
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   191
  /**
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   192
   * Set the Duration/ID field with the given raw uint16_t value.
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   193
   *
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   194
   * \param duration the raw duration in uint16_t
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   195
   */
2022
33579d27ce2a try to simplify duration calculations
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents: 1978
diff changeset
   196
  void SetRawDuration (uint16_t duration);
10424
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   197
  /**
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   198
   * Set the Duration/ID field with the given duration (Time object).
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   199
   * The method converts the given time to microseconds.
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   200
   *
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   201
   * \param duration the duration (Time object)
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   202
   */
2022
33579d27ce2a try to simplify duration calculations
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents: 1978
diff changeset
   203
  void SetDuration (Time duration);
10424
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   204
  /**
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   205
   * Set the Duration/ID field with the given ID.
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   206
   *
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   207
   * \param id the ID
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   208
   */
1896
9861a16a8a1d build WifiMacHeader
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff changeset
   209
  void SetId (uint16_t id);
10424
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   210
  /**
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   211
   * Set the sequence number of the header.
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   212
   *
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   213
   * \param seq the given sequence number
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   214
   */
1896
9861a16a8a1d build WifiMacHeader
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff changeset
   215
  void SetSequenceNumber (uint16_t seq);
10424
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   216
  /**
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   217
   * Set the fragment number of the header.
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   218
   *
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   219
   * \param frag the given fragment number
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   220
   */
1896
9861a16a8a1d build WifiMacHeader
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff changeset
   221
  void SetFragmentNumber (uint8_t frag);
10424
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   222
  /**
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   223
   * Un-set the More Fragment bit in the Frame Control Field
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   224
   */
1896
9861a16a8a1d build WifiMacHeader
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff changeset
   225
  void SetNoMoreFragments (void);
10424
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   226
  /**
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   227
   * Set the More Fragment bit in the Frame Control field
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   228
   */
1896
9861a16a8a1d build WifiMacHeader
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff changeset
   229
  void SetMoreFragments (void);
10424
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   230
  /**
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   231
   * Set the Retry bit in the Frame Control field.
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   232
   */
1896
9861a16a8a1d build WifiMacHeader
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff changeset
   233
  void SetRetry (void);
10424
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   234
  /**
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   235
   * Un-set the Retry bit in the Frame Control field.
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   236
   */
1896
9861a16a8a1d build WifiMacHeader
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff changeset
   237
  void SetNoRetry (void);
10424
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   238
  /**
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   239
   * Set the TID for the QoS header.
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   240
   *
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   241
   * \param tid the TID for the QoS header
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   242
   */
1896
9861a16a8a1d build WifiMacHeader
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff changeset
   243
  void SetQosTid (uint8_t tid);
10424
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   244
  /**
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   245
   * Set the end of service period (EOSP) bit in the QoS control field.
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   246
   */
4401
427cec7079f3 add amsdu field
Mirko Banchi <mk.banchi@gmail.com>
parents: 3660
diff changeset
   247
  void SetQosEosp ();
10424
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   248
  /**
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   249
   * Un-set the end of service period (EOSP) bit in the QoS control field.
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   250
   */
4401
427cec7079f3 add amsdu field
Mirko Banchi <mk.banchi@gmail.com>
parents: 3660
diff changeset
   251
  void SetQosNoEosp ();
10424
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   252
  /**
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   253
   * Set the QoS ACK policy in the QoS control field.
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   254
   */
4401
427cec7079f3 add amsdu field
Mirko Banchi <mk.banchi@gmail.com>
parents: 3660
diff changeset
   255
  void SetQosAckPolicy (enum QosAckPolicy);
10424
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   256
  /**
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   257
   * Set the QoS ACK policy in the QoS control field to normal ACK.
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   258
   */
5950
a09eebc83465 add support for block ack frames in WifiMacHeader
Mirko Banchi <mk.banchi@gmail.com>
parents: 5819
diff changeset
   259
  void SetQosNormalAck (void);
10424
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   260
  /**
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   261
   * Set the QoS ACK policy in the QoS control field to block ACK.
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   262
   */
5950
a09eebc83465 add support for block ack frames in WifiMacHeader
Mirko Banchi <mk.banchi@gmail.com>
parents: 5819
diff changeset
   263
  void SetQosBlockAck (void);
10424
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   264
  /**
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   265
   * Set the QoS ACK policy in the QoS control field to no ACK.
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   266
   */
5950
a09eebc83465 add support for block ack frames in WifiMacHeader
Mirko Banchi <mk.banchi@gmail.com>
parents: 5819
diff changeset
   267
  void SetQosNoAck (void);
4401
427cec7079f3 add amsdu field
Mirko Banchi <mk.banchi@gmail.com>
parents: 3660
diff changeset
   268
  void SetQosAmsdu (void);
427cec7079f3 add amsdu field
Mirko Banchi <mk.banchi@gmail.com>
parents: 3660
diff changeset
   269
  void SetQosNoAmsdu (void);
1896
9861a16a8a1d build WifiMacHeader
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff changeset
   270
  void SetQosTxopLimit (uint8_t txop);
10139
17a71cd49da3 partial 802.11n support
Ghada Badawy <gbadawy@gmail.com>
parents: 7385
diff changeset
   271
  void SetOrder (void);
17a71cd49da3 partial 802.11n support
Ghada Badawy <gbadawy@gmail.com>
parents: 7385
diff changeset
   272
  void SetNoOrder (void);
1896
9861a16a8a1d build WifiMacHeader
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff changeset
   273
10424
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   274
  /**
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   275
   * Return the address in the Address 1 field.
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   276
   *
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   277
   * \return the address in the Address 1 field
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   278
   */
1896
9861a16a8a1d build WifiMacHeader
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff changeset
   279
  Mac48Address GetAddr1 (void) const;
10424
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   280
  /**
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   281
   * Return the address in the Address 2 field.
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   282
   *
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   283
   * \return the address in the Address 2 field
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   284
   */
1896
9861a16a8a1d build WifiMacHeader
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff changeset
   285
  Mac48Address GetAddr2 (void) const;
10424
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   286
  /**
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   287
   * Return the address in the Address 3 field.
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   288
   *
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   289
   * \return the address in the Address 3 field
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   290
   */
1896
9861a16a8a1d build WifiMacHeader
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff changeset
   291
  Mac48Address GetAddr3 (void) const;
10424
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   292
  /**
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   293
   * Return the address in the Address 4 field.
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   294
   *
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   295
   * \return the address in the Address 4 field
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   296
   */
1896
9861a16a8a1d build WifiMacHeader
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff changeset
   297
  Mac48Address GetAddr4 (void) const;
10424
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   298
  /**
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   299
   * Return the type (enum WifiMacType)
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   300
   *
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   301
   * \return the type (enum WifiMacType)
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   302
   */
4401
427cec7079f3 add amsdu field
Mirko Banchi <mk.banchi@gmail.com>
parents: 3660
diff changeset
   303
  enum WifiMacType GetType (void) const;
10424
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   304
  /**
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   305
   * \return true if From DS bit is set, false otherwise
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   306
   */
1896
9861a16a8a1d build WifiMacHeader
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff changeset
   307
  bool IsFromDs (void) const;
10424
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   308
  /**
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   309
   * \return true if To DS bit is set, false otherwise
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   310
   */
1896
9861a16a8a1d build WifiMacHeader
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff changeset
   311
  bool IsToDs (void) const;
10424
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   312
  /**
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   313
   * Return true if the Type is DATA.  The method does
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   314
   * not check the Subtype field. (e.g. the header may be
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   315
   * DATA with QoS)
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   316
   *
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   317
   * \return true if Type is DATA, false otherwise
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   318
   */
1896
9861a16a8a1d build WifiMacHeader
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff changeset
   319
  bool IsData (void) const;
10424
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   320
  /**
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   321
   * Return true if the Type is DATA and Subtype is one of the
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   322
   * possible values for QoS DATA.
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   323
   *
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   324
   * \return true if Type is QoS DATA, false otherwise
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   325
   */
1896
9861a16a8a1d build WifiMacHeader
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff changeset
   326
  bool IsQosData (void) const;
10424
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   327
  /**
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   328
   * Return true if the Type is Control.
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   329
   *
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   330
   * \return true if Type is Control, false otherwise
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   331
   */
1896
9861a16a8a1d build WifiMacHeader
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff changeset
   332
  bool IsCtl (void) const;
10424
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   333
  /**
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   334
   * Return true if the Type is Management.
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   335
   *
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   336
   * \return true if Type is Management, false otherwise
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   337
   */
1896
9861a16a8a1d build WifiMacHeader
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff changeset
   338
  bool IsMgt (void) const;
10424
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   339
  /**
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   340
   * Return true if the Type/Subtype is one of the possible CF-Poll headers.
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   341
   *
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   342
   * \return true if the Type/Subtype is one of the possible CF-Poll headers, false otherwise
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   343
   */
1896
9861a16a8a1d build WifiMacHeader
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff changeset
   344
  bool IsCfpoll (void) const;
10424
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   345
  /**
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   346
   * Return true if the header is a RTS header.
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   347
   *
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   348
   * \return true if the header is a RTS header, false otherwise
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   349
   */
1896
9861a16a8a1d build WifiMacHeader
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff changeset
   350
  bool IsRts (void) const;
10424
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   351
  /**
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   352
   * Return true if the header is a CTS header.
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   353
   *
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   354
   * \return true if the header is a CTS header, false otherwise
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   355
   */
1896
9861a16a8a1d build WifiMacHeader
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff changeset
   356
  bool IsCts (void) const;
10424
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   357
  /**
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   358
   * Return true if the header is an ACK header.
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   359
   *
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   360
   * \return true if the header is an ACK header, false otherwise
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   361
   */
1896
9861a16a8a1d build WifiMacHeader
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff changeset
   362
  bool IsAck (void) const;
10424
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   363
  /**
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   364
   * Return true if the header is a Block ACK Request header.
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   365
   *
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   366
   * \return true if the header is a Block ACK Request header, false otherwise
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   367
   */
5950
a09eebc83465 add support for block ack frames in WifiMacHeader
Mirko Banchi <mk.banchi@gmail.com>
parents: 5819
diff changeset
   368
  bool IsBlockAckReq (void) const;
10424
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   369
  /**
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   370
   * Return true if the header is a Block ACK header.
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   371
   *
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   372
   * \return true if the header is a Block ACK header, false otherwise
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   373
   */
5950
a09eebc83465 add support for block ack frames in WifiMacHeader
Mirko Banchi <mk.banchi@gmail.com>
parents: 5819
diff changeset
   374
  bool IsBlockAck (void) const;
10424
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   375
  /**
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   376
   * Return true if the header is an Association Request header.
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   377
   *
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   378
   * \return true if the header is an Association Request header, false otherwise
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   379
   */
1896
9861a16a8a1d build WifiMacHeader
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff changeset
   380
  bool IsAssocReq (void) const;
10424
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   381
  /**
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   382
   * Return true if the header is an Association Response header.
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   383
   *
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   384
   * \return true if the header is an Association Response header, false otherwise
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   385
   */
1896
9861a16a8a1d build WifiMacHeader
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff changeset
   386
  bool IsAssocResp (void) const;
10424
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   387
  /**
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   388
   * Return true if the header is a Reassociation Request header.
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   389
   *
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   390
   * \return true if the header is a Reassociation Request header, false otherwise
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   391
   */
1896
9861a16a8a1d build WifiMacHeader
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff changeset
   392
  bool IsReassocReq (void) const;
10424
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   393
  /**
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   394
   * Return true if the header is a Reassociation Response header.
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   395
   *
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   396
   * \return true if the header is a Reassociation Response header, false otherwise
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   397
   */
1896
9861a16a8a1d build WifiMacHeader
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff changeset
   398
  bool IsReassocResp (void) const;
10424
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   399
  /**
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   400
   * Return true if the header is a Probe Request header.
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   401
   *
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   402
   * \return true if the header is a Probe Request header, false otherwise
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   403
   */
1896
9861a16a8a1d build WifiMacHeader
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff changeset
   404
  bool IsProbeReq (void) const;
10424
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   405
  /**
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   406
   * Return true if the header is a Probe Response header.
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   407
   *
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   408
   * \return true if the header is a Probe Response header, false otherwise
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   409
   */
1896
9861a16a8a1d build WifiMacHeader
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff changeset
   410
  bool IsProbeResp (void) const;
10424
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   411
  /**
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   412
   * Return true if the header is a Beacon header.
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   413
   *
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   414
   * \return true if the header is a Beacon header, false otherwise
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   415
   */
1896
9861a16a8a1d build WifiMacHeader
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff changeset
   416
  bool IsBeacon (void) const;
10424
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   417
  /**
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   418
   * Return true if the header is a Disassociation header.
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   419
   *
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   420
   * \return true if the header is a Disassociation header, false otherwise
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   421
   */
1896
9861a16a8a1d build WifiMacHeader
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff changeset
   422
  bool IsDisassociation (void) const;
10424
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   423
  /**
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   424
   * Return true if the header is an Authentication header.
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   425
   *
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   426
   * \return true if the header is an Authentication header, false otherwise
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   427
   */
1896
9861a16a8a1d build WifiMacHeader
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff changeset
   428
  bool IsAuthentication (void) const;
10424
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   429
  /**
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   430
   * Return true if the header is a Deauthentication header.
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   431
   *
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   432
   * \return true if the header is a Deauthentication header, false otherwise
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   433
   */
1896
9861a16a8a1d build WifiMacHeader
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff changeset
   434
  bool IsDeauthentication (void) const;
10424
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   435
  /**
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   436
   * Return true if the header is an Action header.
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   437
   *
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   438
   * \return true if the header is an Action header, false otherwise
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   439
   */
4692
f4cd995f1718 Review issue 88093: Minor changes in wifi module needed by 802.11s
Pavel Boyko <boyko@iitp.ru>
parents: 4401
diff changeset
   440
  bool IsAction () const;
f4cd995f1718 Review issue 88093: Minor changes in wifi module needed by 802.11s
Pavel Boyko <boyko@iitp.ru>
parents: 4401
diff changeset
   441
  bool IsMultihopAction () const;
10424
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   442
  /**
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   443
   * Return the raw duration from the Duration/ID field.
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   444
   *
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   445
   * \return the raw duration from the Duration/ID field
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   446
   */
2022
33579d27ce2a try to simplify duration calculations
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents: 1978
diff changeset
   447
  uint16_t GetRawDuration (void) const;
10424
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   448
  /**
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   449
   * Return the duration from the Duration/ID field (Time object).
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   450
   *
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   451
   * \return the duration from the Duration/ID field (Time object)
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   452
   */
2022
33579d27ce2a try to simplify duration calculations
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents: 1978
diff changeset
   453
  Time GetDuration (void) const;
10424
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   454
  /**
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   455
   * Return the raw Sequence Control field.
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   456
   *
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   457
   * \return the raw Sequence Control field
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   458
   */
1896
9861a16a8a1d build WifiMacHeader
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff changeset
   459
  uint16_t GetSequenceControl (void) const;
10424
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   460
  /**
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   461
   * Return the sequence number of the header.
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   462
   *
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   463
   * \return the sequence number of the header
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   464
   */
1896
9861a16a8a1d build WifiMacHeader
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff changeset
   465
  uint16_t GetSequenceNumber (void) const;
10424
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   466
  /**
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   467
   * Return the fragment number of the header.
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   468
   *
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   469
   * \return the fragment number of the header
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   470
   */
1896
9861a16a8a1d build WifiMacHeader
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff changeset
   471
  uint16_t GetFragmentNumber (void) const;
10424
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   472
  /**
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   473
   * Return if the Retry bit is set.
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   474
   *
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   475
   * \return true if the Retry bit is set, false otherwise
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   476
   */
1896
9861a16a8a1d build WifiMacHeader
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff changeset
   477
  bool IsRetry (void) const;
10424
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   478
  /**
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   479
   * Return if the More Fragment bit is set.
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   480
   *
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   481
   * \return true if the More Fragment bit is set, false otherwise
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   482
   */
1896
9861a16a8a1d build WifiMacHeader
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff changeset
   483
  bool IsMoreFragments (void) const;
10424
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   484
  /**
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   485
   * Return if the QoS ACK policy is Block ACK.
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   486
   *
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   487
   * \return true if the QoS ACK policy is Block ACK, false otherwise
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   488
   */
1896
9861a16a8a1d build WifiMacHeader
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff changeset
   489
  bool IsQosBlockAck (void) const;
10424
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   490
  /**
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   491
   * Return if the QoS ACK policy is No ACK.
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   492
   *
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   493
   * \return true if the QoS ACK policy is No ACK, false otherwise
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   494
   */
1896
9861a16a8a1d build WifiMacHeader
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff changeset
   495
  bool IsQosNoAck (void) const;
10424
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   496
  /**
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   497
   * Return if the QoS ACK policy is Normal ACK.
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   498
   *
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   499
   * \return true if the QoS ACK policy is No ACK, false otherwise
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   500
   */
1896
9861a16a8a1d build WifiMacHeader
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff changeset
   501
  bool IsQosAck (void) const;
10424
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   502
  /**
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   503
   * Return if the end of service period (EOSP) is set.
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   504
   *
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   505
   * \return true if the end of service period (EOSP) is set, false otherwise
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   506
   */
4401
427cec7079f3 add amsdu field
Mirko Banchi <mk.banchi@gmail.com>
parents: 3660
diff changeset
   507
  bool IsQosEosp (void) const;
427cec7079f3 add amsdu field
Mirko Banchi <mk.banchi@gmail.com>
parents: 3660
diff changeset
   508
  bool IsQosAmsdu (void) const;
10424
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   509
  /**
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   510
   * Return the Traffic ID of a QoS header.
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   511
   *
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   512
   * \return the Traffic ID of a QoS header
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   513
   */
1896
9861a16a8a1d build WifiMacHeader
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff changeset
   514
  uint8_t GetQosTid (void) const;
10424
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   515
  /**
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   516
   * Return the QoS ACK Policy of a QoS header.
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   517
   *
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   518
   * \return the QoS ACK Policy of a QoS header
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   519
   */
4401
427cec7079f3 add amsdu field
Mirko Banchi <mk.banchi@gmail.com>
parents: 3660
diff changeset
   520
  enum QosAckPolicy GetQosAckPolicy (void) const;
1896
9861a16a8a1d build WifiMacHeader
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff changeset
   521
  uint8_t GetQosTxopLimit (void) const;
9861a16a8a1d build WifiMacHeader
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff changeset
   522
9861a16a8a1d build WifiMacHeader
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff changeset
   523
  uint32_t GetSize (void) const;
10424
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   524
  /**
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   525
   * Return a string corresponds to the header type.
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   526
   *
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   527
   * \returns a string corresponds to the header type.
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   528
   */
7141
072fb225b714 run check-style.py on src/wifi
Nicola Baldo <nicola@baldo.biz>
parents: 7139
diff changeset
   529
  const char * GetTypeString (void) const;
1896
9861a16a8a1d build WifiMacHeader
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff changeset
   530
9861a16a8a1d build WifiMacHeader
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff changeset
   531
9861a16a8a1d build WifiMacHeader
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff changeset
   532
private:
10424
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   533
  /**
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   534
   * Return the raw Frame Control field.
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   535
   *
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   536
   * \return the raw Frame Control field
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   537
   */
1896
9861a16a8a1d build WifiMacHeader
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff changeset
   538
  uint16_t GetFrameControl (void) const;
10424
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   539
  /**
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   540
   * Return the raw QoS Control field.
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   541
   *
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   542
   * \return the raw QoS Control field
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   543
   */
1896
9861a16a8a1d build WifiMacHeader
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff changeset
   544
  uint16_t GetQosControl (void) const;
10424
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   545
  /**
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   546
   * Set the Frame Control field with the given raw value.
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   547
   *
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   548
   * \param control the raw Frame Control field value
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   549
   */
1896
9861a16a8a1d build WifiMacHeader
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff changeset
   550
  void SetFrameControl (uint16_t control);
10424
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   551
  /**
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   552
   * Set the Sequence Control field with the given raw value.
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   553
   *
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   554
   * \param seq the raw Sequence Control field value
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   555
   */
1896
9861a16a8a1d build WifiMacHeader
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff changeset
   556
  void SetSequenceControl (uint16_t seq);
10424
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   557
  /**
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   558
   * Set the QoS Control field with the given raw value.
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   559
   *
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   560
   * \param qos the raw QoS Control field value
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   561
   */
1896
9861a16a8a1d build WifiMacHeader
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff changeset
   562
  void SetQosControl (uint16_t qos);
10424
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   563
  /**
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   564
   * Print the Frame Control field to the output stream.
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   565
   *
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   566
   * \param os the output stream to print to
9d29c9a5ddcb doxygen warnings for wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10218
diff changeset
   567
   */
1896
9861a16a8a1d build WifiMacHeader
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff changeset
   568
  void PrintFrameControl (std::ostream &os) const;
9861a16a8a1d build WifiMacHeader
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff changeset
   569
3660
0ae474317c28 don't use bitfields: they are evil.
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents: 2646
diff changeset
   570
  uint8_t m_ctrlType;
0ae474317c28 don't use bitfields: they are evil.
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents: 2646
diff changeset
   571
  uint8_t m_ctrlSubtype;
0ae474317c28 don't use bitfields: they are evil.
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents: 2646
diff changeset
   572
  uint8_t m_ctrlToDs;
0ae474317c28 don't use bitfields: they are evil.
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents: 2646
diff changeset
   573
  uint8_t m_ctrlFromDs;
0ae474317c28 don't use bitfields: they are evil.
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents: 2646
diff changeset
   574
  uint8_t m_ctrlMoreFrag;
0ae474317c28 don't use bitfields: they are evil.
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents: 2646
diff changeset
   575
  uint8_t m_ctrlRetry;
0ae474317c28 don't use bitfields: they are evil.
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents: 2646
diff changeset
   576
  uint8_t m_ctrlMoreData;
0ae474317c28 don't use bitfields: they are evil.
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents: 2646
diff changeset
   577
  uint8_t m_ctrlWep;
0ae474317c28 don't use bitfields: they are evil.
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents: 2646
diff changeset
   578
  uint8_t m_ctrlOrder;
1896
9861a16a8a1d build WifiMacHeader
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff changeset
   579
  uint16_t m_duration;
9861a16a8a1d build WifiMacHeader
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff changeset
   580
  Mac48Address m_addr1;
9861a16a8a1d build WifiMacHeader
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff changeset
   581
  Mac48Address m_addr2;
9861a16a8a1d build WifiMacHeader
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff changeset
   582
  Mac48Address m_addr3;
3660
0ae474317c28 don't use bitfields: they are evil.
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents: 2646
diff changeset
   583
  uint8_t m_seqFrag;
0ae474317c28 don't use bitfields: they are evil.
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents: 2646
diff changeset
   584
  uint16_t m_seqSeq;
1896
9861a16a8a1d build WifiMacHeader
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff changeset
   585
  Mac48Address m_addr4;
3660
0ae474317c28 don't use bitfields: they are evil.
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents: 2646
diff changeset
   586
  uint8_t m_qosTid;
0ae474317c28 don't use bitfields: they are evil.
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents: 2646
diff changeset
   587
  uint8_t m_qosEosp;
0ae474317c28 don't use bitfields: they are evil.
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents: 2646
diff changeset
   588
  uint8_t m_qosAckPolicy;
4401
427cec7079f3 add amsdu field
Mirko Banchi <mk.banchi@gmail.com>
parents: 3660
diff changeset
   589
  uint8_t m_amsduPresent;
3660
0ae474317c28 don't use bitfields: they are evil.
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents: 2646
diff changeset
   590
  uint16_t m_qosStuff;
1896
9861a16a8a1d build WifiMacHeader
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff changeset
   591
};
9861a16a8a1d build WifiMacHeader
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff changeset
   592
1977
4303409f3d8e remove uneeded trailing ';'
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents: 1896
diff changeset
   593
} // namespace ns3
1896
9861a16a8a1d build WifiMacHeader
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff changeset
   594
9861a16a8a1d build WifiMacHeader
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff changeset
   595
9861a16a8a1d build WifiMacHeader
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff changeset
   596
9861a16a8a1d build WifiMacHeader
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff changeset
   597
#endif /* WIFI_MAC_HEADER_H */