Skip to content
Open
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
38 changes: 38 additions & 0 deletions examples/wireless/lan80211/omnetpp-ht-greenfield.ini
Original file line number Diff line number Diff line change
@@ -0,0 +1,38 @@
[General]
network = Lan80211
abstract = true
cmdenv-express-mode = true

**.constraintAreaMinX = 0m
**.constraintAreaMinY = 0m
**.constraintAreaMinZ = 0m
**.constraintAreaMaxX = 600m
**.constraintAreaMaxY = 400m
**.constraintAreaMaxZ = 0m

**.arp.typename = "GlobalArp"
**.opMode = "n(greenfield-2.4Ghz)"
**.wlan[*].bitrate = 13Mbps
**.wlan[*].radio.transmitter.centerFrequency = 2.4GHz

*.ap.wlan[*].address = "10:00:00:00:00:00"
*.host[*].**.mgmt.accessPointAddress = "10:00:00:00:00:00"

*.ap.mobility.typename = "StationaryMobility"
*.ap.mobility.initialX = 250m
*.ap.mobility.initialY = 200m
*.host[*].mobility.typename = "StationaryMobility"
*.host[*].mobility.initialY = 200m
*.host[0].mobility.initialX = 260m
*.host[1].mobility.initialX = 270m

[Config HtGreenfield]
description = "HT Greenfield mode exchanging ping traffic through an access point"
sim-time-limit = 2s
*.numHosts = 2
*.host[0].numApps = 0
*.host[1].numApps = 1
*.host[1].app[0].typename = "PingApp"
*.host[1].app[0].destAddr = "host[0]"
*.host[1].app[0].sendInterval = 100ms
*.host[1].app[0].printPing = true
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ module ExtUpperIeee80211Interface extends ExtInterface like IWirelessInterface
{
parameters:
string energySourceModule = default("");
string opMode @enum("a","b","g(erp)","g(mixed)","n(mixed-2.4Ghz)","p","ac") = default("g(mixed)");
string opMode @enum("a","b","g(erp)","g(mixed)","n(mixed-2.4Ghz)","n(greenfield-2.4Ghz)","p","ac") = default("g(mixed)");
double bitrate @unit(bps) = default(-1bps);
**.opMode = this.opMode;
**.bitrate = this.bitrate;
Expand Down Expand Up @@ -92,4 +92,3 @@ module ExtUpperIeee80211Interface extends ExtInterface like IWirelessInterface

classifier.in <-- { @display("m=n"); } <-- tap.lowerLayerOut;
}

3 changes: 1 addition & 2 deletions src/inet/linklayer/ieee80211/Ieee80211Interface.ned
Original file line number Diff line number Diff line change
Expand Up @@ -63,7 +63,7 @@ module Ieee80211Interface extends NetworkInterface like IWirelessInterface
parameters:
string interfaceTableModule;
string energySourceModule = default("");
string opMode @enum("a","b","g(erp)","g(mixed)","n(mixed-2.4Ghz)","p","ac") = default("g(mixed)");
string opMode @enum("a","b","g(erp)","g(mixed)","n(mixed-2.4Ghz)","n(greenfield-2.4Ghz)","p","ac") = default("g(mixed)");
string address @mutable = default("auto"); // MAC address as hex string (12 hex digits), or
// "auto". "auto" values will be replaced by
// a generated MAC address in init stage 0.
Expand Down Expand Up @@ -129,4 +129,3 @@ module Ieee80211Interface extends NetworkInterface like IWirelessInterface

classifier.in <-- { @display("m=n"); } <-- upperLayerIn;
}

3 changes: 1 addition & 2 deletions src/inet/linklayer/ieee80211/mac/Ieee80211Mac.ned
Original file line number Diff line number Diff line change
Expand Up @@ -78,7 +78,7 @@ module Ieee80211Mac extends MacProtocolBase like IIeee80211Mac
{
parameters:
string mibModule;
string modeSet @enum("a","b","g(erp)","g(mixed)","n(mixed-2.4Ghz)","p","ac") = default("g(mixed)");
string modeSet @enum("a","b","g(erp)","g(mixed)","n(mixed-2.4Ghz)","n(greenfield-2.4Ghz)","p","ac") = default("g(mixed)");
string fcsMode @enum("declared","computed") = default("declared");
string initialRadioMode @enum("off","sleep","receiver","transmitter","transceiver") = default("receiver");

Expand Down Expand Up @@ -130,4 +130,3 @@ module Ieee80211Mac extends MacProtocolBase like IIeee80211Mac
@display("p=250,200");
}
}

Original file line number Diff line number Diff line change
Expand Up @@ -326,7 +326,7 @@ Ieee80211HtCompliantModes::~Ieee80211HtCompliantModes()
const Ieee80211HtMode *Ieee80211HtCompliantModes::getCompliantMode(const Ieee80211Htmcs *mcsMode, Ieee80211HtMode::BandMode centerFrequencyMode, Ieee80211HtPreambleMode::HighTroughputPreambleFormat preambleFormat, Ieee80211HtModeBase::GuardIntervalType guardIntervalType)
{
const char *name = ""; // TODO
auto htModeId = std::make_tuple(mcsMode->getBandwidth(), mcsMode->getMcsIndex(), guardIntervalType);
auto htModeId = std::make_tuple(mcsMode->getBandwidth(), mcsMode->getMcsIndex(), centerFrequencyMode, preambleFormat, guardIntervalType);
auto mode = singleton.modeCache.find(htModeId);
if (mode == singleton.modeCache.end()) {
const Ieee80211OfdmModulation *modulation = nullptr;
Expand All @@ -348,7 +348,7 @@ const Ieee80211HtMode *Ieee80211HtCompliantModes::getCompliantMode(const Ieee802
const Ieee80211HtDataMode *dataMode = new Ieee80211HtDataMode(mcsMode, mcsMode->getBandwidth(), guardIntervalType);
const Ieee80211HtPreambleMode *preambleMode = new Ieee80211HtPreambleMode(htSignal, legacySignal, preambleFormat, dataMode->getNumberOfSpatialStreams());
const Ieee80211HtMode *htMode = new Ieee80211HtMode(name, preambleMode, dataMode, centerFrequencyMode);
singleton.modeCache.insert(std::pair<std::tuple<Hz, unsigned int, Ieee80211HtModeBase::GuardIntervalType>, const Ieee80211HtMode *>(htModeId, htMode));
singleton.modeCache.emplace(htModeId, htMode);
return htMode;
}
return mode->second;
Expand Down Expand Up @@ -544,4 +544,3 @@ const DI<Ieee80211Htmcs> Ieee80211HtmcsTable::htMcs76BW40MHz([](){ return new Ie

} /* namespace physicallayer */
} /* namespace inet */

Original file line number Diff line number Diff line change
Expand Up @@ -460,7 +460,7 @@ class INET_API Ieee80211HtCompliantModes
protected:
static OPP_THREAD_LOCAL const Ieee80211HtCompliantModes singleton;

mutable std::map<std::tuple<Hz, unsigned int, Ieee80211HtModeBase::GuardIntervalType>, const Ieee80211HtMode *> modeCache;
mutable std::map<std::tuple<Hz, unsigned int, Ieee80211HtMode::BandMode, Ieee80211HtPreambleMode::HighTroughputPreambleFormat, Ieee80211HtModeBase::GuardIntervalType>, const Ieee80211HtMode *> modeCache;

public:
Ieee80211HtCompliantModes();
Expand All @@ -473,4 +473,3 @@ class INET_API Ieee80211HtCompliantModes
} /* namespace inet */

#endif

Loading