Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update and rename pifox.sh to bspifox.sh #3

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
28 changes: 14 additions & 14 deletions pifox/pifox.sh → pifox/bspifox.sh
Original file line number Diff line number Diff line change
Expand Up @@ -300,7 +300,7 @@ fi
Time=$(date +"%R %p")
Seconds=$(date +"%S")
Day=$(date +"%F")
GPIO22=$(gpio -g read 22)
# GPIO22=$(gpio -g read 22)

if [[ "$foxtimeset" == 1 ]]; then
echo "${callsign} ${foxmessage} at ${Time}" >> fox.txt
Expand All @@ -312,14 +312,14 @@ if [[ "$foxtimeset" == 0 ]]; then
echo "${callsign}>BEACON:${foxmessage}" >> fox_pkt.txt
fi

if [ $GPIO22 == 0 ]; then
#chech the GPIO22 as input for signals or alarms, and modify the following text as you wish
echo " . Input 22 active!!!" >> fox.txt
echo ". Input 22 active!!!" >> fox_pkt.txt
fi
# if [ $GPIO22 == 0 ]; then
# #chech the GPIO22 as input for signals or alarms, and modify the following text as you wish
# echo " . Input 22 active!!!" >> fox.txt
# echo ". Input 22 active!!!" >> fox_pkt.txt
# fi

echo "${Day};${Time}:${Seconds};${callsign};${foxmessage};${GPIO22};" >> Logger.txt
cat fox.txt
# echo "${Day};${Time}:${Seconds};${callsign};${foxmessage};${GPIO22};" >> Logger.txt
# cat fox.txt

#the following line is to generate the voice audio file

Expand All @@ -329,11 +329,11 @@ fi

#the following line is to generate the packet radio audio file

if [[ "$foxpacket" == 1 ]]; then
./pkt2wave fox_pkt.txt -n 1 -r 44100 -o fox_pkt.wav
fi
#if [[ "$foxpacket" == 1 ]]; then
# ./pkt2wave fox_pkt.txt -n 1 -r 44100 -o fox_pkt.wav
#fi

gpio -g write 17 1
#gpio -g write 17 1


if [[ "$Vox" == 1 ]]; then
Expand All @@ -360,7 +360,7 @@ fi

fi

gpio -g write 17 0
#gpio -g write 17 0
rm -f fox.txt
rm -f fox_pkt.txt

Expand All @@ -379,4 +379,4 @@ done

echo ""
echo "End of transmissions."
exit
exit