From 13dcbb6dcaac9d1e0d716efcfd8557beeaf5789f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?S=C3=A9bastien=20Deronne?= Date: Tue, 15 May 2018 21:28:34 +0200 Subject: [PATCH] examples: Fix Visual Studio compilation errors --- examples/wireless/power-adaptation-distance.cc | 2 +- examples/wireless/power-adaptation-interference.cc | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/examples/wireless/power-adaptation-distance.cc b/examples/wireless/power-adaptation-distance.cc index 7c18d929c..ca059268b 100644 --- a/examples/wireless/power-adaptation-distance.cc +++ b/examples/wireless/power-adaptation-distance.cc @@ -359,7 +359,7 @@ int main (int argc, char *argv[]) wifiStaDevices.Add (wifi.Install (wifiPhy, wifiMac, wifiStaNodes.Get (0))); //Configure the AP node - wifi.SetRemoteStationManager (manager, "DefaultTxPowerLevel", UintegerValue (maxPower), "RtsCtsThreshold", UintegerValue (rtsThreshold)); + wifi.SetRemoteStationManager (manager, "DefaultTxPowerLevel", UintegerValue (powerLevels - 1), "RtsCtsThreshold", UintegerValue (rtsThreshold)); wifiPhy.Set ("TxPowerStart", DoubleValue (minPower)); wifiPhy.Set ("TxPowerEnd", DoubleValue (maxPower)); wifiPhy.Set ("TxPowerLevels", UintegerValue (powerLevels)); diff --git a/examples/wireless/power-adaptation-interference.cc b/examples/wireless/power-adaptation-interference.cc index e769d9f16..9510ac5ae 100644 --- a/examples/wireless/power-adaptation-interference.cc +++ b/examples/wireless/power-adaptation-interference.cc @@ -410,7 +410,7 @@ int main (int argc, char *argv[]) wifiStaDevices.Add (wifi.Install (wifiPhy, wifiMac, wifiStaNodes.Get (1))); //Configure the AP nodes - wifi.SetRemoteStationManager (manager, "DefaultTxPowerLevel", UintegerValue (maxPower), "RtsCtsThreshold", UintegerValue (rtsThreshold)); + wifi.SetRemoteStationManager (manager, "DefaultTxPowerLevel", UintegerValue (powerLevels - 1), "RtsCtsThreshold", UintegerValue (rtsThreshold)); wifiPhy.Set ("TxPowerStart", DoubleValue (minPower)); wifiPhy.Set ("TxPowerEnd", DoubleValue (maxPower)); wifiPhy.Set ("TxPowerLevels", UintegerValue (powerLevels));