|
|
|
|
@ -710,7 +710,7 @@ elif [ "$1" = "-C" ]; then
|
|
|
|
|
echo
|
|
|
|
|
|
|
|
|
|
sudo systemctl stop cubesatsim
|
|
|
|
|
sudo systemctl stop rpitx
|
|
|
|
|
sudo systemctl stop transmit
|
|
|
|
|
sudo systemctl stop command
|
|
|
|
|
|
|
|
|
|
sudo mv -f /home/pi/CubeSatSim/telem.txt /home/pi/CubeSatSim/telem.txt.bk
|
|
|
|
|
@ -993,7 +993,7 @@ elif [ "$1" = "-q" ]; then
|
|
|
|
|
|
|
|
|
|
# reboot=1
|
|
|
|
|
## sudo reboot now
|
|
|
|
|
sudo systemctl restart rpitx
|
|
|
|
|
sudo systemctl restart transmit
|
|
|
|
|
|
|
|
|
|
elif [ "$1" = "-Q" ]; then
|
|
|
|
|
|
|
|
|
|
@ -1131,7 +1131,7 @@ elif [ "$1" = "-F" ]; then
|
|
|
|
|
## echo
|
|
|
|
|
# reboot=1
|
|
|
|
|
## sudo reboot now
|
|
|
|
|
sudo systemctl restart rpitx
|
|
|
|
|
sudo systemctl restart transmit
|
|
|
|
|
# fi
|
|
|
|
|
|
|
|
|
|
elif [ "$1" = "-o" ]; then
|
|
|
|
|
@ -1162,9 +1162,7 @@ elif [ "$1" = "-o" ]; then
|
|
|
|
|
if [ "$reset" = "y" ] || [ "$reset" = "yes" ] ; then
|
|
|
|
|
echo "Turn beacon telemetry ON"
|
|
|
|
|
sudo rm /home/pi/CubeSatSim/beacon_off > /dev/null 2>&1
|
|
|
|
|
sudo systemctl restart rpitx
|
|
|
|
|
# sudo python3 -u /home/pi/CubeSatSim/rpitx.py s & > /dev/null 2>&1
|
|
|
|
|
|
|
|
|
|
sudo systemctl restart transmit
|
|
|
|
|
# restart=1
|
|
|
|
|
fi
|
|
|
|
|
|
|
|
|
|
@ -1179,7 +1177,7 @@ elif [ "$1" = "-o" ]; then
|
|
|
|
|
if [ "$reset" = "y" ] || [ "$reset" = "yes" ] ; then
|
|
|
|
|
echo "Turn beacon telemetry OFF"
|
|
|
|
|
touch /home/pi/CubeSatSim/beacon_off
|
|
|
|
|
sudo systemctl restart rpitx
|
|
|
|
|
sudo systemctl restart transmit
|
|
|
|
|
# restart=1
|
|
|
|
|
fi
|
|
|
|
|
fi
|
|
|
|
|
@ -1284,10 +1282,10 @@ elif [ "$1" = "-A" ]; then
|
|
|
|
|
if [ "$1" != "n" ]; then
|
|
|
|
|
|
|
|
|
|
sudo systemctl stop cubesatsim
|
|
|
|
|
sudo systemctl stop rpitx
|
|
|
|
|
sudo systemctl stop transmit
|
|
|
|
|
# sudo rm /home/pi/CubeSatSim/t.txt > /dev/null 2>&1
|
|
|
|
|
|
|
|
|
|
sudo python3 -u /home/pi/CubeSatSim/rpitx.py x > /dev/null 2>&1 & # Force APRS mode
|
|
|
|
|
sudo python3 -u /home/pi/CubeSatSim/transmit.py x > /dev/null 2>&1 & # Force APRS mode
|
|
|
|
|
fi
|
|
|
|
|
|
|
|
|
|
sim="y"
|
|
|
|
|
@ -1391,7 +1389,7 @@ elif [ "$1" = "-g" ]; then
|
|
|
|
|
sudo echo "0" > /home/pi/CubeSatSim/command_count.txt
|
|
|
|
|
|
|
|
|
|
sudo systemctl stop cubesatsim
|
|
|
|
|
sudo systemctl stop rpitx
|
|
|
|
|
sudo systemctl stop transmit
|
|
|
|
|
sudo systemctl stop command
|
|
|
|
|
|
|
|
|
|
sudo mv -f /home/pi/CubeSatSim/telem.txt /home/pi/CubeSatSim/telem.txt.bk
|
|
|
|
|
@ -1466,7 +1464,7 @@ if [ "$reboot" = "1" ] ; then
|
|
|
|
|
if [ "$noreboot" = "0" ] ; then
|
|
|
|
|
echo 'Reboot due to config change!' | wall
|
|
|
|
|
echo "Rebooting"
|
|
|
|
|
sudo systemctl stop rpitx
|
|
|
|
|
sudo systemctl stop transmit
|
|
|
|
|
sudo reboot now
|
|
|
|
|
else
|
|
|
|
|
echo "Reboot needed for changes to take effect"
|
|
|
|
|
@ -1476,9 +1474,9 @@ fi
|
|
|
|
|
if [ "$restart" = "1" ] ; then
|
|
|
|
|
if [ "$reboot" = "0" ] ; then
|
|
|
|
|
echo "Restarting"
|
|
|
|
|
# sudo systemctl stop rpitx
|
|
|
|
|
# sudo systemctl stop transmit
|
|
|
|
|
sudo systemctl restart cubesatsim
|
|
|
|
|
sudo systemctl restart rpitx
|
|
|
|
|
sudo systemctl restart transmit
|
|
|
|
|
else
|
|
|
|
|
echo "Restart needed for changes to take effect"
|
|
|
|
|
fi
|
|
|
|
|
|