add projection screen up/down script
parent
cb5a29d91f
commit
9e57c15fbe
|
@ -70,6 +70,10 @@ sudo sed -i 's/#\(watchdog-device\)/\1/
|
||||||
|
|
||||||
sudo service watchdog start
|
sudo service watchdog start
|
||||||
|
|
||||||
|
Note: projectionscreen.sh is a standalone program called remotely by pidor
|
||||||
|
because pidor knows the IP adress of the projector but doorbuzz has the RF remote connected.
|
||||||
|
The remote command works with ssh, so install pidor's root pub key into
|
||||||
|
~pi/.ssh/authorized_keys
|
||||||
todo
|
todo
|
||||||
====
|
====
|
||||||
create a config file
|
create a config file
|
||||||
|
|
|
@ -0,0 +1,31 @@
|
||||||
|
STOPBUTTON=8
|
||||||
|
UPBUTTON=7
|
||||||
|
DOWNBUTTON=23
|
||||||
|
gpio -g mode $STOPBUTTON out
|
||||||
|
gpio -g mode $UPBUTTON out
|
||||||
|
gpio -g mode $DOWNBUTTON out
|
||||||
|
function rollstop() {
|
||||||
|
gpio -g write $STOPBUTTON 1
|
||||||
|
sleep 0.2
|
||||||
|
gpio -g write $STOPBUTTON 0
|
||||||
|
}
|
||||||
|
function rollup() {
|
||||||
|
gpio -g write $UPBUTTON 1
|
||||||
|
sleep 0.2
|
||||||
|
gpio -g write $UPBUTTON 0
|
||||||
|
}
|
||||||
|
function rolldown() {
|
||||||
|
gpio -g write $DOWNBUTTON 1
|
||||||
|
sleep 0.2
|
||||||
|
gpio -g write $DOWNBUTTON 0
|
||||||
|
}
|
||||||
|
|
||||||
|
logger "$0 action $1"
|
||||||
|
case "$1" in
|
||||||
|
up) rollup
|
||||||
|
;;
|
||||||
|
down) rolldown
|
||||||
|
;;
|
||||||
|
stop) rollstop
|
||||||
|
;;
|
||||||
|
esac
|
Loading…
Reference in New Issue