|
|
|
@ -176,9 +176,7 @@ if [ "$1" = "" ]; then
|
|
|
|
FILE=/home/pi/CubeSatSim/sim_mode_auto
|
|
|
|
FILE=/home/pi/CubeSatSim/sim_mode_auto
|
|
|
|
if [ -f "$FILE" ]; then
|
|
|
|
if [ -f "$FILE" ]; then
|
|
|
|
echo "Simulated Telemetry is automatically turned ON"
|
|
|
|
echo "Simulated Telemetry is automatically turned ON"
|
|
|
|
else
|
|
|
|
elif [[ $(timeout 2 i2cdetect -y 1 | grep -e "43" -e "44") ]]; then
|
|
|
|
|
|
|
|
|
|
|
|
if [[ $(timeout 2 i2cdetect -y 1 | grep -e "43" -e "44") ]]; then
|
|
|
|
|
|
|
|
# Check the exit code of the last command
|
|
|
|
# Check the exit code of the last command
|
|
|
|
if [ $? -ne 0 ]; then
|
|
|
|
if [ $? -ne 0 ]; then
|
|
|
|
echo "Command failed!"
|
|
|
|
echo "Command failed!"
|
|
|
|
|