homebridge-viessmann-vicare 2.0.26 → 2.0.28

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/README.md CHANGED
@@ -203,6 +203,10 @@ Starting from v2.0.25 the plugin automatically records historical data at every
203
203
  | Burner starts + hours (lifetime) | Boiler | CSV, HTML report |
204
204
  | Outside temperature | Boiler | CSV, HTML report |
205
205
  | Outside humidity (if sensor present) | Boiler | CSV, HTML report |
206
+ | PV production (W) + daily yield (kWh) | Energy | CSV, HTML report |
207
+ | Battery level (%) + charge/discharge (W) | Energy | CSV, HTML report |
208
+ | Grid feed-in / draw (W) | Energy | CSV, HTML report |
209
+ | Wallbox charging state + power (W) | Energy | CSV, HTML report |
206
210
 
207
211
  ---
208
212
 
@@ -938,6 +942,28 @@ For issues and questions:
938
942
  - 🔧 `scheduleStateRefresh()` replaced by `scheduleCommandConfirmation()` in all three accessories.
939
943
  - 🔧 Applied uniformly to `dhw-accessory`, `boiler-accessory`, and `heating-circuit-accessory`.
940
944
 
945
+ ### [2.0.28] - 2026-03-10
946
+ #### Added
947
+ - **Flow temperature logging** — `heating.circuits.N.sensors.temperature.supply` now read and logged to CSV as `flow_temp` column from HC0 accessory
948
+ - **Real gas consumption logging** — `heating.gas.consumption.summary.heating/dhw.currentDay` (m³) logged as `gas_heating_day_m3` / `gas_dhw_day_m3` columns from boiler accessory
949
+ - **Heat demand estimation** — avg modulation × `nominalPowerKw` config param (default 24 kW) shown in report as stat card
950
+ - **Condensing efficiency badge** — percentage of time flow temp < 55°C displayed in HC0 section with Good/Borderline/Not condensing badge
951
+ - **Burner cycle analysis** — ON/OFF edges reconstructed from CSV; stat cards: cycle count, avg duration, shortest cycle with ⚠ badge if < 5 min
952
+ - **Cycle duration histogram** — bar chart in report (5 buckets: 0–5, 5–10, 10–20, 20–40, 40+ min) shown when ≥ 3 cycles in period
953
+ - **Flow temp chart** — dedicated chart in HC0 section with 55°C condensing threshold line
954
+ - **Flow temp in overview chart** — added as dashed red series on left temperature axis
955
+ - **`nominalPowerKw` config param** — optional, default 24 kW, for heat demand estimation
956
+
957
+ #### CSV header (v2.0.28)
958
+ `timestamp,accessory,burner_active,modulation,room_temp,target_temp,outside_temp,outside_humidity,dhw_temp,dhw_target,program,mode,burner_starts,burner_hours,flow_temp,gas_heating_day_m3,gas_dhw_day_m3,pv_production_w,pv_daily_kwh,battery_level,battery_charging_w,battery_discharging_w,grid_feedin_w,grid_draw_w,wallbox_charging,wallbox_power_w`
959
+
960
+ ### [2.0.27] - 2026-03-10
961
+ **Added**
962
+ - ⚡ **Energy accessory** (`src/accessories/energy-accessory.ts`): new accessory supporting PV/solar production (Vitocharge VX3 / Vitovolt 300), battery storage, wallbox/EV charger, and electric DHW heater. Capabilities are auto-detected from API features — the accessory is silently skipped if none are present. HomeKit mapping: PV → Lightbulb (brightness = production %), Battery → Battery service + Lightbulb for power, Wallbox → Switch (enable/disable) + Outlet (plugged-in status), Electric DHW → HeaterCooler.
963
+ - ⚡ **Energy CSV logging**: energy accessory logs PV production (W), daily yield (kWh), battery level (%), charging/discharging power (W), grid feed-in/draw (W), wallbox charging state and power (W) to `viessmann-history.csv` every refresh cycle.
964
+ - 📊 **HTML report — Energy section**: new *Energy System* section in the report with stat cards and Chart.js graphs for PV production, battery level + charge/discharge, and wallbox power. Sections are shown only when data is present.
965
+ - 📊 **CSV columns added**: `pv_production_w`, `pv_daily_kwh`, `battery_level`, `battery_charging_w`, `battery_discharging_w`, `grid_feedin_w`, `grid_draw_w`, `wallbox_charging`, `wallbox_power_w` appended after existing columns. Backward compatible — empty for non-energy rows.
966
+
941
967
  ### [2.0.26] - 2026-03-10
