/
sound.html
28 lines (25 loc) · 962 Bytes
/
sound.html
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
<html>
<head>
<meta http-equiv="refresh" content="2">
</head>
<body>
<script type="text/javascript" src="https://www.gstatic.com/charts/loader.js"></script>
<script type="text/javascript" src="http://127.0.0.1/level.js"></script>
<script type="text/javascript">
google.charts.load('current', {'packages':['gauge']});
google.charts.setOnLoadCallback(drawGauge);
var gaugeOptions = {min: 0, max: .03, yellowFrom: .007, yellowTo: .01,
redFrom: .01, redTo: .03, minorTicks: 5};
var gauge;
function drawGauge() {
gaugeData = new google.visualization.DataTable();
gaugeData.addColumn('number', 'Level');
gaugeData.addRows(2);
gaugeData.setCell(0, 0, int_level);
gauge = new google.visualization.Gauge(document.getElementById('gauge_div'));
gauge.draw(gaugeData, gaugeOptions);
}
</script>
<div id="gauge_div" style="width:400px; height: 200px;" align=center></div>
</body>
</html>