diff --git a/Web App/web/src/i18n/da.json b/Web App/web/src/i18n/da.json index 53b7750..151791a 100644 --- a/Web App/web/src/i18n/da.json +++ b/Web App/web/src/i18n/da.json @@ -136,6 +136,8 @@ "lineToLine": "Mellem faser", "power": "Samlet effekt", "sessionDuration": "Sessionens længde", + "chargingStatus": "Ladestatus", + "sessionEnergy": "Sessionsenergi", "cpSignal": "Control pilot", "cpVoltage": "Pilotspænding", "phaseMode": "Kører på", diff --git a/Web App/web/src/i18n/en.json b/Web App/web/src/i18n/en.json index dde8d20..37addc0 100644 --- a/Web App/web/src/i18n/en.json +++ b/Web App/web/src/i18n/en.json @@ -122,6 +122,8 @@ "lineToLine": "Line to line", "power": "Total power", "sessionDuration": "Session length", + "chargingStatus": "Charging status", + "sessionEnergy": "Session energy", "cpSignal": "Control pilot", "cpVoltage": "Pilot voltage", "phaseMode": "Running on", diff --git a/Web App/web/src/i18n/pl.json b/Web App/web/src/i18n/pl.json index 04712b9..1141d63 100644 --- a/Web App/web/src/i18n/pl.json +++ b/Web App/web/src/i18n/pl.json @@ -138,6 +138,8 @@ "lineToLine": "Międzyfazowe", "power": "Moc całkowita", "sessionDuration": "Czas sesji", + "chargingStatus": "Status ładowania", + "sessionEnergy": "Energia sesji", "cpSignal": "Control pilot", "cpVoltage": "Napięcie pilota", "phaseMode": "Pracuje na", diff --git a/Web App/web/src/views/Charging.vue b/Web App/web/src/views/Charging.vue index 928a123..876ddb8 100644 --- a/Web App/web/src/views/Charging.vue +++ b/Web App/web/src/views/Charging.vue @@ -342,6 +342,14 @@ function sessionLength(sec) { return h > 0 ? `${h} h ${m} min` : `${m} min`; } +// What the car is drawing and how long it has been, beside the buttons that +// start and stop it — the two numbers you look at to see whether pressing one +// did anything. Both are Modbus registers; the OCPP status carries neither, so +// there the tiles are absent rather than empty, which is also what happens on a +// charger whose firmware does not report them. +const ctlPower = computed(() => unit(mb.value.powerTotal, 0, "W")); +const ctlSessionTime = computed(() => sessionLength(mb.value.sessionSeconds)); + // Pairs with no value drop out: a charger on older firmware, or one that refused // the control block, should show a shorter list rather than a column of dashes. const rows = (pairs) => @@ -350,8 +358,14 @@ const rows = (pairs) => const modbusLive = computed(() => { const s = mb.value; return rows([ + // What the charger says it is doing, and the session's own energy. Both are + // registers of their own, and both were readable only from the tiles in the + // control card — a readout that leaves out the two numbers the page puts in + // front of you is not the full readout it claims to be. + ["chargingStatus", s.statusDesc], ["power", unit(s.powerTotal, 0, "W")], ["sessionDuration", sessionLength(s.sessionSeconds)], + ["sessionEnergy", isSet(s.sessionWh) ? `${(s.sessionWh / 1000).toFixed(2)} kWh` : null], ["cpSignal", s.cpSignalDesc], ["cpVoltage", unit(s.cpVoltage, 2, "V")], ["phaseMode", enumLabel("phaseMode", s.phaseMode)], @@ -1065,6 +1079,14 @@ onMounted(async () => {