From 697c2ec086cdd0ddb1fe226935ffbc221f808f82 Mon Sep 17 00:00:00 2001 From: stephb9959 Date: Thu, 4 Aug 2022 14:32:49 -0700 Subject: [PATCH] https://telecominfraproject.atlassian.net/browse/WIFI-10435 Signed-off-by: stephb9959 --- build | 2 +- src/uCentralClient.cpp | 24 ++---------------------- 2 files changed, 3 insertions(+), 23 deletions(-) diff --git a/build b/build index bf0d87a..7813681 100644 --- a/build +++ b/build @@ -1 +1 @@ -4 \ No newline at end of file +5 \ No newline at end of file diff --git a/src/uCentralClient.cpp b/src/uCentralClient.cpp index 8846348..afd3b6f 100644 --- a/src/uCentralClient.cpp +++ b/src/uCentralClient.cpp @@ -278,14 +278,11 @@ namespace OpenWifi { nlohmann::json uCentralClient::CreateState() { nlohmann::json S; - std::cout << __LINE__ << std::endl; // set the version S["version"] = 1; - std::cout << __LINE__ << std::endl; // set the unit stuff auto now = OpenWifi::Now(); - std::cout << __LINE__ << std::endl; S["unit"]["load"] = std::vector{ (double)(MicroService::instance().Random(75)) /100.0 , (double)(MicroService::instance().Random(50))/100.0 , (double)(MicroService::instance().Random(25))/100.0 }; S["unit"]["localtime"] = now; S["unit"]["uptime"] = now - StartTime_; @@ -294,7 +291,6 @@ namespace OpenWifi { S["unit"]["memory"]["cached"] = 29233152; S["unit"]["memory"]["free"] = 760164352; - std::cout << __LINE__ << std::endl; // get all the radios out for(auto &[_,radio]:AllRadios_) { radio.next(); @@ -310,15 +306,11 @@ namespace OpenWifi { nlohmann::json current_interface; nlohmann::json up_ssids; uint64_t ssid_num = 0, interfaces = 0; - std::cout << __LINE__ << std::endl; for (auto &[interface, associations]: AllAssociations_) { auto &[interface_type, ssid, band] = interface; - std::cout << __LINE__ << std::endl; if (interface_type == ap_interface_type) { - std::cout << __LINE__ << std::endl; nlohmann::json association_list; std::string bssid; - std::cout << __LINE__ << std::endl; for (auto &association: associations) { association.next(); bssid = association.bssid; @@ -337,39 +329,27 @@ namespace OpenWifi { up_ssids.push_back(ssid_info); } } - std::cout << __LINE__ << std::endl; current_interface["ssids"] = up_ssids; - std::cout << __LINE__ << std::endl; AllCounters_[ap_interface_type].next(); - std::cout << __LINE__ << std::endl; current_interface["counters"] = AllCounters_[ap_interface_type].to_json(); - std::cout << __LINE__ << std::endl; // if we have 2 interfaces, then the clients go to the downstream interface // if we only have 1 interface then this is bridged and therefore clients go on the upstream - std::cout << __LINE__ << std::endl; if( (AllCounters_.size()==1 && ap_interface_type==ap_interface_types::upstream) || (AllCounters_.size()==2 && ap_interface_type==ap_interface_types::downstream)) { - std::cout << __LINE__ << std::endl; nlohmann::json state_lan_clients; - std::cout << __LINE__ << std::endl; for (const auto &lan_client: AllLanClients_) { - std::cout << __LINE__ << std::endl; state_lan_clients.push_back(lan_client.to_json()); } current_interface["clients"] = state_lan_clients; } current_interface["name"] = AllInterfaceNames_[ap_interface_type]; - std::cout << __LINE__ << std::endl; all_interfaces.push_back(current_interface); } - std::cout << __LINE__ << std::endl; } - std::cout << __LINE__ << std::endl; S["interfaces"] = all_interfaces; - std::cout << __LINE__ << std::endl << std::endl << std::endl; - std::cout << S << std::endl; - std::cout << std::endl << std::endl << std::endl; +// std::cout << S << std::endl; +// std::cout << std::endl << std::endl << std::endl; return S; }