fix: VE.Direct MPPT data not always updated in websocket
set the "last published" timestampt after handling *all* MPPTs.
This commit is contained in:
parent
811b64adb5
commit
91a0992964
@ -138,9 +138,10 @@ void WebApiWsVedirectLiveClass::generateJsonResponse(JsonVariant& root, bool ful
|
|||||||
const JsonObject &nested = array.createNestedObject(serial);
|
const JsonObject &nested = array.createNestedObject(serial);
|
||||||
nested["data_age_ms"] = VictronMppt.getDataAgeMillis(idx);
|
nested["data_age_ms"] = VictronMppt.getDataAgeMillis(idx);
|
||||||
populateJson(nested, spMpptData);
|
populateJson(nested, spMpptData);
|
||||||
_lastPublish = millis();
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
_lastPublish = millis();
|
||||||
|
|
||||||
// power limiter state
|
// power limiter state
|
||||||
root["dpl"]["PLSTATE"] = -1;
|
root["dpl"]["PLSTATE"] = -1;
|
||||||
if (Configuration.get().PowerLimiter.Enabled)
|
if (Configuration.get().PowerLimiter.Enabled)
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user