1a21b41ecea9e8ab4186d4f25ed754e9b7a10b9b
[apps/agl-service-unicens.git] / htdocs / UNICENS.html
1 <html>
2 <head>
3     <title>Unicens Simple Test</title>
4
5     <link rel="stylesheet" href="Ucs2Binding.css">
6     <script type="text/javascript" src="AFB-websock.js"></script>
7     <script type="text/javascript" src="Ucs2Binding.js"></script>
8
9 <body onload="init('ucs2_config','unicens', 'listconfig');">
10     <h1>Unicens Simple Test</h1>
11     
12     <button id="connected" onclick="init('ucs2_config','unicens', 'listconfig')">Binder WS Fail</button>
13     <br><br>
14     <b>Selected HAL </b>
15     <select id='ucs2_config'></select>
16     <br>
17     
18     <ol>
19     <li><button onclick="callbinder('UNICENS','initialise', {filename:ucs2_config})">Parse XML and Start UNICENS</button></li>
20     <li><button onclick="callbinder('UNICENS','volume', {channel:'master', volume: 255})">Set Master Volume to 255</button></li>
21     <li><button onclick="callbinder('unicens','volume', {channel:'master', volume: 230})">Set Master Volume to 230</button></li>
22     <li><button onclick="callbinder('unicens','volume', {channel:'master', volume: 215})">Set Master Volume to 215</button></li>
23     <li><button onclick="callbinder('unicens','volume', {channel:'master', volume: 200})">Set Master Volume to 200</button></li>
24     <li><button onclick="callbinder('unicens','volume', {channel:'master', volume: 185})">Set Master Volume to 185</button></li>
25     <li><button onclick="callbinder('unicens','volume', {channel:'master', volume: 0})">Set Master Volume to 0</button></li>
26     </ol>
27     <br>
28     <ol>
29     <li><button onclick="callbinder('UNICENS','volume', [[0,200], [1,255]])">Set left=200 right=250</button></li>
30     <li><button onclick="callbinder('UNICENS','volume', [[0,255], [1,200]])">Set right=250 left=200</button></li>
31     <li><button onclick="callbinder('UNICENS','volume', [[0,255], [1,255]])">Set right=255 left=255</button></li>
32     </ol>
33     <br>
34     <ol>
35     <li><button onclick="callbinder('UNICENS','write_i2c', {node_address: 0x270, i2c_data:[0x07,0x03,0xFF]})">Write I2C to 0x270 (mute)</button></li>
36     <li><button onclick="callbinder('UNICENS','write_i2c', {node_address: 0x271, i2c_data:[0x07,0x03,0xFF]})">Write I2C to 0x271 (mute)</button></li>
37     <li><button onclick="callbinder('UNICENS','write_i2c', {node_address: 0x272, i2c_data:[0x07,0x03,0xFF]})">Write I2C to 0x272 (mute)</button></li>
38     </ol>
39     <br>
40     <br>
41     <div id="main" style="visibility:hidden">
42     <ol>
43     <li>Question <pre id="question"></pre>
44     <li>Response <pre id="output"></pre>
45     <li>Events: <pre id="outevt"></pre>
46     </ol>
47     </div>