From 866af461ce6591574f0c6946693a60145dbbaefc Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?S=C3=A9bastien=20Deronne?= Date: Wed, 31 May 2023 21:54:34 +0200 Subject: [PATCH] wifi: Extend OBSS-PD for 802.11be --- src/wifi/test/inter-bss-test-suite.cc | 19 ++++++++++++++----- 1 file changed, 14 insertions(+), 5 deletions(-) diff --git a/src/wifi/test/inter-bss-test-suite.cc b/src/wifi/test/inter-bss-test-suite.cc index 7bb611a62..3dcc538ea 100644 --- a/src/wifi/test/inter-bss-test-suite.cc +++ b/src/wifi/test/inter-bss-test-suite.cc @@ -77,7 +77,12 @@ ConvertContextToNodeId(std::string context) class TestInterBssConstantObssPdAlgo : public TestCase { public: - TestInterBssConstantObssPdAlgo(); + /** + * Constructor + * + * \param standard The standard to use for the test + */ + TestInterBssConstantObssPdAlgo(WifiStandard standard); ~TestInterBssConstantObssPdAlgo() override; void DoRun() override; @@ -205,9 +210,11 @@ class TestInterBssConstantObssPdAlgo : public TestCase uint8_t m_bssColor1; ///< color for BSS 1 uint8_t m_bssColor2; ///< color for BSS 2 uint8_t m_bssColor3; ///< color for BSS 3 + + WifiStandard m_standard; ///< the standard to use for the test }; -TestInterBssConstantObssPdAlgo::TestInterBssConstantObssPdAlgo() +TestInterBssConstantObssPdAlgo::TestInterBssConstantObssPdAlgo(WifiStandard standard) : TestCase("InterBssConstantObssPd"), m_numSta1PacketsSent(0), m_numSta2PacketsSent(0), @@ -226,7 +233,8 @@ TestInterBssConstantObssPdAlgo::TestInterBssConstantObssPdAlgo() m_expectedTxPowerDbm(15), m_bssColor1(1), m_bssColor2(2), - m_bssColor3(3) + m_bssColor3(3), + m_standard(standard) { } @@ -850,7 +858,7 @@ TestInterBssConstantObssPdAlgo::RunOne() phy.Set("ChannelSettings", StringValue("{36, 20, BAND_5GHZ, 0}")); WifiHelper wifi; - wifi.SetStandard(WIFI_STANDARD_80211ax); + wifi.SetStandard(m_standard); wifi.SetRemoteStationManager("ns3::ConstantRateWifiManager", "DataMode", StringValue("HeMcs5"), @@ -991,7 +999,8 @@ class InterBssTestSuite : public TestSuite InterBssTestSuite::InterBssTestSuite() : TestSuite("wifi-inter-bss", UNIT) { - AddTestCase(new TestInterBssConstantObssPdAlgo, TestCase::QUICK); + AddTestCase(new TestInterBssConstantObssPdAlgo(WIFI_STANDARD_80211ax), TestCase::QUICK); + AddTestCase(new TestInterBssConstantObssPdAlgo(WIFI_STANDARD_80211be), TestCase::QUICK); } // Do not forget to allocate an instance of this TestSuite