141 var tokens = result.split(
'\n');
143 var date1 =
new Date();
145 if (tokens[0].length!=13)
148 strike(
"time",
date0.getTime()+60000>date1.getTime());
153 var date2 =
new Date();
154 date2.setTime(tokens[0]);
156 strike(
"time", date2.getTime()+60000>date1.getTime());
160 gray(
"drive", tokens[drive]);
161 gray(
"temp", tokens[temp]);
162 gray(
"volt", tokens[voltmed]);
163 gray(
"current", tokens[curmed]);
165 document.getElementById(
"time").innerHTML =
166 "· "+date0.toUTCString()+
" ·";
168 document.getElementById(
"system").innerHTML =
171 if (
valid(tokens[drive])) document.getElementById(
"drive").innerHTML =
172 tokens[drive]+
" ["+tokens[zd]+
" "+tokens[az]+
"]";
174 if (
valid(tokens[temp]))
176 document.getElementById(
"temp").innerHTML =
177 tokens[
temp]+
"°C ["+tokens[dew]+
"°C]";
178 document.getElementById(
"aux").innerHTML =
179 tokens[gusts]+
" km/h";
181 document.getElementById(
"temp_row").style.background=
"#fff8f0";
182 if (parseFloat(tokens[temp])-parseFloat(tokens[dew])>0.3)
183 document.getElementById(
"temp_row").style.background=
"#fffff0";
184 if (parseFloat(tokens[temp])-parseFloat(tokens[dew])>0.7)
185 document.getElementById(
"temp_row").style.background=
"#f0fff0";
187 document.getElementById(
"aux_row").style.background=
"#fff8f0";
188 if (parseFloat(tokens[gusts])<50)
189 document.getElementById(
"aux_row").style.background=
"#fffff0";
190 if (parseFloat(tokens[gusts])<35)
191 document.getElementById(
"aux_row").style.background=
"#f0fff0";
195 document.getElementById(
"temp_row").style.background=
"#ffffff";
196 document.getElementById(
"aux_row").style.background=
"#ffffff";
200 if (
valid(tokens[voltmed]))
202 document.getElementById(
"bias").innerHTML =
203 tokens[curmed]+
"µA / "+tokens[curmax]+
"µA"+
204 " ["+tokens[voltmed]+
"V]";
206 if (parseFloat(tokens[voltmed])>1)
207 document.getElementById(
"bias_row").style.background=
"#f0f0f0";
209 document.getElementById(
"bias_row").style.background=
"#fff0f0";
213 document.getElementById(
"bias_row").style.background=
"#ffffff";
216 document.getElementById(
"localtime").innerHTML =
"· "+date1.toLocaleString()+
" ·";
function strike(id, status)
po::typed_value< T > * var(T *ptr=0)