[no ci] Wifibroadcast: minor formatting

pull/1407/head
Viktor 2024-04-17 15:27:32 +02:00
parent 4acbf74200
commit f8dc871eeb
1 changed files with 7 additions and 11 deletions

View File

@ -30,10 +30,6 @@ set_mcs() {
fi fi
} }
# "0bda:8813" -> (8814) -> 8814au
# "0846:9052" -> (8811) -> 8821au
# "0bda:a81a" -> 88x2eu
detect_wifi_card() { detect_wifi_card() {
devices=$(lsusb | cut -d ' ' -f6 | sort | uniq) devices=$(lsusb | cut -d ' ' -f6 | sort | uniq)
for card in $devices; do for card in $devices; do
@ -74,7 +70,7 @@ detect_wifi_card() {
exit 1 exit 1
fi fi
sleep 0.5 sleep 0.5
n=$(expr $n + 1) n=$((n + 1))
done done
} }
@ -87,10 +83,10 @@ load_interface() {
if [ "$driver" = "realtek" ]; then if [ "$driver" = "realtek" ]; then
ifconfig "$wlan" up ifconfig "$wlan" up
iwconfig "$wlan" mode monitor iwconfig "$wlan" mode monitor
elif [ ${driver} = "realtek_8812eu" ]; then elif [ "$driver" = "realtek_8812eu" ]; then
ifconfig ${wlan} up ifconfig "$wlan" up
iwconfig ${wlan} mode monitor iwconfig "$wlan" mode monitor
iw dev ${wlan} set txpower fixed $(expr ${driver_txpower_override} * 50) iw dev "$wlan" set txpower fixed $((driver_txpower_override * 50))
elif [ "$driver" = "atheros" ]; then elif [ "$driver" = "atheros" ]; then
iwconfig "$wlan" mode monitor iwconfig "$wlan" mode monitor
ifconfig "$wlan" up ifconfig "$wlan" up
@ -131,7 +127,7 @@ case "$1" in
fi fi
echo "Starting Wifibroadcast service..." echo "Starting Wifibroadcast service..."
start_"$unit"_wfb start_${unit}_wfb
if [ "$telemetry" = "true" ]; then if [ "$telemetry" = "true" ]; then
if [ "$chip" = "gk7205v200" ]; then if [ "$chip" = "gk7205v200" ]; then