Update config reset all settings

beta-ft
Alan Johnston 1 year ago committed by GitHub
parent 2a16426a0a
commit efb2cf8fd0
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

@ -1367,14 +1367,36 @@ elif [ "$1" = "-L" ]; then
elif [ "$1" = "-g" ]; then
echo
echo "Resetting configration back to default settings"
echo "Are you sure you want to reset the CubeSatSim configration back to the default settings?"
echo
echo "AMSAT 0 0 0 no 3 434.9 435 no 0 0" > /home/pi/CubeSatSim/sim.cfg
read rset
echo
sudo echo "f" > /home/pi/CubeSatSim/.mode
if [ "$rset" = "y" ] || [ "$rset" = "yes" ] ; then
reboot=1
echo "Resetting"
echo "AMSAT 0 0 0 no 3 434.9 435 no 0 0" > /home/pi/CubeSatSim/sim.cfg
sudo echo "f" > /home/pi/CubeSatSim/.mode
sudo rm /home/pi/CubeSatSim/battery_saver
sudo rm /home/pi/CubeSatSim/command_control
sudo rm /home/pi/CubeSatSim/command_control_direwolf
sydi rm /home/pi/CubeSatSim/beacon_off
sudo echo "0" > /home/pi/CubeSatSim/command_count.txt
reboot=1
else
echo "Not resetting"
fi
elif [ "$1" = "-h" ]; then

Loading…
Cancel
Save

Powered by TurnKey Linux.