942
968
  **Added**
943
969
  - 🌐 **HTML report — Overview chart**: new all-in-one chart at the top of the report with dual Y axis combining room temperature, HC0 setpoint, DHW temperature, outside temperature, modulation (%), burner ON/OFF, and outside humidity (when sensor is present). Series from different accessories are aligned on a unified timeline using linear interpolation for continuous, gap-free lines.
@@ -1 +1 @@
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O,CAAC,yBAAyB;IAoBjC,OAAO,CAAC,wBAAwB;IAoEhC,OAAO,CAAC,kBAAkB;IAwD1B,OAAO,CAAC,sBAAsB;IAyE9B,OAAO,CAAC,uBAAuB;IAmO/B,OAAO,CAAC,gCAAgC;IAqCxC,OAAO,CAAC,2BAA2B;IAInC,OAAO,CAAC,iBAAiB;IAIzB,OAAO,CAAC,mBAAmB;IAI3B,OAAO,CAAC,gBAAgB;IAIlB,qBAAqB,IAAI,OAAO,CAAC,mBAAmB,CAAC;IAIrD,8BAA8B,IAAI,OAAO,CAAC,mBAAmB,CAAC;IAI9D,8BAA8B,CAAC,KAAK,EAAE,mBAAmB;IA8C/D,OAAO,CAAC,2BAA2B;YAiDrB,YAAY;YAYZ,kBAAkB;IA6VzB,oBAAoB,IAAI;QAC7B,WAAW,EAAE,MAAM,CAAC;QACpB,YAAY,EAAE,MAAM,CAAC;QACrB,aAAa,EAAE,MAAM,CAAC;QACtB,UAAU,EAAE,MAAM,GAAG,MAAM,GAAG,SAAS,CAAC;QACxC,mBAAmB,EAAE,MAAM,CAAC;QAC5B,sBAAsB,EAAE,MAAM,CAAC;QAC/B,qBAAqB,EAAE,MAAM,CAAC;QAC9B,wBAAwB,EAAE,MAAM,CAAC;QACjC,kBAAkB,EAAE,MAAM,CAAC;QAC3B,aAAa,EAAE,MAAM,CAAC;QACtB,YAAY,EAAE,MAAM,CAAC;KACtB;CAsBF"}
@@ -43,6 +43,7 @@ class ViessmannBoilerAccessory {
43
43
  GasConsumptionToday: 0,
44
44
  GasConsumptionThisMonth: 0,
45
45
  GasConsumptionThisYear: 0,
46
+ GasConsumptionDhwToday: 0, // heating.gas.consumption.summary.dhw.currentDay
46
47
  PowerConsumptionToday: 0,
47
48
  PowerConsumptionThisMonth: 0,
48
49
  PowerConsumptionThisYear: 0,
@@ -748,6 +749,11 @@ class ViessmannBoilerAccessory {
748
749
  this.states.GasConsumptionThisYear = gasConsumptionFeature.properties.currentYear.value;
749
750
  }
750
751
  }
752
+ // Update DHW gas consumption
753
+ const gasDhwFeature = features.find(f => f.feature === 'heating.gas.consumption.summary.dhw');
754
+ if (gasDhwFeature?.properties?.currentDay?.value !== undefined) {
755
+ this.states.GasConsumptionDhwToday = gasDhwFeature.properties.currentDay.value;
756
+ }
751
757
  // Update gas consumption occupancy sensor
752
758
  if (gasDataUpdated && this.gasConsumptionService) {
753
759
  const hasActiveConsumption = this.states.GasConsumptionToday > 0.1;
@@ -904,6 +910,8 @@ class ViessmannBoilerAccessory {
904
910
  outside_humidity: this.states.OutsideHumidity,
905
911
  burner_starts: this.states.BurnerStarts,
906
912
  burner_hours: this.states.BurnerHours,
913
+ gas_heating_day_m3: this.states.GasConsumptionToday || undefined,
914
+ gas_dhw_day_m3: this.states.GasConsumptionDhwToday || undefined,
907
915
  });
