Aktuellen Stand von Dooris übernommen.

This commit is contained in:
Jamalaka 2014-12-09 21:39:21 +01:00
parent 4a28a8debd
commit ce8a61b8a1
3 changed files with 38 additions and 37 deletions

View file

@ -1,17 +1,20 @@
#!/bin/sh #!/bin/sh
echo "Initializing Door Systems..." echo "Initializing Door Systems..."
echo "2" > /sys/class/gpio/unexport echo "17" > /sys/class/gpio/unexport
echo "2" > /sys/class/gpio/export echo "17" > /sys/class/gpio/export
sleep 0.5 sleep 0.5
echo "Securing Communication to Door Systems..." echo "Securing Communication to Door Systems..."
echo "out" > /sys/class/gpio/gpio2/direction echo "out" > /sys/class/gpio/gpio17/direction
sleep 0.5 sleep 0.5
echo "Open Communication Channel..." echo "Open Communication Channel..."
curl dooris.gnomus.de/dooropen sleep 0.5
echo "Opening Door..." echo "Opening Door..."
echo "1" > /sys/class/gpio/gpio2/value echo "1" > /sys/class/gpio/gpio17/value
sleep 1 sleep 1
echo "Welcome" echo "Welcome"
echo "0" > /sys/class/gpio/gpio2/value echo "0" > /sys/class/gpio/gpio17/value
sleep 3
echo "1" > /sys/class/gpio/gpio17/value
sleep 1
echo "0" > /sys/class/gpio/gpio17/value

29
lock
View file

@ -1,17 +1,16 @@
#!/bin/sh #!/bin/sh
#echo "Initializing Door Systems..." echo "Initializing Space Systems..."
#echo "2" > /sys/class/gpio/unexport echo "22" > /sys/class/gpio/unexport
#echo "2" > /sys/class/gpio/export echo "22" > /sys/class/gpio/export
#sleep 0.5 sleep 0.5
#echo "Securing Communication to Door Systems..." echo "Securing Communication to Space Systems..."
#echo "out" > /sys/class/gpio/gpio2/direction echo "out" > /sys/class/gpio/gpio22/direction
#sleep 0.5 sleep 0.5
#echo "Open Communication Channel..." echo "Open Communication Channel..."
curl dooris.gnomus.de/lock curl -s -o /dev/null "hamburg.ccc.de/dooris/status.php?apikey=sesamaenderdich&action=close"
#echo "Opening Door..." echo "Locking Space..."
#echo "1" > /sys/class/gpio/gpio2/value echo "1" > /sys/class/gpio/gpio22/value
#sleep 1 sleep 0.3
#echo "Welcome" echo "Bye!"
#echo "0" > /sys/class/gpio/gpio2/value echo "0" > /sys/class/gpio/gpio22/value

29
unlock
View file

@ -1,17 +1,16 @@
#!/bin/sh #!/bin/sh
#echo "Initializing Door Systems..." echo "Initializing Space Systems..."
#echo "2" > /sys/class/gpio/unexport echo "27" > /sys/class/gpio/unexport
#echo "2" > /sys/class/gpio/export echo "27" > /sys/class/gpio/export
#sleep 0.5 sleep 0.5
#echo "Securing Communication to Door Systems..." echo "Securing Communication to Space Systems..."
#echo "out" > /sys/class/gpio/gpio2/direction echo "out" > /sys/class/gpio/gpio27/direction
#sleep 0.5 sleep 0.5
#echo "Open Communication Channel..." echo "Open Communication Channel..."
curl dooris.gnomus.de/unlock curl -s -o /dev/null "hamburg.ccc.de/dooris/status.php?apikey=sesamaenderdich&action=open"
#echo "Opening Door..." echo "Unlocking Space..."
#echo "1" > /sys/class/gpio/gpio2/value echo "1" > /sys/class/gpio/gpio27/value
#sleep 1 sleep 0.3
#echo "Welcome" echo "Welcome"
#echo "0" > /sys/class/gpio/gpio2/value echo "0" > /sys/class/gpio/gpio27/value