From 30f33430e8d785a1aed4a686dbd2d92c8e928d50 Mon Sep 17 00:00:00 2001 From: viktorxda <35473052+viktorxda@users.noreply.github.com> Date: Fri, 31 Jan 2025 14:31:22 +0100 Subject: [PATCH] wifibroadcast-ng: minor page update --- .../wifibroadcast-ng/files/wifibroadcast | 14 ++--- .../package/wifibroadcast-ng/www/index.html | 59 ++++++++++++------- .../package/wifibroadcast-ng/www/stream.svg | 2 +- 3 files changed, 45 insertions(+), 30 deletions(-) diff --git a/general/package/wifibroadcast-ng/files/wifibroadcast b/general/package/wifibroadcast-ng/files/wifibroadcast index 95392ca5..d9212cdc 100755 --- a/general/package/wifibroadcast-ng/files/wifibroadcast +++ b/general/package/wifibroadcast-ng/files/wifibroadcast @@ -4,7 +4,7 @@ wfb_dev=wlan0 wfb_yaml() { if [ -e "$1" ]; then - while IFS=": " read -r key value; do + while IFS=: read -r key value; do value=$(eval echo $value) export "$key=$value" done < "$1" @@ -59,9 +59,9 @@ load_interface() { iw reg set 00 if [ "$driver" = "88XXau" ]; then - iw "$wfb_dev" set txpower fixed $((txpower * -100)) + iw "$wfb_dev" set txpower fixed "$((txpower * -100))" else - iw "$wfb_dev" set txpower fixed $((txpower * 50)) + iw "$wfb_dev" set txpower fixed "$((txpower * 50))" fi case "$mode" in @@ -135,11 +135,9 @@ start() { } stop() { - killall -q wfb_rx - killall -q wfb_tx - killall -q wfb_tun - killall -q msposd - killall -q mavfwd + for process in wfb_rx wfb_tx wfb_tun msposd mavfwd; do + killall -q "$process" + done } case "$1" in diff --git a/general/package/wifibroadcast-ng/www/index.html b/general/package/wifibroadcast-ng/www/index.html index 820af70b..c2a7a998 100644 --- a/general/package/wifibroadcast-ng/www/index.html +++ b/general/package/wifibroadcast-ng/www/index.html @@ -16,7 +16,7 @@ header { background-color: #252526; color: white; - padding: 20px 0; + padding: 15px 0; } h3 { font-size: 1.5rem; @@ -29,7 +29,7 @@ .form-section { background-color: #2d2d2d; border-radius: 8px; - box-shadow: 0 2px 10px rgba(0, 0, 0, 0.5); + box-shadow: 0 2px 10px #00000080; max-width: 40%; padding: 20px; margin: 20px auto; @@ -55,6 +55,7 @@ } .form-section button { background-color: #0d6efd80; + box-shadow: 0 2px 10px #00000040; color: white; padding: 10px 60px; border: none; @@ -65,10 +66,12 @@ .form-section button:hover { background-color: #0b5ed7; } - #camera-preview { - max-width: 60%; + #preview { + width: 100%; + max-width: 1200px; + aspect-ratio: 16/9; border-radius: 8px; - box-shadow: 0 2px 10px rgba(0, 0, 0, 0.5); + box-shadow: 0 2px 10px #00000080; } .row { margin-bottom: 15px; @@ -78,12 +81,12 @@