avoid turning projector on when booting

install flask
master
pidor 2017-03-20 17:36:27 +01:00
parent fe4d415615
commit b7fabb2da6
2 changed files with 5 additions and 1 deletions

View File

@ -45,6 +45,7 @@ put discard (for fstrim) in fstab
reboot reboot
NO systemd:
put this in /etc/inittab (see example in systemfiles/inittab) put this in /etc/inittab (see example in systemfiles/inittab)
# pidor # pidor
P0:2345:respawn:/root/pidor/scripts/lockbutton.sh P0:2345:respawn:/root/pidor/scripts/lockbutton.sh
@ -53,6 +54,7 @@ P2:2345:respawn:/root/pidor/scripts/ws4beamer_status.py
P3:2345:respawn:/root/pidor/scripts/peoplecounter-realtime.sh P3:2345:respawn:/root/pidor/scripts/peoplecounter-realtime.sh
P4:2345:respawn:/root/pidor/scripts/caststatus.py P4:2345:respawn:/root/pidor/scripts/caststatus.py
WITH systemd
cd systemfiles/ cd systemfiles/
cp -p systemd/system/* /etc/systemd/system/ cp -p systemd/system/* /etc/systemd/system/
systemctl enable lockbutton.service beamerdetect.service ws4beamer_status.service peoplecounter-realtime.service caststatus.service systemctl enable lockbutton.service beamerdetect.service ws4beamer_status.service peoplecounter-realtime.service caststatus.service
@ -60,6 +62,8 @@ systemctl daemon-reload
systemctl start lockbutton.service beamerdetect.service ws4beamer_status.service peoplecounter-realtime.service caststatus.service systemctl start lockbutton.service beamerdetect.service ws4beamer_status.service peoplecounter-realtime.service caststatus.service
# get beamer status on port 5042
apt-get install python-flask
put the beamer IP into beamerip.txt put the beamer IP into beamerip.txt

View File

@ -79,7 +79,7 @@ do
# logger -t "$(basename $0) $$" "source=$signalsource cast=$(cat /var/run/caststatus)" # logger -t "$(basename $0) $$" "source=$signalsource cast=$(cat /var/run/caststatus)"
sleep 10 sleep 10
caststatus="$(cat /var/run/caststatus)" caststatus="$(cat /var/run/caststatus)"
if [ "$caststatus" != "Backdrop" ] && [ "$caststatus" != "None" ] && if [ "$caststatus" != "Backdrop" ] && [ "$caststatus" != "None" ] && [ "$caststatus" != "" ] &&
( [ "$signalsource" = "" ] || ( [ "$signalsource" = "" ] ||
[ "$signalsource" = "00" ] || [ "$signalsource" = "00" ] ||
[ "$signalsource" = "02" ] ) [ "$signalsource" = "02" ] )