wfb-ng/scripts/tx_standalone.sh

40 lines
670 B
Bash
Raw Normal View History

2017-04-07 11:38:41 -03:00
#!/bin/bash
WLAN=$1
BAND="5G"
#BAND="2G"
CHANNEL2G="6"
2017-04-07 11:38:41 -03:00
CHANNEL5G="149"
ifconfig $WLAN down
iw dev $WLAN set monitor otherbss
iw reg set BO
2017-04-07 11:38:41 -03:00
ifconfig $WLAN up
case $BAND in
"5G")
echo "Setting $WLAN to channel $CHANNEL5G"
iw dev $WLAN set bitrates ht-mcs-5 1 sgi-5
iw dev $WLAN set channel $CHANNEL5G HT40+
;;
"2G")
echo "Setting $WLAN to channel $CHANNEL2G"
iw dev $WLAN set bitrates ht-mcs-2.4 1 sgi-2.4
iw dev $WLAN set channel $CHANNEL2G HT40+
;;
*)
echo "Select 2G or 5G band"
exit -1;
;;
esac
2017-04-07 11:38:41 -03:00
# Video TX
./tx -p 1 -u 5600 $WLAN &
# Mavlink TX
./tx -m 100 -p 2 -u 14550 $WLAN &
wait -n