author | Timo Bingmann <tbns@idlebox.net> |
Mon, 30 Nov 2009 18:40:35 +0100 | |
changeset 5820 | 1c02054740eb |
parent 5294 | 684768c10c59 |
child 5901 | a24cd8dce646 |
permissions | -rw-r--r-- |
1889 | 1 |
/* -*- Mode: C++; c-file-style: "gnu"; indent-tabs-mode:nil; -*- */ |
2 |
/* |
|
3 |
* Copyright (c) 2005,2006 INRIA |
|
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: Mathieu Lacage <mathieu.lacage@sophia.inria.fr> |
|
19 |
*/ |
|
20 |
||
21 |
#include "wifi-phy.h" |
|
1891
add6fb8761f3
use WifiMode rather than TransmissionMode
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
1890
diff
changeset
|
22 |
#include "wifi-mode.h" |
add6fb8761f3
use WifiMode rather than TransmissionMode
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
1890
diff
changeset
|
23 |
#include "wifi-channel.h" |
1920
1d4864775cf8
replace header mode with preamble mode
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
1919
diff
changeset
|
24 |
#include "wifi-preamble.h" |
1889 | 25 |
#include "ns3/simulator.h" |
26 |
#include "ns3/packet.h" |
|
27 |
#include "ns3/random-variable.h" |
|
1974
0d6b3bead74a
replace cassert by ns3/assert.h
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
1964
diff
changeset
|
28 |
#include "ns3/assert.h" |
1979
d535a38b7fc4
convert TRACE to NS_LOG
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
1978
diff
changeset
|
29 |
#include "ns3/log.h" |
2524
db72c0e7743e
port wifi model to Attributes
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
2503
diff
changeset
|
30 |
#include "ns3/double.h" |
db72c0e7743e
port wifi model to Attributes
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
2503
diff
changeset
|
31 |
#include "ns3/uinteger.h" |
db72c0e7743e
port wifi model to Attributes
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
2503
diff
changeset
|
32 |
#include "ns3/enum.h" |
db72c0e7743e
port wifi model to Attributes
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
2503
diff
changeset
|
33 |
#include "ns3/trace-source-accessor.h" |
1889 | 34 |
#include <math.h> |
35 |
||
1979
d535a38b7fc4
convert TRACE to NS_LOG
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
1978
diff
changeset
|
36 |
NS_LOG_COMPONENT_DEFINE ("WifiPhy"); |
1891
add6fb8761f3
use WifiMode rather than TransmissionMode
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
1890
diff
changeset
|
37 |
|
1889 | 38 |
namespace ns3 { |
39 |
||
40 |
/**************************************************************** |
|
41 |
* This destructor is needed. |
|
42 |
****************************************************************/ |
|
43 |
||
1890
a2b30c6456c9
Phy80211 -> WifiPhy
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
1889
diff
changeset
|
44 |
WifiPhyListener::~WifiPhyListener () |
1889 | 45 |
{} |
46 |
||
47 |
/**************************************************************** |
|
1890
a2b30c6456c9
Phy80211 -> WifiPhy
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
1889
diff
changeset
|
48 |
* The actual WifiPhy class |
1889 | 49 |
****************************************************************/ |
50 |
||
2524
db72c0e7743e
port wifi model to Attributes
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
2503
diff
changeset
|
51 |
NS_OBJECT_ENSURE_REGISTERED (WifiPhy); |
db72c0e7743e
port wifi model to Attributes
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
2503
diff
changeset
|
52 |
|
db72c0e7743e
port wifi model to Attributes
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
2503
diff
changeset
|
53 |
TypeId |
db72c0e7743e
port wifi model to Attributes
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
2503
diff
changeset
|
54 |
WifiPhy::GetTypeId (void) |
db72c0e7743e
port wifi model to Attributes
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
2503
diff
changeset
|
55 |
{ |
2602
d9262bff6df2
add back support for introspected doxygen.
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
2530
diff
changeset
|
56 |
static TypeId tid = TypeId ("ns3::WifiPhy") |
2524
db72c0e7743e
port wifi model to Attributes
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
2503
diff
changeset
|
57 |
.SetParent<Object> () |
4264
9d2e96c4e6e4
Piles of changes for tracing rework
Craig Dowell <craigdo@ee.washington.edu>
parents:
4263
diff
changeset
|
58 |
.AddTraceSource ("PhyTxBegin", |
4263
fec2f830d015
trace consistency changes
Craig Dowell <craigdo@ee.washington.edu>
parents:
4040
diff
changeset
|
59 |
"Trace source indicating a packet has begun transmitting over the channel medium", |
4264
9d2e96c4e6e4
Piles of changes for tracing rework
Craig Dowell <craigdo@ee.washington.edu>
parents:
4263
diff
changeset
|
60 |
MakeTraceSourceAccessor (&WifiPhy::m_phyTxBeginTrace)) |
9d2e96c4e6e4
Piles of changes for tracing rework
Craig Dowell <craigdo@ee.washington.edu>
parents:
4263
diff
changeset
|
61 |
.AddTraceSource ("PhyTxEnd", |
4263
fec2f830d015
trace consistency changes
Craig Dowell <craigdo@ee.washington.edu>
parents:
4040
diff
changeset
|
62 |
"Trace source indicating a packet has been completely transmitted over the channel", |
4264
9d2e96c4e6e4
Piles of changes for tracing rework
Craig Dowell <craigdo@ee.washington.edu>
parents:
4263
diff
changeset
|
63 |
MakeTraceSourceAccessor (&WifiPhy::m_phyTxEndTrace)) |
4263
fec2f830d015
trace consistency changes
Craig Dowell <craigdo@ee.washington.edu>
parents:
4040
diff
changeset
|
64 |
.AddTraceSource ("PhyTxDrop", |
fec2f830d015
trace consistency changes
Craig Dowell <craigdo@ee.washington.edu>
parents:
4040
diff
changeset
|
65 |
"Trace source indicating a packet has been dropped by the device during transmission", |
fec2f830d015
trace consistency changes
Craig Dowell <craigdo@ee.washington.edu>
parents:
4040
diff
changeset
|
66 |
MakeTraceSourceAccessor (&WifiPhy::m_phyTxDropTrace)) |
4264
9d2e96c4e6e4
Piles of changes for tracing rework
Craig Dowell <craigdo@ee.washington.edu>
parents:
4263
diff
changeset
|
67 |
.AddTraceSource ("PhyRxBegin", |
4263
fec2f830d015
trace consistency changes
Craig Dowell <craigdo@ee.washington.edu>
parents:
4040
diff
changeset
|
68 |
"Trace source indicating a packet has begun being received from the channel medium by the device", |
4264
9d2e96c4e6e4
Piles of changes for tracing rework
Craig Dowell <craigdo@ee.washington.edu>
parents:
4263
diff
changeset
|
69 |
MakeTraceSourceAccessor (&WifiPhy::m_phyRxBeginTrace)) |
9d2e96c4e6e4
Piles of changes for tracing rework
Craig Dowell <craigdo@ee.washington.edu>
parents:
4263
diff
changeset
|
70 |
.AddTraceSource ("PhyRxEnd", |
4263
fec2f830d015
trace consistency changes
Craig Dowell <craigdo@ee.washington.edu>
parents:
4040
diff
changeset
|
71 |
"Trace source indicating a packet has been completely received from the channel medium by the device", |
4264
9d2e96c4e6e4
Piles of changes for tracing rework
Craig Dowell <craigdo@ee.washington.edu>
parents:
4263
diff
changeset
|
72 |
MakeTraceSourceAccessor (&WifiPhy::m_phyRxEndTrace)) |
4263
fec2f830d015
trace consistency changes
Craig Dowell <craigdo@ee.washington.edu>
parents:
4040
diff
changeset
|
73 |
.AddTraceSource ("PhyRxDrop", |
fec2f830d015
trace consistency changes
Craig Dowell <craigdo@ee.washington.edu>
parents:
4040
diff
changeset
|
74 |
"Trace source indicating a packet has been dropped by the device during reception", |
fec2f830d015
trace consistency changes
Craig Dowell <craigdo@ee.washington.edu>
parents:
4040
diff
changeset
|
75 |
MakeTraceSourceAccessor (&WifiPhy::m_phyRxDropTrace)) |
4492
3ebeb7bf3c15
added support for radiotap and prism headers
Nicola Baldo <nbaldo@cttc.es>
parents:
4470
diff
changeset
|
76 |
.AddTraceSource ("PromiscSnifferRx", |
3ebeb7bf3c15
added support for radiotap and prism headers
Nicola Baldo <nbaldo@cttc.es>
parents:
4470
diff
changeset
|
77 |
"Trace source simulating a wifi device in monitor mode sniffing all received frames", |
3ebeb7bf3c15
added support for radiotap and prism headers
Nicola Baldo <nbaldo@cttc.es>
parents:
4470
diff
changeset
|
78 |
MakeTraceSourceAccessor (&WifiPhy::m_phyPromiscSniffRxTrace)) |
3ebeb7bf3c15
added support for radiotap and prism headers
Nicola Baldo <nbaldo@cttc.es>
parents:
4470
diff
changeset
|
79 |
.AddTraceSource ("PromiscSnifferTx", |
3ebeb7bf3c15
added support for radiotap and prism headers
Nicola Baldo <nbaldo@cttc.es>
parents:
4470
diff
changeset
|
80 |
"Trace source simulating the capability of a wifi device in monitor mode to sniff all frames being transmitted", |
3ebeb7bf3c15
added support for radiotap and prism headers
Nicola Baldo <nbaldo@cttc.es>
parents:
4470
diff
changeset
|
81 |
MakeTraceSourceAccessor (&WifiPhy::m_phyPromiscSniffTxTrace)) |
2524
db72c0e7743e
port wifi model to Attributes
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
2503
diff
changeset
|
82 |
; |
db72c0e7743e
port wifi model to Attributes
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
2503
diff
changeset
|
83 |
return tid; |
db72c0e7743e
port wifi model to Attributes
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
2503
diff
changeset
|
84 |
} |
db72c0e7743e
port wifi model to Attributes
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
2503
diff
changeset
|
85 |
|
db72c0e7743e
port wifi model to Attributes
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
2503
diff
changeset
|
86 |
WifiPhy::WifiPhy () |
2985
fa0747c4ad5e
use function logging macros
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
2782
diff
changeset
|
87 |
{ |
fa0747c4ad5e
use function logging macros
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
2782
diff
changeset
|
88 |
NS_LOG_FUNCTION (this); |
fa0747c4ad5e
use function logging macros
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
2782
diff
changeset
|
89 |
} |
2524
db72c0e7743e
port wifi model to Attributes
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
2503
diff
changeset
|
90 |
|
db72c0e7743e
port wifi model to Attributes
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
2503
diff
changeset
|
91 |
WifiPhy::~WifiPhy () |
2985
fa0747c4ad5e
use function logging macros
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
2782
diff
changeset
|
92 |
{ |
fa0747c4ad5e
use function logging macros
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
2782
diff
changeset
|
93 |
NS_LOG_FUNCTION (this); |
fa0747c4ad5e
use function logging macros
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
2782
diff
changeset
|
94 |
} |
2530
05f9cec44621
avoid memory leaks
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
2524
diff
changeset
|
95 |
|
4039
50a070c2750c
remove public static variables. Use public static methods
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
3906
diff
changeset
|
96 |
WifiMode |
50a070c2750c
remove public static variables. Use public static methods
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
3906
diff
changeset
|
97 |
WifiPhy::Get6mba (void) |
50a070c2750c
remove public static variables. Use public static methods
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
3906
diff
changeset
|
98 |
{ |
50a070c2750c
remove public static variables. Use public static methods
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
3906
diff
changeset
|
99 |
static WifiMode mode = WifiModeFactory::CreateBpsk ("wifia-6mbs", |
50a070c2750c
remove public static variables. Use public static methods
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
3906
diff
changeset
|
100 |
true, |
4681
8558474b6149
made InterferenceHelper::CalculateTxDuration () static
Nicola Baldo <nbaldo@cttc.es>
parents:
4680
diff
changeset
|
101 |
20000000, 6000000, 12000000, |
8558474b6149
made InterferenceHelper::CalculateTxDuration () static
Nicola Baldo <nbaldo@cttc.es>
parents:
4680
diff
changeset
|
102 |
WIFI_PHY_STANDARD_80211a); |
4039
50a070c2750c
remove public static variables. Use public static methods
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
3906
diff
changeset
|
103 |
return mode; |
50a070c2750c
remove public static variables. Use public static methods
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
3906
diff
changeset
|
104 |
} |
50a070c2750c
remove public static variables. Use public static methods
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
3906
diff
changeset
|
105 |
WifiMode |
50a070c2750c
remove public static variables. Use public static methods
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
3906
diff
changeset
|
106 |
WifiPhy::Get9mba (void) |
50a070c2750c
remove public static variables. Use public static methods
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
3906
diff
changeset
|
107 |
{ |
50a070c2750c
remove public static variables. Use public static methods
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
3906
diff
changeset
|
108 |
static WifiMode mode = WifiModeFactory::CreateBpsk ("wifia-9mbs", |
4040
df2f5e1ea15b
ensure that all wifi modes are registered
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
4039
diff
changeset
|
109 |
false, |
4681
8558474b6149
made InterferenceHelper::CalculateTxDuration () static
Nicola Baldo <nbaldo@cttc.es>
parents:
4680
diff
changeset
|
110 |
20000000, 9000000, 12000000, |
8558474b6149
made InterferenceHelper::CalculateTxDuration () static
Nicola Baldo <nbaldo@cttc.es>
parents:
4680
diff
changeset
|
111 |
WIFI_PHY_STANDARD_80211a); |
4039
50a070c2750c
remove public static variables. Use public static methods
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
3906
diff
changeset
|
112 |
return mode; |
50a070c2750c
remove public static variables. Use public static methods
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
3906
diff
changeset
|
113 |
} |
50a070c2750c
remove public static variables. Use public static methods
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
3906
diff
changeset
|
114 |
WifiMode |
50a070c2750c
remove public static variables. Use public static methods
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
3906
diff
changeset
|
115 |
WifiPhy::Get12mba (void) |
50a070c2750c
remove public static variables. Use public static methods
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
3906
diff
changeset
|
116 |
{ |
50a070c2750c
remove public static variables. Use public static methods
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
3906
diff
changeset
|
117 |
static WifiMode mode = WifiModeFactory::CreateBpsk ("wifia-12mbs", |
50a070c2750c
remove public static variables. Use public static methods
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
3906
diff
changeset
|
118 |
true, |
4681
8558474b6149
made InterferenceHelper::CalculateTxDuration () static
Nicola Baldo <nbaldo@cttc.es>
parents:
4680
diff
changeset
|
119 |
20000000, 12000000, 24000000, |
8558474b6149
made InterferenceHelper::CalculateTxDuration () static
Nicola Baldo <nbaldo@cttc.es>
parents:
4680
diff
changeset
|
120 |
WIFI_PHY_STANDARD_80211a); |
4039
50a070c2750c
remove public static variables. Use public static methods
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
3906
diff
changeset
|
121 |
return mode; |
50a070c2750c
remove public static variables. Use public static methods
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
3906
diff
changeset
|
122 |
} |
50a070c2750c
remove public static variables. Use public static methods
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
3906
diff
changeset
|
123 |
WifiMode |
50a070c2750c
remove public static variables. Use public static methods
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
3906
diff
changeset
|
124 |
WifiPhy::Get18mba (void) |
50a070c2750c
remove public static variables. Use public static methods
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
3906
diff
changeset
|
125 |
{ |
50a070c2750c
remove public static variables. Use public static methods
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
3906
diff
changeset
|
126 |
static WifiMode mode = WifiModeFactory::CreateBpsk ("wifia-18mbs", |
50a070c2750c
remove public static variables. Use public static methods
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
3906
diff
changeset
|
127 |
false, |
4681
8558474b6149
made InterferenceHelper::CalculateTxDuration () static
Nicola Baldo <nbaldo@cttc.es>
parents:
4680
diff
changeset
|
128 |
20000000, 18000000, 24000000, |
8558474b6149
made InterferenceHelper::CalculateTxDuration () static
Nicola Baldo <nbaldo@cttc.es>
parents:
4680
diff
changeset
|
129 |
WIFI_PHY_STANDARD_80211a); |
4039
50a070c2750c
remove public static variables. Use public static methods
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
3906
diff
changeset
|
130 |
return mode; |
50a070c2750c
remove public static variables. Use public static methods
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
3906
diff
changeset
|
131 |
} |
50a070c2750c
remove public static variables. Use public static methods
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
3906
diff
changeset
|
132 |
WifiMode |
50a070c2750c
remove public static variables. Use public static methods
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
3906
diff
changeset
|
133 |
WifiPhy::Get24mba (void) |
50a070c2750c
remove public static variables. Use public static methods
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
3906
diff
changeset
|
134 |
{ |
50a070c2750c
remove public static variables. Use public static methods
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
3906
diff
changeset
|
135 |
static WifiMode mode = WifiModeFactory::CreateBpsk ("wifia-24mbs", |
50a070c2750c
remove public static variables. Use public static methods
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
3906
diff
changeset
|
136 |
true, |
4681
8558474b6149
made InterferenceHelper::CalculateTxDuration () static
Nicola Baldo <nbaldo@cttc.es>
parents:
4680
diff
changeset
|
137 |
20000000, 24000000, 48000000, |
8558474b6149
made InterferenceHelper::CalculateTxDuration () static
Nicola Baldo <nbaldo@cttc.es>
parents:
4680
diff
changeset
|
138 |
WIFI_PHY_STANDARD_80211a); |
4039
50a070c2750c
remove public static variables. Use public static methods
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
3906
diff
changeset
|
139 |
return mode; |
50a070c2750c
remove public static variables. Use public static methods
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
3906
diff
changeset
|
140 |
} |
50a070c2750c
remove public static variables. Use public static methods
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
3906
diff
changeset
|
141 |
WifiMode |
50a070c2750c
remove public static variables. Use public static methods
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
3906
diff
changeset
|
142 |
WifiPhy::Get36mba (void) |
50a070c2750c
remove public static variables. Use public static methods
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
3906
diff
changeset
|
143 |
{ |
50a070c2750c
remove public static variables. Use public static methods
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
3906
diff
changeset
|
144 |
static WifiMode mode = WifiModeFactory::CreateBpsk ("wifia-36mbs", |
50a070c2750c
remove public static variables. Use public static methods
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
3906
diff
changeset
|
145 |
false, |
4681
8558474b6149
made InterferenceHelper::CalculateTxDuration () static
Nicola Baldo <nbaldo@cttc.es>
parents:
4680
diff
changeset
|
146 |
20000000, 36000000, 48000000, |
8558474b6149
made InterferenceHelper::CalculateTxDuration () static
Nicola Baldo <nbaldo@cttc.es>
parents:
4680
diff
changeset
|
147 |
WIFI_PHY_STANDARD_80211a); |
4039
50a070c2750c
remove public static variables. Use public static methods
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
3906
diff
changeset
|
148 |
return mode; |
50a070c2750c
remove public static variables. Use public static methods
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
3906
diff
changeset
|
149 |
} |
50a070c2750c
remove public static variables. Use public static methods
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
3906
diff
changeset
|
150 |
|
50a070c2750c
remove public static variables. Use public static methods
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
3906
diff
changeset
|
151 |
WifiMode |
50a070c2750c
remove public static variables. Use public static methods
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
3906
diff
changeset
|
152 |
WifiPhy::Get48mba (void) |
50a070c2750c
remove public static variables. Use public static methods
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
3906
diff
changeset
|
153 |
{ |
50a070c2750c
remove public static variables. Use public static methods
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
3906
diff
changeset
|
154 |
static WifiMode mode = WifiModeFactory::CreateBpsk ("wifia-48mbs", |
50a070c2750c
remove public static variables. Use public static methods
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
3906
diff
changeset
|
155 |
false, |
4681
8558474b6149
made InterferenceHelper::CalculateTxDuration () static
Nicola Baldo <nbaldo@cttc.es>
parents:
4680
diff
changeset
|
156 |
20000000, 48000000, 72000000, |
8558474b6149
made InterferenceHelper::CalculateTxDuration () static
Nicola Baldo <nbaldo@cttc.es>
parents:
4680
diff
changeset
|
157 |
WIFI_PHY_STANDARD_80211a); |
4039
50a070c2750c
remove public static variables. Use public static methods
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
3906
diff
changeset
|
158 |
return mode; |
50a070c2750c
remove public static variables. Use public static methods
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
3906
diff
changeset
|
159 |
} |
50a070c2750c
remove public static variables. Use public static methods
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
3906
diff
changeset
|
160 |
|
50a070c2750c
remove public static variables. Use public static methods
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
3906
diff
changeset
|
161 |
WifiMode |
50a070c2750c
remove public static variables. Use public static methods
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
3906
diff
changeset
|
162 |
WifiPhy::Get54mba (void) |
50a070c2750c
remove public static variables. Use public static methods
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
3906
diff
changeset
|
163 |
{ |
50a070c2750c
remove public static variables. Use public static methods
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
3906
diff
changeset
|
164 |
static WifiMode mode = WifiModeFactory::CreateBpsk ("wifia-54mbs", |
50a070c2750c
remove public static variables. Use public static methods
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
3906
diff
changeset
|
165 |
false, |
4681
8558474b6149
made InterferenceHelper::CalculateTxDuration () static
Nicola Baldo <nbaldo@cttc.es>
parents:
4680
diff
changeset
|
166 |
20000000, 54000000, 72000000, |
8558474b6149
made InterferenceHelper::CalculateTxDuration () static
Nicola Baldo <nbaldo@cttc.es>
parents:
4680
diff
changeset
|
167 |
WIFI_PHY_STANDARD_80211a); |
4039
50a070c2750c
remove public static variables. Use public static methods
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
3906
diff
changeset
|
168 |
return mode; |
50a070c2750c
remove public static variables. Use public static methods
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
3906
diff
changeset
|
169 |
} |
50a070c2750c
remove public static variables. Use public static methods
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
3906
diff
changeset
|
170 |
|
4264
9d2e96c4e6e4
Piles of changes for tracing rework
Craig Dowell <craigdo@ee.washington.edu>
parents:
4263
diff
changeset
|
171 |
void |
9d2e96c4e6e4
Piles of changes for tracing rework
Craig Dowell <craigdo@ee.washington.edu>
parents:
4263
diff
changeset
|
172 |
WifiPhy::NotifyTxBegin (Ptr<const Packet> packet) |
9d2e96c4e6e4
Piles of changes for tracing rework
Craig Dowell <craigdo@ee.washington.edu>
parents:
4263
diff
changeset
|
173 |
{ |
9d2e96c4e6e4
Piles of changes for tracing rework
Craig Dowell <craigdo@ee.washington.edu>
parents:
4263
diff
changeset
|
174 |
m_phyTxBeginTrace (packet); |
9d2e96c4e6e4
Piles of changes for tracing rework
Craig Dowell <craigdo@ee.washington.edu>
parents:
4263
diff
changeset
|
175 |
} |
9d2e96c4e6e4
Piles of changes for tracing rework
Craig Dowell <craigdo@ee.washington.edu>
parents:
4263
diff
changeset
|
176 |
|
9d2e96c4e6e4
Piles of changes for tracing rework
Craig Dowell <craigdo@ee.washington.edu>
parents:
4263
diff
changeset
|
177 |
void |
9d2e96c4e6e4
Piles of changes for tracing rework
Craig Dowell <craigdo@ee.washington.edu>
parents:
4263
diff
changeset
|
178 |
WifiPhy::NotifyTxEnd (Ptr<const Packet> packet) |
9d2e96c4e6e4
Piles of changes for tracing rework
Craig Dowell <craigdo@ee.washington.edu>
parents:
4263
diff
changeset
|
179 |
{ |
9d2e96c4e6e4
Piles of changes for tracing rework
Craig Dowell <craigdo@ee.washington.edu>
parents:
4263
diff
changeset
|
180 |
m_phyTxEndTrace (packet); |
9d2e96c4e6e4
Piles of changes for tracing rework
Craig Dowell <craigdo@ee.washington.edu>
parents:
4263
diff
changeset
|
181 |
} |
9d2e96c4e6e4
Piles of changes for tracing rework
Craig Dowell <craigdo@ee.washington.edu>
parents:
4263
diff
changeset
|
182 |
|
9d2e96c4e6e4
Piles of changes for tracing rework
Craig Dowell <craigdo@ee.washington.edu>
parents:
4263
diff
changeset
|
183 |
void |
9d2e96c4e6e4
Piles of changes for tracing rework
Craig Dowell <craigdo@ee.washington.edu>
parents:
4263
diff
changeset
|
184 |
WifiPhy::NotifyTxDrop (Ptr<const Packet> packet) |
9d2e96c4e6e4
Piles of changes for tracing rework
Craig Dowell <craigdo@ee.washington.edu>
parents:
4263
diff
changeset
|
185 |
{ |
9d2e96c4e6e4
Piles of changes for tracing rework
Craig Dowell <craigdo@ee.washington.edu>
parents:
4263
diff
changeset
|
186 |
m_phyTxDropTrace (packet); |
9d2e96c4e6e4
Piles of changes for tracing rework
Craig Dowell <craigdo@ee.washington.edu>
parents:
4263
diff
changeset
|
187 |
} |
9d2e96c4e6e4
Piles of changes for tracing rework
Craig Dowell <craigdo@ee.washington.edu>
parents:
4263
diff
changeset
|
188 |
|
9d2e96c4e6e4
Piles of changes for tracing rework
Craig Dowell <craigdo@ee.washington.edu>
parents:
4263
diff
changeset
|
189 |
void |
9d2e96c4e6e4
Piles of changes for tracing rework
Craig Dowell <craigdo@ee.washington.edu>
parents:
4263
diff
changeset
|
190 |
WifiPhy::NotifyRxBegin (Ptr<const Packet> packet) |
9d2e96c4e6e4
Piles of changes for tracing rework
Craig Dowell <craigdo@ee.washington.edu>
parents:
4263
diff
changeset
|
191 |
{ |
9d2e96c4e6e4
Piles of changes for tracing rework
Craig Dowell <craigdo@ee.washington.edu>
parents:
4263
diff
changeset
|
192 |
m_phyRxBeginTrace (packet); |
9d2e96c4e6e4
Piles of changes for tracing rework
Craig Dowell <craigdo@ee.washington.edu>
parents:
4263
diff
changeset
|
193 |
} |
9d2e96c4e6e4
Piles of changes for tracing rework
Craig Dowell <craigdo@ee.washington.edu>
parents:
4263
diff
changeset
|
194 |
|
9d2e96c4e6e4
Piles of changes for tracing rework
Craig Dowell <craigdo@ee.washington.edu>
parents:
4263
diff
changeset
|
195 |
void |
9d2e96c4e6e4
Piles of changes for tracing rework
Craig Dowell <craigdo@ee.washington.edu>
parents:
4263
diff
changeset
|
196 |
WifiPhy::NotifyRxEnd (Ptr<const Packet> packet) |
9d2e96c4e6e4
Piles of changes for tracing rework
Craig Dowell <craigdo@ee.washington.edu>
parents:
4263
diff
changeset
|
197 |
{ |
9d2e96c4e6e4
Piles of changes for tracing rework
Craig Dowell <craigdo@ee.washington.edu>
parents:
4263
diff
changeset
|
198 |
m_phyRxEndTrace (packet); |
9d2e96c4e6e4
Piles of changes for tracing rework
Craig Dowell <craigdo@ee.washington.edu>
parents:
4263
diff
changeset
|
199 |
} |
9d2e96c4e6e4
Piles of changes for tracing rework
Craig Dowell <craigdo@ee.washington.edu>
parents:
4263
diff
changeset
|
200 |
|
9d2e96c4e6e4
Piles of changes for tracing rework
Craig Dowell <craigdo@ee.washington.edu>
parents:
4263
diff
changeset
|
201 |
void |
9d2e96c4e6e4
Piles of changes for tracing rework
Craig Dowell <craigdo@ee.washington.edu>
parents:
4263
diff
changeset
|
202 |
WifiPhy::NotifyRxDrop (Ptr<const Packet> packet) |
9d2e96c4e6e4
Piles of changes for tracing rework
Craig Dowell <craigdo@ee.washington.edu>
parents:
4263
diff
changeset
|
203 |
{ |
9d2e96c4e6e4
Piles of changes for tracing rework
Craig Dowell <craigdo@ee.washington.edu>
parents:
4263
diff
changeset
|
204 |
m_phyRxDropTrace (packet); |
9d2e96c4e6e4
Piles of changes for tracing rework
Craig Dowell <craigdo@ee.washington.edu>
parents:
4263
diff
changeset
|
205 |
} |
9d2e96c4e6e4
Piles of changes for tracing rework
Craig Dowell <craigdo@ee.washington.edu>
parents:
4263
diff
changeset
|
206 |
|
9d2e96c4e6e4
Piles of changes for tracing rework
Craig Dowell <craigdo@ee.washington.edu>
parents:
4263
diff
changeset
|
207 |
void |
4715
d0041768ff60
bug 644: make sure we set standard and frequency correctly in radiotap output
Nicola Baldo <nbaldo@cttc.es>
parents:
4681
diff
changeset
|
208 |
WifiPhy::NotifyPromiscSniffRx (Ptr<const Packet> packet, uint16_t channelFreqMhz, uint16_t channelNumber, uint32_t rate, bool isShortPreamble, double signalDbm, double noiseDbm) |
4264
9d2e96c4e6e4
Piles of changes for tracing rework
Craig Dowell <craigdo@ee.washington.edu>
parents:
4263
diff
changeset
|
209 |
{ |
4715
d0041768ff60
bug 644: make sure we set standard and frequency correctly in radiotap output
Nicola Baldo <nbaldo@cttc.es>
parents:
4681
diff
changeset
|
210 |
m_phyPromiscSniffRxTrace (packet, channelFreqMhz, channelNumber, rate, isShortPreamble, signalDbm, noiseDbm); |
4492
3ebeb7bf3c15
added support for radiotap and prism headers
Nicola Baldo <nbaldo@cttc.es>
parents:
4470
diff
changeset
|
211 |
} |
3ebeb7bf3c15
added support for radiotap and prism headers
Nicola Baldo <nbaldo@cttc.es>
parents:
4470
diff
changeset
|
212 |
|
3ebeb7bf3c15
added support for radiotap and prism headers
Nicola Baldo <nbaldo@cttc.es>
parents:
4470
diff
changeset
|
213 |
void |
4715
d0041768ff60
bug 644: make sure we set standard and frequency correctly in radiotap output
Nicola Baldo <nbaldo@cttc.es>
parents:
4681
diff
changeset
|
214 |
WifiPhy::NotifyPromiscSniffTx (Ptr<const Packet> packet, uint16_t channelFreqMhz, uint16_t channelNumber, uint32_t rate, bool isShortPreamble) |
4492
3ebeb7bf3c15
added support for radiotap and prism headers
Nicola Baldo <nbaldo@cttc.es>
parents:
4470
diff
changeset
|
215 |
{ |
4715
d0041768ff60
bug 644: make sure we set standard and frequency correctly in radiotap output
Nicola Baldo <nbaldo@cttc.es>
parents:
4681
diff
changeset
|
216 |
m_phyPromiscSniffTxTrace (packet, channelFreqMhz, channelNumber, rate, isShortPreamble); |
4264
9d2e96c4e6e4
Piles of changes for tracing rework
Craig Dowell <craigdo@ee.washington.edu>
parents:
4263
diff
changeset
|
217 |
} |
9d2e96c4e6e4
Piles of changes for tracing rework
Craig Dowell <craigdo@ee.washington.edu>
parents:
4263
diff
changeset
|
218 |
|
4470 | 219 |
WifiMode |
220 |
WifiPhy::Get1mbb (void) |
|
221 |
{ |
|
222 |
static WifiMode mode = WifiModeFactory::CreateDbpsk ("wifib-1mbs", |
|
223 |
true, |
|
4681
8558474b6149
made InterferenceHelper::CalculateTxDuration () static
Nicola Baldo <nbaldo@cttc.es>
parents:
4680
diff
changeset
|
224 |
22000000, 1000000, 1000000, |
8558474b6149
made InterferenceHelper::CalculateTxDuration () static
Nicola Baldo <nbaldo@cttc.es>
parents:
4680
diff
changeset
|
225 |
WIFI_PHY_STANDARD_80211b); |
4470 | 226 |
return mode; |
227 |
} |
|
228 |
||
229 |
WifiMode |
|
230 |
WifiPhy::Get2mbb (void) |
|
231 |
{ |
|
232 |
static WifiMode mode = WifiModeFactory::CreateDqpsk ("wifib-2mbs", |
|
233 |
true, |
|
4681
8558474b6149
made InterferenceHelper::CalculateTxDuration () static
Nicola Baldo <nbaldo@cttc.es>
parents:
4680
diff
changeset
|
234 |
22000000, 2000000, 2000000, |
8558474b6149
made InterferenceHelper::CalculateTxDuration () static
Nicola Baldo <nbaldo@cttc.es>
parents:
4680
diff
changeset
|
235 |
WIFI_PHY_STANDARD_80211b); |
4470 | 236 |
return mode; |
237 |
} |
|
238 |
||
239 |
WifiMode |
|
240 |
WifiPhy::Get5_5mbb (void) |
|
241 |
{ |
|
242 |
static WifiMode mode = WifiModeFactory::CreateDqpsk ("wifib-5.5mbs", |
|
243 |
true, |
|
4681
8558474b6149
made InterferenceHelper::CalculateTxDuration () static
Nicola Baldo <nbaldo@cttc.es>
parents:
4680
diff
changeset
|
244 |
22000000, 5500000, 5500000, |
8558474b6149
made InterferenceHelper::CalculateTxDuration () static
Nicola Baldo <nbaldo@cttc.es>
parents:
4680
diff
changeset
|
245 |
WIFI_PHY_STANDARD_80211b); |
4470 | 246 |
return mode; |
247 |
} |
|
248 |
||
249 |
WifiMode |
|
250 |
WifiPhy::Get11mbb (void) |
|
251 |
{ |
|
252 |
static WifiMode mode = WifiModeFactory::CreateDqpsk ("wifib-11mbs", |
|
253 |
true, |
|
4681
8558474b6149
made InterferenceHelper::CalculateTxDuration () static
Nicola Baldo <nbaldo@cttc.es>
parents:
4680
diff
changeset
|
254 |
22000000, 11000000, 11000000, |
8558474b6149
made InterferenceHelper::CalculateTxDuration () static
Nicola Baldo <nbaldo@cttc.es>
parents:
4680
diff
changeset
|
255 |
WIFI_PHY_STANDARD_80211b); |
4470 | 256 |
return mode; |
257 |
} |
|
258 |
||
4680
a52c39181dd4
Support for 5 and 10Mhz wifi channels
Ramon Bauza <monbauza@gmail.com>
parents:
4492
diff
changeset
|
259 |
WifiMode |
a52c39181dd4
Support for 5 and 10Mhz wifi channels
Ramon Bauza <monbauza@gmail.com>
parents:
4492
diff
changeset
|
260 |
WifiPhy::Get3mb10Mhz (void) |
a52c39181dd4
Support for 5 and 10Mhz wifi channels
Ramon Bauza <monbauza@gmail.com>
parents:
4492
diff
changeset
|
261 |
{ |
a52c39181dd4
Support for 5 and 10Mhz wifi channels
Ramon Bauza <monbauza@gmail.com>
parents:
4492
diff
changeset
|
262 |
static WifiMode mode = WifiModeFactory::CreateBpsk ("wifi-3mbs-10Mhz", |
a52c39181dd4
Support for 5 and 10Mhz wifi channels
Ramon Bauza <monbauza@gmail.com>
parents:
4492
diff
changeset
|
263 |
true, |
4681
8558474b6149
made InterferenceHelper::CalculateTxDuration () static
Nicola Baldo <nbaldo@cttc.es>
parents:
4680
diff
changeset
|
264 |
10000000, 3000000, 6000000, |
8558474b6149
made InterferenceHelper::CalculateTxDuration () static
Nicola Baldo <nbaldo@cttc.es>
parents:
4680
diff
changeset
|
265 |
WIFI_PHY_STANDARD_80211_10Mhz); |
4680
a52c39181dd4
Support for 5 and 10Mhz wifi channels
Ramon Bauza <monbauza@gmail.com>
parents:
4492
diff
changeset
|
266 |
return mode; |
a52c39181dd4
Support for 5 and 10Mhz wifi channels
Ramon Bauza <monbauza@gmail.com>
parents:
4492
diff
changeset
|
267 |
} |
a52c39181dd4
Support for 5 and 10Mhz wifi channels
Ramon Bauza <monbauza@gmail.com>
parents:
4492
diff
changeset
|
268 |
|
a52c39181dd4
Support for 5 and 10Mhz wifi channels
Ramon Bauza <monbauza@gmail.com>
parents:
4492
diff
changeset
|
269 |
WifiMode |
a52c39181dd4
Support for 5 and 10Mhz wifi channels
Ramon Bauza <monbauza@gmail.com>
parents:
4492
diff
changeset
|
270 |
WifiPhy::Get4_5mb10Mhz (void) |
a52c39181dd4
Support for 5 and 10Mhz wifi channels
Ramon Bauza <monbauza@gmail.com>
parents:
4492
diff
changeset
|
271 |
{ |
a52c39181dd4
Support for 5 and 10Mhz wifi channels
Ramon Bauza <monbauza@gmail.com>
parents:
4492
diff
changeset
|
272 |
static WifiMode mode = WifiModeFactory::CreateBpsk ("wifi-4.5mbs-10Mhz", |
a52c39181dd4
Support for 5 and 10Mhz wifi channels
Ramon Bauza <monbauza@gmail.com>
parents:
4492
diff
changeset
|
273 |
false, |
4681
8558474b6149
made InterferenceHelper::CalculateTxDuration () static
Nicola Baldo <nbaldo@cttc.es>
parents:
4680
diff
changeset
|
274 |
10000000, 4500000, 6000000, |
8558474b6149
made InterferenceHelper::CalculateTxDuration () static
Nicola Baldo <nbaldo@cttc.es>
parents:
4680
diff
changeset
|
275 |
WIFI_PHY_STANDARD_80211_10Mhz); |
4680
a52c39181dd4
Support for 5 and 10Mhz wifi channels
Ramon Bauza <monbauza@gmail.com>
parents:
4492
diff
changeset
|
276 |
return mode; |
a52c39181dd4
Support for 5 and 10Mhz wifi channels
Ramon Bauza <monbauza@gmail.com>
parents:
4492
diff
changeset
|
277 |
} |
a52c39181dd4
Support for 5 and 10Mhz wifi channels
Ramon Bauza <monbauza@gmail.com>
parents:
4492
diff
changeset
|
278 |
|
a52c39181dd4
Support for 5 and 10Mhz wifi channels
Ramon Bauza <monbauza@gmail.com>
parents:
4492
diff
changeset
|
279 |
WifiMode |
a52c39181dd4
Support for 5 and 10Mhz wifi channels
Ramon Bauza <monbauza@gmail.com>
parents:
4492
diff
changeset
|
280 |
WifiPhy::Get6mb10Mhz (void) |
a52c39181dd4
Support for 5 and 10Mhz wifi channels
Ramon Bauza <monbauza@gmail.com>
parents:
4492
diff
changeset
|
281 |
{ |
a52c39181dd4
Support for 5 and 10Mhz wifi channels
Ramon Bauza <monbauza@gmail.com>
parents:
4492
diff
changeset
|
282 |
static WifiMode mode = WifiModeFactory::CreateBpsk ("wifi-6mbs-10Mhz", |
a52c39181dd4
Support for 5 and 10Mhz wifi channels
Ramon Bauza <monbauza@gmail.com>
parents:
4492
diff
changeset
|
283 |
true, |
4681
8558474b6149
made InterferenceHelper::CalculateTxDuration () static
Nicola Baldo <nbaldo@cttc.es>
parents:
4680
diff
changeset
|
284 |
10000000, 6000000, 12000000, |
8558474b6149
made InterferenceHelper::CalculateTxDuration () static
Nicola Baldo <nbaldo@cttc.es>
parents:
4680
diff
changeset
|
285 |
WIFI_PHY_STANDARD_80211_10Mhz); |
4680
a52c39181dd4
Support for 5 and 10Mhz wifi channels
Ramon Bauza <monbauza@gmail.com>
parents:
4492
diff
changeset
|
286 |
return mode; |
a52c39181dd4
Support for 5 and 10Mhz wifi channels
Ramon Bauza <monbauza@gmail.com>
parents:
4492
diff
changeset
|
287 |
} |
a52c39181dd4
Support for 5 and 10Mhz wifi channels
Ramon Bauza <monbauza@gmail.com>
parents:
4492
diff
changeset
|
288 |
|
a52c39181dd4
Support for 5 and 10Mhz wifi channels
Ramon Bauza <monbauza@gmail.com>
parents:
4492
diff
changeset
|
289 |
WifiMode |
a52c39181dd4
Support for 5 and 10Mhz wifi channels
Ramon Bauza <monbauza@gmail.com>
parents:
4492
diff
changeset
|
290 |
WifiPhy::Get9mb10Mhz (void) |
a52c39181dd4
Support for 5 and 10Mhz wifi channels
Ramon Bauza <monbauza@gmail.com>
parents:
4492
diff
changeset
|
291 |
{ |
a52c39181dd4
Support for 5 and 10Mhz wifi channels
Ramon Bauza <monbauza@gmail.com>
parents:
4492
diff
changeset
|
292 |
static WifiMode mode = WifiModeFactory::CreateBpsk ("wifi-9mbs-10Mhz", |
a52c39181dd4
Support for 5 and 10Mhz wifi channels
Ramon Bauza <monbauza@gmail.com>
parents:
4492
diff
changeset
|
293 |
false, |
4681
8558474b6149
made InterferenceHelper::CalculateTxDuration () static
Nicola Baldo <nbaldo@cttc.es>
parents:
4680
diff
changeset
|
294 |
10000000, 9000000, 12000000, |
8558474b6149
made InterferenceHelper::CalculateTxDuration () static
Nicola Baldo <nbaldo@cttc.es>
parents:
4680
diff
changeset
|
295 |
WIFI_PHY_STANDARD_80211_10Mhz); |
4680
a52c39181dd4
Support for 5 and 10Mhz wifi channels
Ramon Bauza <monbauza@gmail.com>
parents:
4492
diff
changeset
|
296 |
return mode; |
a52c39181dd4
Support for 5 and 10Mhz wifi channels
Ramon Bauza <monbauza@gmail.com>
parents:
4492
diff
changeset
|
297 |
} |
a52c39181dd4
Support for 5 and 10Mhz wifi channels
Ramon Bauza <monbauza@gmail.com>
parents:
4492
diff
changeset
|
298 |
|
a52c39181dd4
Support for 5 and 10Mhz wifi channels
Ramon Bauza <monbauza@gmail.com>
parents:
4492
diff
changeset
|
299 |
WifiMode |
a52c39181dd4
Support for 5 and 10Mhz wifi channels
Ramon Bauza <monbauza@gmail.com>
parents:
4492
diff
changeset
|
300 |
WifiPhy::Get12mb10Mhz (void) |
a52c39181dd4
Support for 5 and 10Mhz wifi channels
Ramon Bauza <monbauza@gmail.com>
parents:
4492
diff
changeset
|
301 |
{ |
a52c39181dd4
Support for 5 and 10Mhz wifi channels
Ramon Bauza <monbauza@gmail.com>
parents:
4492
diff
changeset
|
302 |
static WifiMode mode = WifiModeFactory::CreateBpsk ("wifi-12mbs-10Mhz", |
a52c39181dd4
Support for 5 and 10Mhz wifi channels
Ramon Bauza <monbauza@gmail.com>
parents:
4492
diff
changeset
|
303 |
true, |
4681
8558474b6149
made InterferenceHelper::CalculateTxDuration () static
Nicola Baldo <nbaldo@cttc.es>
parents:
4680
diff
changeset
|
304 |
10000000, 12000000, 24000000, |
8558474b6149
made InterferenceHelper::CalculateTxDuration () static
Nicola Baldo <nbaldo@cttc.es>
parents:
4680
diff
changeset
|
305 |
WIFI_PHY_STANDARD_80211_10Mhz); |
4680
a52c39181dd4
Support for 5 and 10Mhz wifi channels
Ramon Bauza <monbauza@gmail.com>
parents:
4492
diff
changeset
|
306 |
return mode; |
a52c39181dd4
Support for 5 and 10Mhz wifi channels
Ramon Bauza <monbauza@gmail.com>
parents:
4492
diff
changeset
|
307 |
} |
a52c39181dd4
Support for 5 and 10Mhz wifi channels
Ramon Bauza <monbauza@gmail.com>
parents:
4492
diff
changeset
|
308 |
|
a52c39181dd4
Support for 5 and 10Mhz wifi channels
Ramon Bauza <monbauza@gmail.com>
parents:
4492
diff
changeset
|
309 |
WifiMode |
a52c39181dd4
Support for 5 and 10Mhz wifi channels
Ramon Bauza <monbauza@gmail.com>
parents:
4492
diff
changeset
|
310 |
WifiPhy::Get18mb10Mhz (void) |
a52c39181dd4
Support for 5 and 10Mhz wifi channels
Ramon Bauza <monbauza@gmail.com>
parents:
4492
diff
changeset
|
311 |
{ |
a52c39181dd4
Support for 5 and 10Mhz wifi channels
Ramon Bauza <monbauza@gmail.com>
parents:
4492
diff
changeset
|
312 |
static WifiMode mode = WifiModeFactory::CreateBpsk ("wifi-18mbs-10Mhz", |
a52c39181dd4
Support for 5 and 10Mhz wifi channels
Ramon Bauza <monbauza@gmail.com>
parents:
4492
diff
changeset
|
313 |
false, |
4681
8558474b6149
made InterferenceHelper::CalculateTxDuration () static
Nicola Baldo <nbaldo@cttc.es>
parents:
4680
diff
changeset
|
314 |
10000000, 18000000, 24000000, |
8558474b6149
made InterferenceHelper::CalculateTxDuration () static
Nicola Baldo <nbaldo@cttc.es>
parents:
4680
diff
changeset
|
315 |
WIFI_PHY_STANDARD_80211_10Mhz); |
4680
a52c39181dd4
Support for 5 and 10Mhz wifi channels
Ramon Bauza <monbauza@gmail.com>
parents:
4492
diff
changeset
|
316 |
return mode; |
a52c39181dd4
Support for 5 and 10Mhz wifi channels
Ramon Bauza <monbauza@gmail.com>
parents:
4492
diff
changeset
|
317 |
} |
a52c39181dd4
Support for 5 and 10Mhz wifi channels
Ramon Bauza <monbauza@gmail.com>
parents:
4492
diff
changeset
|
318 |
|
a52c39181dd4
Support for 5 and 10Mhz wifi channels
Ramon Bauza <monbauza@gmail.com>
parents:
4492
diff
changeset
|
319 |
WifiMode |
a52c39181dd4
Support for 5 and 10Mhz wifi channels
Ramon Bauza <monbauza@gmail.com>
parents:
4492
diff
changeset
|
320 |
WifiPhy::Get24mb10Mhz (void) |
a52c39181dd4
Support for 5 and 10Mhz wifi channels
Ramon Bauza <monbauza@gmail.com>
parents:
4492
diff
changeset
|
321 |
{ |
a52c39181dd4
Support for 5 and 10Mhz wifi channels
Ramon Bauza <monbauza@gmail.com>
parents:
4492
diff
changeset
|
322 |
static WifiMode mode = WifiModeFactory::CreateBpsk ("wifi-24mbs-10Mhz", |
a52c39181dd4
Support for 5 and 10Mhz wifi channels
Ramon Bauza <monbauza@gmail.com>
parents:
4492
diff
changeset
|
323 |
false, |
4681
8558474b6149
made InterferenceHelper::CalculateTxDuration () static
Nicola Baldo <nbaldo@cttc.es>
parents:
4680
diff
changeset
|
324 |
10000000, 24000000, 36000000, |
8558474b6149
made InterferenceHelper::CalculateTxDuration () static
Nicola Baldo <nbaldo@cttc.es>
parents:
4680
diff
changeset
|
325 |
WIFI_PHY_STANDARD_80211_10Mhz); |
4680
a52c39181dd4
Support for 5 and 10Mhz wifi channels
Ramon Bauza <monbauza@gmail.com>
parents:
4492
diff
changeset
|
326 |
return mode; |
a52c39181dd4
Support for 5 and 10Mhz wifi channels
Ramon Bauza <monbauza@gmail.com>
parents:
4492
diff
changeset
|
327 |
} |
a52c39181dd4
Support for 5 and 10Mhz wifi channels
Ramon Bauza <monbauza@gmail.com>
parents:
4492
diff
changeset
|
328 |
|
a52c39181dd4
Support for 5 and 10Mhz wifi channels
Ramon Bauza <monbauza@gmail.com>
parents:
4492
diff
changeset
|
329 |
WifiMode |
a52c39181dd4
Support for 5 and 10Mhz wifi channels
Ramon Bauza <monbauza@gmail.com>
parents:
4492
diff
changeset
|
330 |
WifiPhy::Get27mb10Mhz (void) |
a52c39181dd4
Support for 5 and 10Mhz wifi channels
Ramon Bauza <monbauza@gmail.com>
parents:
4492
diff
changeset
|
331 |
{ |
a52c39181dd4
Support for 5 and 10Mhz wifi channels
Ramon Bauza <monbauza@gmail.com>
parents:
4492
diff
changeset
|
332 |
static WifiMode mode = WifiModeFactory::CreateBpsk ("wifi-27mbs-10Mhz", |
a52c39181dd4
Support for 5 and 10Mhz wifi channels
Ramon Bauza <monbauza@gmail.com>
parents:
4492
diff
changeset
|
333 |
false, |
4681
8558474b6149
made InterferenceHelper::CalculateTxDuration () static
Nicola Baldo <nbaldo@cttc.es>
parents:
4680
diff
changeset
|
334 |
10000000, 27000000, 36000000, |
8558474b6149
made InterferenceHelper::CalculateTxDuration () static
Nicola Baldo <nbaldo@cttc.es>
parents:
4680
diff
changeset
|
335 |
WIFI_PHY_STANDARD_80211_10Mhz); |
4680
a52c39181dd4
Support for 5 and 10Mhz wifi channels
Ramon Bauza <monbauza@gmail.com>
parents:
4492
diff
changeset
|
336 |
return mode; |
a52c39181dd4
Support for 5 and 10Mhz wifi channels
Ramon Bauza <monbauza@gmail.com>
parents:
4492
diff
changeset
|
337 |
} |
a52c39181dd4
Support for 5 and 10Mhz wifi channels
Ramon Bauza <monbauza@gmail.com>
parents:
4492
diff
changeset
|
338 |
|
a52c39181dd4
Support for 5 and 10Mhz wifi channels
Ramon Bauza <monbauza@gmail.com>
parents:
4492
diff
changeset
|
339 |
WifiMode |
a52c39181dd4
Support for 5 and 10Mhz wifi channels
Ramon Bauza <monbauza@gmail.com>
parents:
4492
diff
changeset
|
340 |
WifiPhy::Get1_5mb5Mhz (void) |
a52c39181dd4
Support for 5 and 10Mhz wifi channels
Ramon Bauza <monbauza@gmail.com>
parents:
4492
diff
changeset
|
341 |
{ |
a52c39181dd4
Support for 5 and 10Mhz wifi channels
Ramon Bauza <monbauza@gmail.com>
parents:
4492
diff
changeset
|
342 |
static WifiMode mode = WifiModeFactory::CreateBpsk ("wifi-1_5mbs-5Mhz", |
a52c39181dd4
Support for 5 and 10Mhz wifi channels
Ramon Bauza <monbauza@gmail.com>
parents:
4492
diff
changeset
|
343 |
true, |
4681
8558474b6149
made InterferenceHelper::CalculateTxDuration () static
Nicola Baldo <nbaldo@cttc.es>
parents:
4680
diff
changeset
|
344 |
5000000, 1500000, 3000000, |
8558474b6149
made InterferenceHelper::CalculateTxDuration () static
Nicola Baldo <nbaldo@cttc.es>
parents:
4680
diff
changeset
|
345 |
WIFI_PHY_STANDARD_80211_5Mhz); |
4680
a52c39181dd4
Support for 5 and 10Mhz wifi channels
Ramon Bauza <monbauza@gmail.com>
parents:
4492
diff
changeset
|
346 |
return mode; |
a52c39181dd4
Support for 5 and 10Mhz wifi channels
Ramon Bauza <monbauza@gmail.com>
parents:
4492
diff
changeset
|
347 |
} |
a52c39181dd4
Support for 5 and 10Mhz wifi channels
Ramon Bauza <monbauza@gmail.com>
parents:
4492
diff
changeset
|
348 |
|
a52c39181dd4
Support for 5 and 10Mhz wifi channels
Ramon Bauza <monbauza@gmail.com>
parents:
4492
diff
changeset
|
349 |
WifiMode |
a52c39181dd4
Support for 5 and 10Mhz wifi channels
Ramon Bauza <monbauza@gmail.com>
parents:
4492
diff
changeset
|
350 |
WifiPhy::Get2_25mb5Mhz (void) |
a52c39181dd4
Support for 5 and 10Mhz wifi channels
Ramon Bauza <monbauza@gmail.com>
parents:
4492
diff
changeset
|
351 |
{ |
a52c39181dd4
Support for 5 and 10Mhz wifi channels
Ramon Bauza <monbauza@gmail.com>
parents:
4492
diff
changeset
|
352 |
static WifiMode mode = WifiModeFactory::CreateBpsk ("wifi-2.25mbs-5Mhz", |
a52c39181dd4
Support for 5 and 10Mhz wifi channels
Ramon Bauza <monbauza@gmail.com>
parents:
4492
diff
changeset
|
353 |
false, |
4681
8558474b6149
made InterferenceHelper::CalculateTxDuration () static
Nicola Baldo <nbaldo@cttc.es>
parents:
4680
diff
changeset
|
354 |
5000000, 2250000, 3000000, |
8558474b6149
made InterferenceHelper::CalculateTxDuration () static
Nicola Baldo <nbaldo@cttc.es>
parents:
4680
diff
changeset
|
355 |
WIFI_PHY_STANDARD_80211_5Mhz); |
4680
a52c39181dd4
Support for 5 and 10Mhz wifi channels
Ramon Bauza <monbauza@gmail.com>
parents:
4492
diff
changeset
|
356 |
return mode; |
a52c39181dd4
Support for 5 and 10Mhz wifi channels
Ramon Bauza <monbauza@gmail.com>
parents:
4492
diff
changeset
|
357 |
} |
a52c39181dd4
Support for 5 and 10Mhz wifi channels
Ramon Bauza <monbauza@gmail.com>
parents:
4492
diff
changeset
|
358 |
|
a52c39181dd4
Support for 5 and 10Mhz wifi channels
Ramon Bauza <monbauza@gmail.com>
parents:
4492
diff
changeset
|
359 |
WifiMode |
a52c39181dd4
Support for 5 and 10Mhz wifi channels
Ramon Bauza <monbauza@gmail.com>
parents:
4492
diff
changeset
|
360 |
WifiPhy::Get3mb5Mhz (void) |
a52c39181dd4
Support for 5 and 10Mhz wifi channels
Ramon Bauza <monbauza@gmail.com>
parents:
4492
diff
changeset
|
361 |
{ |
a52c39181dd4
Support for 5 and 10Mhz wifi channels
Ramon Bauza <monbauza@gmail.com>
parents:
4492
diff
changeset
|
362 |
static WifiMode mode = WifiModeFactory::CreateBpsk ("wifi-3mbs-5Mhz", |
a52c39181dd4
Support for 5 and 10Mhz wifi channels
Ramon Bauza <monbauza@gmail.com>
parents:
4492
diff
changeset
|
363 |
true, |
4681
8558474b6149
made InterferenceHelper::CalculateTxDuration () static
Nicola Baldo <nbaldo@cttc.es>
parents:
4680
diff
changeset
|
364 |
5000000, 3000000, 6000000, |
8558474b6149
made InterferenceHelper::CalculateTxDuration () static
Nicola Baldo <nbaldo@cttc.es>
parents:
4680
diff
changeset
|
365 |
WIFI_PHY_STANDARD_80211_5Mhz); |
4680
a52c39181dd4
Support for 5 and 10Mhz wifi channels
Ramon Bauza <monbauza@gmail.com>
parents:
4492
diff
changeset
|
366 |
return mode; |
a52c39181dd4
Support for 5 and 10Mhz wifi channels
Ramon Bauza <monbauza@gmail.com>
parents:
4492
diff
changeset
|
367 |
} |
a52c39181dd4
Support for 5 and 10Mhz wifi channels
Ramon Bauza <monbauza@gmail.com>
parents:
4492
diff
changeset
|
368 |
|
a52c39181dd4
Support for 5 and 10Mhz wifi channels
Ramon Bauza <monbauza@gmail.com>
parents:
4492
diff
changeset
|
369 |
WifiMode |
a52c39181dd4
Support for 5 and 10Mhz wifi channels
Ramon Bauza <monbauza@gmail.com>
parents:
4492
diff
changeset
|
370 |
WifiPhy::Get4_5mb5Mhz (void) |
a52c39181dd4
Support for 5 and 10Mhz wifi channels
Ramon Bauza <monbauza@gmail.com>
parents:
4492
diff
changeset
|
371 |
{ |
a52c39181dd4
Support for 5 and 10Mhz wifi channels
Ramon Bauza <monbauza@gmail.com>
parents:
4492
diff
changeset
|
372 |
static WifiMode mode = WifiModeFactory::CreateBpsk ("wifi-4.5mbs-5Mhz", |
a52c39181dd4
Support for 5 and 10Mhz wifi channels
Ramon Bauza <monbauza@gmail.com>
parents:
4492
diff
changeset
|
373 |
false, |
4681
8558474b6149
made InterferenceHelper::CalculateTxDuration () static
Nicola Baldo <nbaldo@cttc.es>
parents:
4680
diff
changeset
|
374 |
5000000, 4500000, 6000000, |
8558474b6149
made InterferenceHelper::CalculateTxDuration () static
Nicola Baldo <nbaldo@cttc.es>
parents:
4680
diff
changeset
|
375 |
WIFI_PHY_STANDARD_80211_5Mhz); |
4680
a52c39181dd4
Support for 5 and 10Mhz wifi channels
Ramon Bauza <monbauza@gmail.com>
parents:
4492
diff
changeset
|
376 |
return mode; |
a52c39181dd4
Support for 5 and 10Mhz wifi channels
Ramon Bauza <monbauza@gmail.com>
parents:
4492
diff
changeset
|
377 |
} |
a52c39181dd4
Support for 5 and 10Mhz wifi channels
Ramon Bauza <monbauza@gmail.com>
parents:
4492
diff
changeset
|
378 |
|
a52c39181dd4
Support for 5 and 10Mhz wifi channels
Ramon Bauza <monbauza@gmail.com>
parents:
4492
diff
changeset
|
379 |
WifiMode |
a52c39181dd4
Support for 5 and 10Mhz wifi channels
Ramon Bauza <monbauza@gmail.com>
parents:
4492
diff
changeset
|
380 |
WifiPhy::Get6mb5Mhz (void) |
a52c39181dd4
Support for 5 and 10Mhz wifi channels
Ramon Bauza <monbauza@gmail.com>
parents:
4492
diff
changeset
|
381 |
{ |
a52c39181dd4
Support for 5 and 10Mhz wifi channels
Ramon Bauza <monbauza@gmail.com>
parents:
4492
diff
changeset
|
382 |
static WifiMode mode = WifiModeFactory::CreateBpsk ("wifi-6mbs-5Mhz", |
a52c39181dd4
Support for 5 and 10Mhz wifi channels
Ramon Bauza <monbauza@gmail.com>
parents:
4492
diff
changeset
|
383 |
true, |
4681
8558474b6149
made InterferenceHelper::CalculateTxDuration () static
Nicola Baldo <nbaldo@cttc.es>
parents:
4680
diff
changeset
|
384 |
5000000, 6000000, 12000000, |
8558474b6149
made InterferenceHelper::CalculateTxDuration () static
Nicola Baldo <nbaldo@cttc.es>
parents:
4680
diff
changeset
|
385 |
WIFI_PHY_STANDARD_80211_5Mhz); |
4680
a52c39181dd4
Support for 5 and 10Mhz wifi channels
Ramon Bauza <monbauza@gmail.com>
parents:
4492
diff
changeset
|
386 |
return mode; |
a52c39181dd4
Support for 5 and 10Mhz wifi channels
Ramon Bauza <monbauza@gmail.com>
parents:
4492
diff
changeset
|
387 |
} |
a52c39181dd4
Support for 5 and 10Mhz wifi channels
Ramon Bauza <monbauza@gmail.com>
parents:
4492
diff
changeset
|
388 |
|
a52c39181dd4
Support for 5 and 10Mhz wifi channels
Ramon Bauza <monbauza@gmail.com>
parents:
4492
diff
changeset
|
389 |
WifiMode |
a52c39181dd4
Support for 5 and 10Mhz wifi channels
Ramon Bauza <monbauza@gmail.com>
parents:
4492
diff
changeset
|
390 |
WifiPhy::Get9mb5Mhz (void) |
a52c39181dd4
Support for 5 and 10Mhz wifi channels
Ramon Bauza <monbauza@gmail.com>
parents:
4492
diff
changeset
|
391 |
{ |
a52c39181dd4
Support for 5 and 10Mhz wifi channels
Ramon Bauza <monbauza@gmail.com>
parents:
4492
diff
changeset
|
392 |
static WifiMode mode = WifiModeFactory::CreateBpsk ("wifi-9mbs-5Mhz", |
a52c39181dd4
Support for 5 and 10Mhz wifi channels
Ramon Bauza <monbauza@gmail.com>
parents:
4492
diff
changeset
|
393 |
false, |
5294
684768c10c59
wifi: bandwidth fixed for 5MHz modes
Pavel Boyko <boyko@iitp.ru>
parents:
4715
diff
changeset
|
394 |
5000000, 9000000, 12000000, |
4681
8558474b6149
made InterferenceHelper::CalculateTxDuration () static
Nicola Baldo <nbaldo@cttc.es>
parents:
4680
diff
changeset
|
395 |
WIFI_PHY_STANDARD_80211_5Mhz); |
4680
a52c39181dd4
Support for 5 and 10Mhz wifi channels
Ramon Bauza <monbauza@gmail.com>
parents:
4492
diff
changeset
|
396 |
return mode; |
a52c39181dd4
Support for 5 and 10Mhz wifi channels
Ramon Bauza <monbauza@gmail.com>
parents:
4492
diff
changeset
|
397 |
} |
a52c39181dd4
Support for 5 and 10Mhz wifi channels
Ramon Bauza <monbauza@gmail.com>
parents:
4492
diff
changeset
|
398 |
|
a52c39181dd4
Support for 5 and 10Mhz wifi channels
Ramon Bauza <monbauza@gmail.com>
parents:
4492
diff
changeset
|
399 |
WifiMode |
a52c39181dd4
Support for 5 and 10Mhz wifi channels
Ramon Bauza <monbauza@gmail.com>
parents:
4492
diff
changeset
|
400 |
WifiPhy::Get12mb5Mhz (void) |
a52c39181dd4
Support for 5 and 10Mhz wifi channels
Ramon Bauza <monbauza@gmail.com>
parents:
4492
diff
changeset
|
401 |
{ |
a52c39181dd4
Support for 5 and 10Mhz wifi channels
Ramon Bauza <monbauza@gmail.com>
parents:
4492
diff
changeset
|
402 |
static WifiMode mode = WifiModeFactory::CreateBpsk ("wifi-12mbs-5Mhz", |
a52c39181dd4
Support for 5 and 10Mhz wifi channels
Ramon Bauza <monbauza@gmail.com>
parents:
4492
diff
changeset
|
403 |
false, |
5294
684768c10c59
wifi: bandwidth fixed for 5MHz modes
Pavel Boyko <boyko@iitp.ru>
parents:
4715
diff
changeset
|
404 |
5000000, 12000000, 18000000, |
4681
8558474b6149
made InterferenceHelper::CalculateTxDuration () static
Nicola Baldo <nbaldo@cttc.es>
parents:
4680
diff
changeset
|
405 |
WIFI_PHY_STANDARD_80211_5Mhz); |
4680
a52c39181dd4
Support for 5 and 10Mhz wifi channels
Ramon Bauza <monbauza@gmail.com>
parents:
4492
diff
changeset
|
406 |
return mode; |
a52c39181dd4
Support for 5 and 10Mhz wifi channels
Ramon Bauza <monbauza@gmail.com>
parents:
4492
diff
changeset
|
407 |
} |
a52c39181dd4
Support for 5 and 10Mhz wifi channels
Ramon Bauza <monbauza@gmail.com>
parents:
4492
diff
changeset
|
408 |
|
a52c39181dd4
Support for 5 and 10Mhz wifi channels
Ramon Bauza <monbauza@gmail.com>
parents:
4492
diff
changeset
|
409 |
WifiMode |
a52c39181dd4
Support for 5 and 10Mhz wifi channels
Ramon Bauza <monbauza@gmail.com>
parents:
4492
diff
changeset
|
410 |
WifiPhy::Get13_5mb5Mhz (void) |
a52c39181dd4
Support for 5 and 10Mhz wifi channels
Ramon Bauza <monbauza@gmail.com>
parents:
4492
diff
changeset
|
411 |
{ |
a52c39181dd4
Support for 5 and 10Mhz wifi channels
Ramon Bauza <monbauza@gmail.com>
parents:
4492
diff
changeset
|
412 |
static WifiMode mode = WifiModeFactory::CreateBpsk ("wifi-13.5mbs-5Mhz", |
a52c39181dd4
Support for 5 and 10Mhz wifi channels
Ramon Bauza <monbauza@gmail.com>
parents:
4492
diff
changeset
|
413 |
false, |
5294
684768c10c59
wifi: bandwidth fixed for 5MHz modes
Pavel Boyko <boyko@iitp.ru>
parents:
4715
diff
changeset
|
414 |
5000000, 13500000, 18000000, |
4681
8558474b6149
made InterferenceHelper::CalculateTxDuration () static
Nicola Baldo <nbaldo@cttc.es>
parents:
4680
diff
changeset
|
415 |
WIFI_PHY_STANDARD_80211_5Mhz); |
4680
a52c39181dd4
Support for 5 and 10Mhz wifi channels
Ramon Bauza <monbauza@gmail.com>
parents:
4492
diff
changeset
|
416 |
return mode; |
a52c39181dd4
Support for 5 and 10Mhz wifi channels
Ramon Bauza <monbauza@gmail.com>
parents:
4492
diff
changeset
|
417 |
} |
a52c39181dd4
Support for 5 and 10Mhz wifi channels
Ramon Bauza <monbauza@gmail.com>
parents:
4492
diff
changeset
|
418 |
|
5820
1c02054740eb
Renaming WifiPhy state SYNC to RX to avoid confusion with "synchronizing".
Timo Bingmann <tbns@idlebox.net>
parents:
5294
diff
changeset
|
419 |
std::ostream& operator<< (std::ostream& os, enum WifiPhy::State state) |
1c02054740eb
Renaming WifiPhy state SYNC to RX to avoid confusion with "synchronizing".
Timo Bingmann <tbns@idlebox.net>
parents:
5294
diff
changeset
|
420 |
{ |
1c02054740eb
Renaming WifiPhy state SYNC to RX to avoid confusion with "synchronizing".
Timo Bingmann <tbns@idlebox.net>
parents:
5294
diff
changeset
|
421 |
switch (state) { |
1c02054740eb
Renaming WifiPhy state SYNC to RX to avoid confusion with "synchronizing".
Timo Bingmann <tbns@idlebox.net>
parents:
5294
diff
changeset
|
422 |
case WifiPhy::IDLE: |
1c02054740eb
Renaming WifiPhy state SYNC to RX to avoid confusion with "synchronizing".
Timo Bingmann <tbns@idlebox.net>
parents:
5294
diff
changeset
|
423 |
return (os << "IDLE"); |
1c02054740eb
Renaming WifiPhy state SYNC to RX to avoid confusion with "synchronizing".
Timo Bingmann <tbns@idlebox.net>
parents:
5294
diff
changeset
|
424 |
case WifiPhy::CCA_BUSY: |
1c02054740eb
Renaming WifiPhy state SYNC to RX to avoid confusion with "synchronizing".
Timo Bingmann <tbns@idlebox.net>
parents:
5294
diff
changeset
|
425 |
return (os << "CCA_BUSY"); |
1c02054740eb
Renaming WifiPhy state SYNC to RX to avoid confusion with "synchronizing".
Timo Bingmann <tbns@idlebox.net>
parents:
5294
diff
changeset
|
426 |
case WifiPhy::TX: |
1c02054740eb
Renaming WifiPhy state SYNC to RX to avoid confusion with "synchronizing".
Timo Bingmann <tbns@idlebox.net>
parents:
5294
diff
changeset
|
427 |
return (os << "TX"); |
1c02054740eb
Renaming WifiPhy state SYNC to RX to avoid confusion with "synchronizing".
Timo Bingmann <tbns@idlebox.net>
parents:
5294
diff
changeset
|
428 |
case WifiPhy::RX: |
1c02054740eb
Renaming WifiPhy state SYNC to RX to avoid confusion with "synchronizing".
Timo Bingmann <tbns@idlebox.net>
parents:
5294
diff
changeset
|
429 |
return (os << "RX"); |
1c02054740eb
Renaming WifiPhy state SYNC to RX to avoid confusion with "synchronizing".
Timo Bingmann <tbns@idlebox.net>
parents:
5294
diff
changeset
|
430 |
case WifiPhy::SWITCHING: |
1c02054740eb
Renaming WifiPhy state SYNC to RX to avoid confusion with "synchronizing".
Timo Bingmann <tbns@idlebox.net>
parents:
5294
diff
changeset
|
431 |
return (os << "SWITCHING"); |
1c02054740eb
Renaming WifiPhy state SYNC to RX to avoid confusion with "synchronizing".
Timo Bingmann <tbns@idlebox.net>
parents:
5294
diff
changeset
|
432 |
default: |
1c02054740eb
Renaming WifiPhy state SYNC to RX to avoid confusion with "synchronizing".
Timo Bingmann <tbns@idlebox.net>
parents:
5294
diff
changeset
|
433 |
NS_FATAL_ERROR ("Invalid WifiPhy state"); |
1c02054740eb
Renaming WifiPhy state SYNC to RX to avoid confusion with "synchronizing".
Timo Bingmann <tbns@idlebox.net>
parents:
5294
diff
changeset
|
434 |
return (os << "INVALID"); |
1c02054740eb
Renaming WifiPhy state SYNC to RX to avoid confusion with "synchronizing".
Timo Bingmann <tbns@idlebox.net>
parents:
5294
diff
changeset
|
435 |
} |
1c02054740eb
Renaming WifiPhy state SYNC to RX to avoid confusion with "synchronizing".
Timo Bingmann <tbns@idlebox.net>
parents:
5294
diff
changeset
|
436 |
} |
4470 | 437 |
|
1977
4303409f3d8e
remove uneeded trailing ';'
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
1974
diff
changeset
|
438 |
} // namespace ns3 |
4040
df2f5e1ea15b
ensure that all wifi modes are registered
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
4039
diff
changeset
|
439 |
|
df2f5e1ea15b
ensure that all wifi modes are registered
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
4039
diff
changeset
|
440 |
namespace { |
df2f5e1ea15b
ensure that all wifi modes are registered
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
4039
diff
changeset
|
441 |
|
df2f5e1ea15b
ensure that all wifi modes are registered
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
4039
diff
changeset
|
442 |
static class Constructor |
df2f5e1ea15b
ensure that all wifi modes are registered
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
4039
diff
changeset
|
443 |
{ |
df2f5e1ea15b
ensure that all wifi modes are registered
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
4039
diff
changeset
|
444 |
public: |
df2f5e1ea15b
ensure that all wifi modes are registered
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
4039
diff
changeset
|
445 |
Constructor () { |
df2f5e1ea15b
ensure that all wifi modes are registered
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
4039
diff
changeset
|
446 |
ns3::WifiPhy::Get6mba (); |
df2f5e1ea15b
ensure that all wifi modes are registered
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
4039
diff
changeset
|
447 |
ns3::WifiPhy::Get9mba (); |
df2f5e1ea15b
ensure that all wifi modes are registered
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
4039
diff
changeset
|
448 |
ns3::WifiPhy::Get12mba (); |
df2f5e1ea15b
ensure that all wifi modes are registered
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
4039
diff
changeset
|
449 |
ns3::WifiPhy::Get18mba (); |
df2f5e1ea15b
ensure that all wifi modes are registered
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
4039
diff
changeset
|
450 |
ns3::WifiPhy::Get24mba (); |
df2f5e1ea15b
ensure that all wifi modes are registered
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
4039
diff
changeset
|
451 |
ns3::WifiPhy::Get36mba (); |
df2f5e1ea15b
ensure that all wifi modes are registered
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
4039
diff
changeset
|
452 |
ns3::WifiPhy::Get48mba (); |
df2f5e1ea15b
ensure that all wifi modes are registered
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
4039
diff
changeset
|
453 |
ns3::WifiPhy::Get54mba (); |
4470 | 454 |
ns3::WifiPhy::Get1mbb (); |
455 |
ns3::WifiPhy::Get2mbb (); |
|
456 |
ns3::WifiPhy::Get5_5mbb (); |
|
457 |
ns3::WifiPhy::Get11mbb (); |
|
4680
a52c39181dd4
Support for 5 and 10Mhz wifi channels
Ramon Bauza <monbauza@gmail.com>
parents:
4492
diff
changeset
|
458 |
ns3::WifiPhy::Get3mb10Mhz (); |
a52c39181dd4
Support for 5 and 10Mhz wifi channels
Ramon Bauza <monbauza@gmail.com>
parents:
4492
diff
changeset
|
459 |
ns3::WifiPhy::Get4_5mb10Mhz (); |
a52c39181dd4
Support for 5 and 10Mhz wifi channels
Ramon Bauza <monbauza@gmail.com>
parents:
4492
diff
changeset
|
460 |
ns3::WifiPhy::Get6mb10Mhz (); |
a52c39181dd4
Support for 5 and 10Mhz wifi channels
Ramon Bauza <monbauza@gmail.com>
parents:
4492
diff
changeset
|
461 |
ns3::WifiPhy::Get9mb10Mhz (); |
a52c39181dd4
Support for 5 and 10Mhz wifi channels
Ramon Bauza <monbauza@gmail.com>
parents:
4492
diff
changeset
|
462 |
ns3::WifiPhy::Get12mb10Mhz (); |
a52c39181dd4
Support for 5 and 10Mhz wifi channels
Ramon Bauza <monbauza@gmail.com>
parents:
4492
diff
changeset
|
463 |
ns3::WifiPhy::Get18mb10Mhz (); |
a52c39181dd4
Support for 5 and 10Mhz wifi channels
Ramon Bauza <monbauza@gmail.com>
parents:
4492
diff
changeset
|
464 |
ns3::WifiPhy::Get24mb10Mhz (); |
a52c39181dd4
Support for 5 and 10Mhz wifi channels
Ramon Bauza <monbauza@gmail.com>
parents:
4492
diff
changeset
|
465 |
ns3::WifiPhy::Get27mb10Mhz (); |
a52c39181dd4
Support for 5 and 10Mhz wifi channels
Ramon Bauza <monbauza@gmail.com>
parents:
4492
diff
changeset
|
466 |
ns3::WifiPhy::Get1_5mb5Mhz (); |
a52c39181dd4
Support for 5 and 10Mhz wifi channels
Ramon Bauza <monbauza@gmail.com>
parents:
4492
diff
changeset
|
467 |
ns3::WifiPhy::Get2_25mb5Mhz (); |
a52c39181dd4
Support for 5 and 10Mhz wifi channels
Ramon Bauza <monbauza@gmail.com>
parents:
4492
diff
changeset
|
468 |
ns3::WifiPhy::Get3mb5Mhz (); |
a52c39181dd4
Support for 5 and 10Mhz wifi channels
Ramon Bauza <monbauza@gmail.com>
parents:
4492
diff
changeset
|
469 |
ns3::WifiPhy::Get4_5mb5Mhz (); |
a52c39181dd4
Support for 5 and 10Mhz wifi channels
Ramon Bauza <monbauza@gmail.com>
parents:
4492
diff
changeset
|
470 |
ns3::WifiPhy::Get6mb5Mhz (); |
a52c39181dd4
Support for 5 and 10Mhz wifi channels
Ramon Bauza <monbauza@gmail.com>
parents:
4492
diff
changeset
|
471 |
ns3::WifiPhy::Get9mb5Mhz (); |
a52c39181dd4
Support for 5 and 10Mhz wifi channels
Ramon Bauza <monbauza@gmail.com>
parents:
4492
diff
changeset
|
472 |
ns3::WifiPhy::Get12mb5Mhz (); |
a52c39181dd4
Support for 5 and 10Mhz wifi channels
Ramon Bauza <monbauza@gmail.com>
parents:
4492
diff
changeset
|
473 |
ns3::WifiPhy::Get13_5mb5Mhz (); |
4040
df2f5e1ea15b
ensure that all wifi modes are registered
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
4039
diff
changeset
|
474 |
} |
df2f5e1ea15b
ensure that all wifi modes are registered
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
4039
diff
changeset
|
475 |
} g_constructor; |
df2f5e1ea15b
ensure that all wifi modes are registered
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
4039
diff
changeset
|
476 |
} |