more ir code stuff, still missing button 7
[svn42.git] / powersensordaemon / ymhremote.html
index c9423ad..afb1931 100755 (executable)
@@ -7,6 +7,7 @@ function sendButton( btn )
 {
   //alert(btn);
   document.getElementById('indicator').style.backgroundColor="red";
+  document.getElementById('commandlabel').innerHTML=btn;
   var req = new XMLHttpRequest();
   url = "http://slug.realraum.at/cgi-bin/switch.cgi?power=send&id="+btn;
   req.open("GET", url ,false);
@@ -16,6 +17,7 @@ function sendButton( btn )
   //response = req.responseText;
   //document.getElementById('output').innerHTML = response; 
   document.getElementById('indicator').style.backgroundColor="white";
+  document.getElementById('commandlabel').innerHTML=' ';
 }
 
 function remoteKeyboard( e )
@@ -37,9 +39,12 @@ function remoteKeyboard( e )
                case 83: sendButton( 'ymhsleep' ); break;               // S
                case 36: sendButton( 'ymhmute' ); break; //pos1        
                case 33: sendButton( 'ymhvolup' ); break;       // P = 80, PAGEUP = 33
+               case 43: sendButton( 'ymhvolup' ); break;       // +
                case 34: sendButton( 'ymhvoldown' ); break;     // N = 78, PAGEDOWN = 34
-               case 43: sendButton( 'ymhtunplus' ); break;     // +
-               case 65: sendButton( 'ymhtunabcde' ); break;    // A 
+               case 45: sendButton( 'ymhvoldown' ); break;     // -
+               case 46: sendButton( 'ymhtunplus' ); break;     // .
+               case 44: sendButton( 'ymhtunminus' ); break;    // ,
+               case 59: sendButton( 'ymhtunabcde' ); break;    // ; 
                case 69: sendButton( 'ymheffect' ); break;      // E
                case 80: sendButton( 'ymhpower' ); break;       // P
                case 48: sendButton( 'ymhtest' ); break;        // 0
@@ -47,9 +52,9 @@ function remoteKeyboard( e )
                case 50: sendButton( 'ymhtuner' ); break;       // 2
                case 51: sendButton( 'ymhtape' ); break;        // 3
                case 52: sendButton( 'ymhwdtv' ); break;        // 4
-               //case 53: sendButton( 'ymhsat' ); break;       // 5
+               case 53: sendButton( 'ymhsattv' ); break;       // 5
                case 54: sendButton( 'ymhvcr' ); break; // 6
-               //case 55: sendButton( '' ); break;     // 7
+               case 55: sendButton( 'ymh7' ); break;   // 7
                case 56: sendButton( 'ymhaux' ); break; // 8
                case 57: sendButton( 'ymhextdec' ); break;      // 9
        }
@@ -74,9 +79,9 @@ document.onkeydown = remoteKeyboard;
 <area shape ="circle" coords ="88,98,17" onClick="sendButton('ymhtuner');" alt="ymhtuner" />
 <area shape ="circle" coords ="142,98,17" onClick="sendButton('ymhtape');" alt="ymhtape" />
 <area shape ="circle" coords ="36,145,17" onClick="sendButton('ymhwdtv');" alt="ymhwdtv" />
-<!--area shape ="circle" coords ="88,145,17" onClick="sendButton('ymhsat);" alt="ymhsat" /-->
+<area shape ="circle" coords ="88,145,17" onClick="sendButton('ymhsattv');" alt="ymhsattv" />
 <area shape ="circle" coords ="142,145,17" onClick="sendButton('ymhvcr');" alt="ymhvcr" />
-<!--area shape ="circle" coords ="36,192,17" onClick="sendButton('ymh7);" alt="ymh7" /-->
+<area shape ="circle" coords ="36,192,17" onClick="sendButton('ymh7');" alt="ymh7" />
 <area shape ="circle" coords ="88,192,17" onClick="sendButton('ymhaux');" alt="ymhaux" />
 <area shape ="circle" coords ="142,192,17" onClick="sendButton('ymhextdec');" alt="ymhextdec" />
 <area shape ="circle" coords ="36,240,17" onClick="sendButton('ymhtest');" alt="ymhtest" />
@@ -90,9 +95,9 @@ document.onkeydown = remoteKeyboard;
 <area shape ="circle" coords ="89,377,16" onClick="sendButton('ymhmute');" alt="ymhmute" />
 
 <area shape ="circle" coords ="36,455,17" onClick="sendButton('ymhsleep');" alt="ymhsleep" />
-<!--area shape ="circle" coords ="142,455,17" onClick="sendButton('ymhdsp');" alt="ymhdsp" /-->
+<area shape ="circle" coords ="142,455,17" onClick="sendButton('ymhdsp');" alt="ymhp5" />
 
-<!--area shape ="rect" coords ="18,278,67,301" onClick="sendButton('ymhminus');"  /-->
+<area shape ="rect" coords ="18,278,67,301" onClick="sendButton('ymhtunminus');"  />
 <area shape ="rect" coords ="111,278,160,301" onClick="sendButton('ymhtunplus');"  />
 
 <area shape ="polygon" coords ="57,524,89,496,119,521,110,524,66,533" onClick="sendButton('ymhprgup');" alt="ymhprgup" />
@@ -104,4 +109,5 @@ document.onkeydown = remoteKeyboard;
 <area shape ="circle" coords ="142,634,17" onClick="sendButton('ymhmenu');" alt="ymhmenu" />
 <!-- href ="./cgi-bin/switch.cgi" target ="_blank" -->
 </map>
+<p id="commandlabel" style="display:hidden;">&nbsp;</p>
 </html>