some optimations and bugfixes
This commit is contained in:
parent
94494bda8e
commit
61839d5e34
1 changed files with 2 additions and 7 deletions
|
@ -23,13 +23,6 @@ cmdonairstat=0
|
||||||
|
|
||||||
while true; do
|
while true; do
|
||||||
|
|
||||||
if [ "$cmdonairstat" -eq 1 ]; then
|
|
||||||
|
|
||||||
cmdonairstat=0
|
|
||||||
$(command -v pkill) "$pgrepplayer"
|
|
||||||
|
|
||||||
fi
|
|
||||||
|
|
||||||
buzzerstat="$($cmdgpio read $buzzgpio)"
|
buzzerstat="$($cmdgpio read $buzzgpio)"
|
||||||
swupstat="$($cmdgpio read $swupgpio)"
|
swupstat="$($cmdgpio read $swupgpio)"
|
||||||
|
|
||||||
|
@ -59,6 +52,8 @@ while true; do
|
||||||
done
|
done
|
||||||
|
|
||||||
echo "Off air!"
|
echo "Off air!"
|
||||||
|
cmdonairstat=0
|
||||||
|
$(command -v pkill) "$pgrepplayer"
|
||||||
|
|
||||||
elif [ "$buzzerstat" -eq 1 ] && [ "$swupstat" -eq 0 ]; then
|
elif [ "$buzzerstat" -eq 1 ] && [ "$swupstat" -eq 0 ]; then
|
||||||
sleep 0.1
|
sleep 0.1
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue