Auto refreshing UI every 15secons.

This commit is contained in:
Blaz Kristan 2021-03-14 22:34:27 +01:00
parent 0f7e22d8b7
commit 07428922c3
3 changed files with 533 additions and 528 deletions

View File

@ -1011,10 +1011,12 @@ function cmpP(a, b) {
return a[1].n.localeCompare(b[1].n,undefined, {numeric: true});
}
var jsonTimeout;
var jsonTimeout, refreshTimer;
function requestJson(command, rinfo = true, verbose = true, callback = null) {
d.getElementById('connind').style.backgroundColor = "#a90";
lastUpdate = new Date();
if (refreshTimer) clearTimeout(refreshTimer);
refreshTimer = setTimeout(function(){requestJson({'v':true},false)},15000);
if (!jsonTimeout) jsonTimeout = setTimeout(showErrorToast, 3000);
var req = null;
var e1 = d.getElementById('fxlist');

File diff suppressed because it is too large Load Diff

View File

@ -8,7 +8,7 @@
*/
// version code in format yymmddb (b = daily build)
#define VERSION 2103130
#define VERSION 2103140
//uncomment this if you have a "my_config.h" file you'd like to use
//#define WLED_USE_MY_CONFIG