* luci/applications: add experimental realtime statistics
[project/luci.git] / applications / luci-livestats / luasrc / view / livestats / wireless.htm
1 <%+header%>
2
3 <!--[if IE]><script type="text/javascript" src="<%=resource%>/livestats/ExCanvas.js"></script><![endif]-->
4 <script type="text/javascript" src="<%=resource%>/livestats/MochiKit.js"></script>
5 <script type="text/javascript" src="<%=resource%>/livestats/JsonRpc.js"></script>
6 <script type="text/javascript" src="<%=resource%>/livestats/PlotKit.js"></script>
7 <script type="text/javascript" src="<%=resource%>/livestats/GraphRPC.js"></script>
8
9 <script type="text/javascript">
10         function initGraphs() {
11                 var rpc = new GraphRPC(
12                         document.getElementById('live_graphs'),
13                         '<%=luci.dispatcher.build_url('rpc', 'sys')%>', 'wifi.getiwconfig',
14                         1500,
15
16                         // Data sources
17                         [ "Noise level", null, "Signal level", null ],
18
19                         // Graph layout options
20                         { yAxis: [ 0, 150 ], title: 'Wifi Interface "%s": Signal and Noise',
21                           padding: { left: 40, right: 10, top: 10, bottom: 20 } }
22                 );
23         }
24
25         MochiKit.DOM.addLoadEvent(initGraphs);
26 </script>
27
28 <div id="live_graphs"></div>
29
30 <%+footer%>