X-Git-Url: https://git.realraum.at/?a=blobdiff_plain;ds=inline;f=powersensordaemon%2Fswitch.cgi;h=533058df1105e51fdf6b0f8e61f54b32ecc96483;hb=cb3568f6daeeb35b6bf7effec71715780946b117;hp=58147d91927e7ba8c5aa41b89971fd3cf27155b0;hpb=5f37c9ae4672a2eac20127b8b24fbd96695cf5ec;p=svn42.git diff --git a/powersensordaemon/switch.cgi b/powersensordaemon/switch.cgi index 58147d9..533058d 100755 --- a/powersensordaemon/switch.cgi +++ b/powersensordaemon/switch.cgi @@ -20,9 +20,9 @@ for QUERY in `echo $QUERY_STRING | tr '&' ' '`; do done UNIXSOCK=/var/run/powersensordaemon/cmd.sock -VALID_ONOFF_IDS="decke ambientlights lichter all werkzeug labor dart logo idee deckehinten deckevorne" -VALID_SEND_IDS="ymhpoweron ymhpoweroff ymhpower ymhvolup ymhvoldown ymhcd ymhwdtv ymhtuner ymhvolmute ymhmenu ymhplus ymhminus ymhtest ymhtimelevel ymheffect ymhprgup ymhprgdown ymhtunplus ymhtunabcde ymhtape ymhvcr ymhextdec" - +VALID_ONOFF_IDS="decke ambientlights lichter all werkzeug labor dart logo spots1 deckehinten deckevorne boiler" +VALID_SEND_IDS="ymhpoweron ymhpoweroff ymhpower ymhvolup ymhvoldown ymhcd ymhwdtv ymhtuner ymhaux ymhsattv ymhvolmute ymhmenu ymhplus ymhminus ymhtest ymhtimelevel ymheffect ymhprgup ymhprgdown ymhtunplus ymhtunminus ymhtunabcde ymhtape ymhvcr ymhextdec ymhsleep ymhp5 panicled blueled moviemode" +VALID_BANSHEE_IDS="playPause next prev" [ "$POWER" == "send" ] && POWER=on if [ "$POWER" == "on" -o "$POWER" == "off" ]; then @@ -39,23 +39,38 @@ if [ "$POWER" == "on" -o "$POWER" == "off" ]; then exit 0 fi done + + for CHECKID in $VALID_BANSHEE_IDS; do + if [ "$CHECKID" == "$ID" ]; then + echo "$ID/" | nc wuerfel.realraum.at 8484 + echo "Content-type: text/html" + echo "" + echo "" + echo "
" + echo "