From 0d158423fcfabfc5f9d23aa2ece50d34d3f738d7 Mon Sep 17 00:00:00 2001 From: Bruno Date: Wed, 17 May 2023 10:44:09 +0200 Subject: [PATCH] =?UTF-8?q?Feat:=20Zm=C4=9Bny?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .DS_Store | Bin 0 -> 6148 bytes AP.yaml | 20 +++++++++ Frontend/src/lib/components/AddAp.svelte | 9 +++- Frontend/src/routes/+page.svelte | 10 ++--- Frontend/src/routes/about/+page.svelte | 6 +-- Frontend/src/routes/contact/+page.svelte | 8 +++- Frontend/src/routes/docs/+page.svelte | 20 ++++++--- Frontend/src/routes/settings/+page.svelte | 52 +++++++++++++++++----- Wifi Analyzer/.DS_Store | Bin 0 -> 6148 bytes Wifi Analyzer/platformio.ini | 1 - Wifi Analyzer/src/main.cpp | 6 +-- 11 files changed, 100 insertions(+), 32 deletions(-) create mode 100644 .DS_Store create mode 100644 AP.yaml create mode 100644 Wifi Analyzer/.DS_Store diff --git a/.DS_Store b/.DS_Store new file mode 100644 index 0000000000000000000000000000000000000000..c3a504bef5797e04a796ac915e345e4dc6bae448 GIT binary patch literal 6148 zcmeHKOHKko5Pgjp0b^w8vKL-}8w_MHF>yBwH!cA2mwHsQK!BUmO3XyfuB`HOVEV{7ABd&0d{@|vO zEqR+^8yV2UJ;4|`Pj2q~F7x3?60YuEd=e`7;WNzBv^U6mvUZ%c-@3K;=4!wGMt-B) zMmD`??WM!5aDa2%;hO5vWOiK)@Puc+V`F*4rry{)J6-QRpX<@XLocation: - +
+
Yaml:
+ +
+ diff --git a/Frontend/src/routes/+page.svelte b/Frontend/src/routes/+page.svelte index 509ee87..c216847 100644 --- a/Frontend/src/routes/+page.svelte +++ b/Frontend/src/routes/+page.svelte @@ -1,16 +1,16 @@
-
Dashboard
-
+
Dashboard
+
Access point amount :
{numberOfAccessPoints}
-
+
Access points up :
{numberOfAccessPointsUp}
diff --git a/Frontend/src/routes/about/+page.svelte b/Frontend/src/routes/about/+page.svelte index bde5c16..5762a02 100644 --- a/Frontend/src/routes/about/+page.svelte +++ b/Frontend/src/routes/about/+page.svelte @@ -1,10 +1,10 @@
-
About
-
+
About
+
This project was made by the Pátek team during the 2023 Junior AT&T Hackathon.
-
+
It’s an open-source management tool for access points with
diff --git a/Frontend/src/routes/contact/+page.svelte b/Frontend/src/routes/contact/+page.svelte index f2f53f9..489bc66 100644 --- a/Frontend/src/routes/contact/+page.svelte +++ b/Frontend/src/routes/contact/+page.svelte @@ -1,7 +1,11 @@
-
Contact
-
patek@gbl.cz
+
Contact
+
Email: patek@gbl.cz
+
Phone: +420 774 824 424
+
+ Address: Královická 668/23, 250 01 Brandýs nad Labem-Stará Boleslav +
diff --git a/Frontend/src/routes/docs/+page.svelte b/Frontend/src/routes/docs/+page.svelte index c58fec1..6b18a06 100644 --- a/Frontend/src/routes/docs/+page.svelte +++ b/Frontend/src/routes/docs/+page.svelte @@ -1,13 +1,19 @@
Docs
-
- dummy text dummy text dummy text dummy text dummy text dummy text dummy text dummy text dummy - text dummy text dummy text dummy text dummy text dummy text dummy text dummy text dummy text - dummy text dummy text dummy text dummy text dummy text dummy text dummy text dummy text dummy - text dummy text dummy text dummy text dummy text dummy text dummy text dummy text dummy text - dummy text dummy text dummy text dummy text dummy text dummy text dummy text dummy text dummy - text dummy text +
+ Project PWC2 is a comprehensive solution designed for the multivendor management of Access + Point (AP) devices. It aims to provide a centralized platform for efficiently managing APs + from various vendors, streamlining operations, and enhancing network performance. This + documentation serves as a guide for understanding and implementing the features and + functionalities of the PWC2 project. +
+
+ System Overview The PWC2 system consists of the following key components: Management Console: + The central user interface where administrators can configure, monitor, and manage AP devices. + AP Vendor Adapters: These are vendor-specific modules responsible for communicating with AP + devices, gathering information, and executing configuration commands. Database: Stores device + information, configurations, and operational data for efficient retrieval and analysis.
diff --git a/Frontend/src/routes/settings/+page.svelte b/Frontend/src/routes/settings/+page.svelte index 9c2d6a5..44f06c6 100644 --- a/Frontend/src/routes/settings/+page.svelte +++ b/Frontend/src/routes/settings/+page.svelte @@ -2,27 +2,59 @@ import AddAp from '$lib/components/AddAp.svelte'; import { onMount } from 'svelte'; - onMount(async () => { - const res = await fetch('http://10.10.1.4:8080/api/v1/aps'); - table = await res.json(); - console.log(table); - }); + function createAP() { + showAddApp = false; + //add to table new AP + table = [ + ...table, + { Name: 'Cisák', Type: 'Cisco', Location: 'Serverovna', ID: 0, IP: '172.27.69.70' } + ]; + } - var table = []; + var table = [ + { + Name: 'Mikrouš', + Type: 'Mikrotik', + Location: 'Recepce', + ID: 0, + IP: '172.27.69.66' + }, + { + Name: 'Turrísek', + Type: 'Turris', + Location: 'Kancelář', + ID: 0, + IP: '172.27.69.67' + }, + { + Name: 'T-Pod', + Type: 'TP-Link', + Location: 'Jídelna', + ID: 0, + IP: '172.27.69.68' + }, + { + Name: 'Asusáč', + Type: 'Asus', + Location: 'Zasedačka', + ID: 0, + IP: '172.27.69.69' + } + ]; let showAddApp = false; {#if showAddApp} - (showAddApp = false)} /> + (showAddApp = false)} on:create={() => createAP()} /> {/if}
-
Settings
- +
Settings
+
@@ -49,7 +81,7 @@
Add access point
diff --git a/Wifi Analyzer/.DS_Store b/Wifi Analyzer/.DS_Store new file mode 100644 index 0000000000000000000000000000000000000000..15cb9656e357f2fcfca4629da4d1f5ff442712ad GIT binary patch literal 6148 zcmeHLJx{|h5Iwgkl%h%10~S6o)7v3j9R{_}vZYh^92A)O&w-4qx2ZB#q;KlJ?=NH`njUu<>-_$A>@0r&rG2 z(9~PRE_hcorvarjq>;x?pPce7!>!@r)wx=Z7SKG<<+Bj{{!2YZct4^%VIsX z>tcpm&+OssIIqW>XOeE}*`DRqqxWN~qLMN7eO-bk>aY=)|Kl;|&!ZdOVziWRPBR+# ze6<73rz0-keS3Xt*IUJRh;i;Zi_sFkfEF~u*oDtn*#To7b2-&>zD6g$S!G$ggcs9` zK>?iEZ1sJE(u)G3fGChF!23gp#u!=54C<`|oxTD91Gu%}S)ZlAkR8CtVrCE?m@-3w zW~j1P3}uGHAKJXgVrI|`C#9J&k7ZW&hGI@~_(PpeDl#a&C?E>>3RKO<7N7s8+wcGW zAo(N;hywpg0Tsl(xQiv(v$e1|K5Ij?3p6&)%M9uv=7%j7iHSE9RL6T literal 0 HcmV?d00001 diff --git a/Wifi Analyzer/platformio.ini b/Wifi Analyzer/platformio.ini index e7da0eb..a3af69b 100644 --- a/Wifi Analyzer/platformio.ini +++ b/Wifi Analyzer/platformio.ini @@ -16,4 +16,3 @@ monitor_speed = 115200 lib_deps = WiFi ArduinoJson - WebSocketsClient diff --git a/Wifi Analyzer/src/main.cpp b/Wifi Analyzer/src/main.cpp index 0876f48..f230cf4 100644 --- a/Wifi Analyzer/src/main.cpp +++ b/Wifi Analyzer/src/main.cpp @@ -3,7 +3,7 @@ #include const int scanIterations = 5; -const int maxChannel = 14; // Maximum number of Wi-Fi channels in the 2.4 GHz band +const int maxChannel = 14; int channelUsage[maxChannel] = {0}; void setup() { @@ -31,14 +31,14 @@ void loop() { delay(1000); } - // Create a JSON object to store channel usage data + StaticJsonDocument<256> jsonDocument; JsonObject channelUsageJson = jsonDocument.to(); for (int channelIndex = 0; channelIndex < maxChannel; channelIndex++) { String channel = String(channelIndex + 1); channelUsageJson[channel] = channelUsage[channelIndex]; - channelUsage[channelIndex] = 0; // Reset channel usage counter for the next analysis + channelUsage[channelIndex] = 0; } // Serialize and print the JSON object
ID Name