908
916
  }
909
917
  }
@@ -0,0 +1,53 @@
1
+ import { PlatformAccessory } from 'homebridge';
2
+ import { ViessmannPlatform, ViessmannInstallation, ViessmannGateway, ViessmannDevice } from '../platform';
3
+ /**
4
+ * ViessmannEnergyAccessory
5
+ *
6
+ * Handles energy-related Viessmann devices:
7
+ * - Vitocharge VX3 / photovoltaic system (heating.solar / heating.photovoltaic)
8
+ * - Battery storage (heating.buffer / heating.powerStorage)
9
+ * - Wallbox / EV charger (charging.ev.*)
10
+ * - Electric DHW heater (heating.dhw.heating.*)
11
+ *
12
+ * HomeKit mapping:
13
+ * - PV production → Lightbulb (Brightness = watts %)
14
+ * - Battery level → Battery service
15
+ * - Grid feed-in → Switch (read-only via Eve-like sensor)
16
+ * - Wallbox charging → Switch (on/off) + Outlet
17
+ * - Electric DHW → HeaterCooler
18
+ */
19
+ export declare class ViessmannEnergyAccessory {
20
+ private readonly platform;
21
+ private readonly accessory;
22
+ private readonly installation;
23
+ private readonly gateway;
24
+ private readonly device;
25
+ private historyLogger?;
26
+ private informationService;
27
+ private pvProductionService?;
28
+ private pvStatusService?;
29
+ private batteryService?;
30
+ private batteryPowerService?;
31
+ private wallboxService?;
32
+ private wallboxOutletService?;
33
+ private electricDHWService?;
34
+ private hasPV;
35
+ private hasBattery;
36
+ private hasWallbox;
37
+ private hasElectricDHW;
38
+ private states;
39
+ constructor(platform: ViessmannPlatform, accessory: PlatformAccessory, installation: ViessmannInstallation, gateway: ViessmannGateway, device: ViessmannDevice);
40
+ private initializeCapabilities;
41
+ private detectCapabilities;
42
+ private setupServices;
43
+ private setupPVServices;
44
+ private setupBatteryServices;
45
+ private setupWallboxServices;
46
+ private setupElectricDHWService;
47
+ handleUpdate(): Promise<void>;
48
+ private updateFromFeatures;
49
+ private setWallboxCharging;
50
+ private setElectricDHWActive;
51
+ private setElectricDHWTemperature;
52
+ }
53
+ //# sourceMappingURL=energy-accessory.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"energy-accessory.d.ts","sourceRoot":"","sources":["../../src/accessories/energy-accessory.ts"],"names":[],"mappings":"AAAA,OAAO,EAAW,iBAAiB,EAAuB,MAAM,YAAY,CAAC;AAC7E,OAAO,EACL,iBAAiB,EACjB,qBAAqB,EACrB,gBAAgB,EAChB,eAAe,EAChB,MAAM,aAAa,CAAC;AAGrB;;;;;;;;;;;;;;;GAeG;AACH,qBAAa,wBAAwB;IA8DjC,OAAO,CAAC,QAAQ,CAAC,QAAQ;IACzB,OAAO,CAAC,QAAQ,CAAC,SAAS;IAC1B,OAAO,CAAC,QAAQ,CAAC,YAAY;IAC7B,OAAO,CAAC,QAAQ,CAAC,OAAO;IACxB,OAAO,CAAC,QAAQ,CAAC,MAAM;IA/DzB,OAAO,CAAC,aAAa,CAAC,CAAyB;IAG/C,OAAO,CAAC,kBAAkB,CAAU;IAGpC,OAAO,CAAC,mBAAmB,CAAC,CAAU;IACtC,OAAO,CAAC,eAAe,CAAC,CAAU;IAGlC,OAAO,CAAC,cAAc,CAAC,CAAU;IACjC,OAAO,CAAC,mBAAmB,CAAC,CAAU;IAGtC,OAAO,CAAC,cAAc,CAAC,CAAU;IACjC,OAAO,CAAC,oBAAoB,CAAC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