-
Notifications
You must be signed in to change notification settings - Fork 1
/
list.html
179 lines (156 loc) · 7.02 KB
/
list.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
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
<!DOCTYPE html><html><head><meta charset="utf-8"/><meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1"><title>Widget Engine</title>
<style>
body {
-ms-overflow-style: none;
height: 434px;
margin: 46px 0 0 0;
position:relative;
/*background-image: url("SMEGbackground.jpg");
background:#000000;
font-family: 'Gill Sans PSA', arial, sans-serif;
font-size: 14px;*/
background:#000000;
color:#FFFFFF;
}
a{
color:#FF0;
}
#infos {
position: absolute;
left: 100px;
top: 0;
width: 600px;
}
#infos .bloc {
float: left;
width: 136px;
height: 94px;
margin: 0 0 1px 1px;
border: 1px white solid;
padding: 18px 5px;
text-align: center;
border-radius: 10px;
margin: 0px 10px;
margin-bottom: 5px;
}
#infos .bloc .valeur {
font-size: 300%;
padding-top: 10px;
color: white;
}
#infos .bloc.small {
float: left;
width: 136px;
height: 45px;
margin: 0 0 1px 1px;
border: 1px white solid;
padding: 10px 5px;
text-align: center;
}
#infos .bloc.small .titre {
padding-bottom: 5px;
}
#infos .bloc.small .valeur {
font-size: 150%;
padding-top: 5px;
color: white;
display:inline;
}
#infos .bloc.small .unite {
font-size: 150%;
padding-left: 5px;
display:inline;
}
#infos .bloc.small.nav-button-container {
width: 34px;
height: 246px;
word-wrap: break-word;
}
.titre.button {
position: relative;
top: 35%;
}
#infos .listitem {
float: left;
width: 450px;
height: auto;
margin: 0 0 1px 1px;
border: 1px white solid;
padding: 18px 5px;
text-align: center;
margin: 0px 10px;
margin-bottom: 20px;
margin-left: 15px;
word-break: break-all;
}
</style>
</head>
<body>
<div style="position:absolute;left:18px;top:34px"><a href="index.html" onclick="document.body.style.marginTop='-1000px'"><img src="back.png" style="width:74px"/></a></div>
<div id="infos">
<div>
<div style="float: right; margin: 5px 20px 0 0" id="obd2-status"></div>
<h2 style="margin: 5px 0">SMEG PowerUp! v0.1</h2>
</div>
<br style="clear:both"/>
<div style="float: left; width:696px">
<div class="listitem"><div class="titre">User Agent<div id="userAgent" class="valeur"></div></div></div>
<div class="listitem"><div class="titre">VIN</div><div id="vin" class="valeur"></div></div>
<div class="listitem"><div class="titre">Driving State</div><div id="driving-state" class="valeur"></div></div>
<div class="listitem"><div class="titre">Fuel Type</div><div id="fuel-type" class="valeur"></div></div>
<div class="listitem"><div class="titre">Speed</div><div id="speed" class="valeur"></div></div>
<div class="listitem"><div class="titre">Mileage</div><div id="mileage" class="valeur"></div></div>
<div class="listitem"><div class="titre">Autonomy</div><div id="autonomy" class="valeur"></div></div>
<div class="listitem"><div class="titre">Offset UTC</div><div id="offset-utc" class="valeur"></div></div>
<div class="listitem"><div class="titre">Software Release</div><div id="software-release" class="valeur"></div></div>
<div class="listitem"><div class="titre">Hardware Release</div><div id="hardware-release" class="valeur"></div></div>
<div class="listitem"><div class="titre">Supplier Id</div><div id="supplier-id" class="valeur"></div></div>
<div class="listitem"><div class="titre">Map Version</div><div id="map-version" class="valeur"></div></div>
<div class="listitem"><div class="titre">Current Altitude</div><div id="altitude" class="valeur"></div></div>
<div class="listitem"><div class="titre">Current Latitude</div><div id="latitude" class="valeur"></div></div>
<div class="listitem"><div class="titre">Current Longitude</div><div id="longitude" class="valeur"></div></div>
<div class="listitem"><div class="titre">Current Street</div><div id="street" class="valeur"></div></div>
<div class="listitem"><div class="titre">Current Town</div><div id="town" class="valeur"></div></div>
<div class="listitem"><div class="titre">Current Country</div><div id="country" class="valeur"></div></div>
<div class="listitem"><div class="titre">TOP String:</div><div id="topString" class="valeur"></div></div>
<br style="clear:both"/>
</div>
<div>
</div>
</div>
</body>
<script>
(function(){
var D = document, P = /complete|loaded|interactive/,
onready = function(a) {
P.test(D.readyState) ? a() : D.addEventListener("DOMContentLoaded", function () {
a()
}, !1);
},
updateValues = function() {
document.getElementById("driving-state").innerHTML = top.GetCar.DrivingState();
document.getElementById("speed").innerHTML = top.GetCar.Speed();
document.getElementById("mileage").innerHTML = top.GetCar.Mileage();
document.getElementById("autonomy").innerHTML = top.GetCar.Autonomy();
document.getElementById("offset-utc").innerHTML = top.GetCar.OffsetUTC();
document.getElementById("altitude").innerHTML = top.GetCurrentPosition.Altitude();
document.getElementById("latitude").innerHTML = top.GetCurrentPosition.Latitude();
document.getElementById("longitude").innerHTML = top.GetCurrentPosition.Longitude();
document.getElementById("street").innerHTML = top.GetCurrentPosition.Street();
document.getElementById("town").innerHTML = top.GetCurrentPosition.Town();
document.getElementById("country").innerHTML = top.GetCurrentPosition.Country();
},
mainFunction = function() {
document.getElementById("userAgent").innerHTML = window.navigator.userAgent;
document.getElementById("vin").innerHTML = top.GetCar.VIN();
document.getElementById("fuel-type").innerHTML = top.GetCar.FuelType();
document.getElementById("software-release").innerHTML = top.GetDevice.SoftwareRelease();
document.getElementById("hardware-release").innerHTML = top.GetDevice.HardwareRelease();
document.getElementById("supplier-id").innerHTML = top.GetDevice.SupplierId();
document.getElementById("map-version").innerHTML = top.GetDevice.MapVersion();
setInterval(updateValues, 1000);
}
onready(mainFunction);
})();
</script>
</html>