Skip to content

Commit

Permalink
Merge pull request #1481 from MichaelDvP/dev
Browse files Browse the repository at this point in the history
add hpMaxPower #1475
  • Loading branch information
proddy committed Dec 4, 2023
2 parents f9b8ac6 + 10cabd0 commit c3ac215
Show file tree
Hide file tree
Showing 6 changed files with 73 additions and 39 deletions.
7 changes: 5 additions & 2 deletions CHANGELOG_LATEST.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,12 +6,15 @@

## Added

- thermostat boost mode and boost time
- heatpump energy meters
- thermostat boost mode and boost time [#1446](https://github.com/emsesp/EMS-ESP32/issues/1446)
- heatpump energy meters [#1463](https://github.com/emsesp/EMS-ESP32/issues/1463)
- heatpump max power [#1475](https://github.com/emsesp/EMS-ESP32/issues/1475)
- checkbox for MQTT-TLS enable [#1474](https://github.com/emsesp/EMS-ESP32/issues/1474)

## Fixed

- exhaust temperature for some boilers
- add back boil2hyst [#1477](https://github.com/emsesp/EMS-ESP32/issues/1477)

## Changed

Expand Down
8 changes: 4 additions & 4 deletions interface/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@
"@table-library/react-table-library": "4.1.7",
"@types/imagemin": "^8.0.5",
"@types/lodash-es": "^4.17.12",
"@types/node": "^20.10.2",
"@types/node": "^20.10.3",
"@types/react": "^18.2.41",
"@types/react-dom": "^18.2.17",
"@types/react-router-dom": "^5.3.3",
Expand Down Expand Up @@ -68,9 +68,9 @@
"eslint-plugin-react-hooks": "^4.6.0",
"preact": "^10.19.2",
"prettier": "^3.1.0",
"rollup-plugin-visualizer": "^5.9.3",
"terser": "^5.24.0",
"vite": "^5.0.4",
"rollup-plugin-visualizer": "^5.10.0",
"terser": "^5.25.0",
"vite": "^5.0.5",
"vite-plugin-imagemin": "^0.6.1",
"vite-tsconfig-paths": "^4.2.1"
},
Expand Down
60 changes: 30 additions & 30 deletions interface/yarn.lock
Original file line number Diff line number Diff line change
Expand Up @@ -1526,12 +1526,12 @@ __metadata:
languageName: node
linkType: hard

"@types/node@npm:^20.10.2":
version: 20.10.2
resolution: "@types/node@npm:20.10.2"
"@types/node@npm:^20.10.3":
version: 20.10.3
resolution: "@types/node@npm:20.10.3"
dependencies:
undici-types: "npm:~5.26.4"
checksum: e88d0e92870ec4880642cc39250903a098443d791e864a08d08f4e7fdca0c4c9c0233a6fd98bec356f0ebabc6551152a4590d1c9c34b73a95c2b33935f59185f
checksum: 7cb506abb0d570bb5133bd06a47115109a813b507323c985c3b4aef2993eed79b6bb62b82194cb5c558b4d349de3d199ee2e8c693b913065a1cd7f526cc65a68
languageName: node
linkType: hard

Expand Down Expand Up @@ -1793,7 +1793,7 @@ __metadata:
"@table-library/react-table-library": "npm:4.1.7"
"@types/imagemin": "npm:^8.0.5"
"@types/lodash-es": "npm:^4.17.12"
"@types/node": "npm:^20.10.2"
"@types/node": "npm:^20.10.3"
"@types/react": "npm:^18.2.41"
"@types/react-dom": "npm:^18.2.17"
"@types/react-router-dom": "npm:^5.3.3"
Expand Down Expand Up @@ -1825,12 +1825,12 @@ __metadata:
react-icons: "npm:^4.12.0"
react-router-dom: "npm:^6.20.1"
react-toastify: "npm:^9.1.3"
rollup-plugin-visualizer: "npm:^5.9.3"
rollup-plugin-visualizer: "npm:^5.10.0"
sockette: "npm:^2.0.6"
terser: "npm:^5.24.0"
terser: "npm:^5.25.0"
typesafe-i18n: "npm:^5.26.2"
typescript: "npm:^5.3.2"
vite: "npm:^5.0.4"
vite: "npm:^5.0.5"
vite-plugin-imagemin: "npm:^0.6.1"
vite-tsconfig-paths: "npm:^4.2.1"
languageName: unknown
Expand Down Expand Up @@ -6253,12 +6253,12 @@ __metadata:
languageName: node
linkType: hard

"nanoid@npm:^3.3.6":
version: 3.3.6
resolution: "nanoid@npm:3.3.6"
"nanoid@npm:^3.3.7":
version: 3.3.7
resolution: "nanoid@npm:3.3.7"
bin:
nanoid: bin/nanoid.cjs
checksum: 67235c39d1bc05851383dadde5cf77ae1c90c2a1d189e845c7f20f646f0488d875ad5f5226bbba072a88cebbb085a3f784a6673117daf785bdf614a852550362
checksum: ac1eb60f615b272bccb0e2b9cd933720dad30bf9708424f691b8113826bb91aca7e9d14ef5d9415a6ba15c266b37817256f58d8ce980c82b0ba3185352565679
languageName: node
linkType: hard

Expand Down Expand Up @@ -6886,14 +6886,14 @@ __metadata:
languageName: node
linkType: hard

"postcss@npm:^8.4.31":
version: 8.4.31
resolution: "postcss@npm:8.4.31"
"postcss@npm:^8.4.32":
version: 8.4.32
resolution: "postcss@npm:8.4.32"
dependencies:
nanoid: "npm:^3.3.6"
nanoid: "npm:^3.3.7"
picocolors: "npm:^1.0.0"
source-map-js: "npm:^1.0.2"
checksum: 1a6653e72105907377f9d4f2cd341d8d90e3fde823a5ddea1e2237aaa56933ea07853f0f2758c28892a1d70c53bbaca200eb8b80f8ed55f13093003dbec5afa0
checksum: 28084864122f29148e1f632261c408444f5ead0e0b9ea9bd9729d0468818ebe73fe5dc0075acd50c1365dbe639b46a79cba27d355ec857723a24bc9af0f18525
languageName: node
linkType: hard

Expand Down Expand Up @@ -7374,9 +7374,9 @@ __metadata:
languageName: node
linkType: hard

"rollup-plugin-visualizer@npm:^5.9.3":
version: 5.9.3
resolution: "rollup-plugin-visualizer@npm:5.9.3"
"rollup-plugin-visualizer@npm:^5.10.0":
version: 5.10.0
resolution: "rollup-plugin-visualizer@npm:5.10.0"
dependencies:
open: "npm:^8.4.0"
picomatch: "npm:^2.3.1"
Expand All @@ -7389,7 +7389,7 @@ __metadata:
optional: true
bin:
rollup-plugin-visualizer: dist/bin/cli.js
checksum: 569acbdf9401fb5e23456d889b1094e95a003331c63428732f94418eda59850fd74994587353f58c833a535cc24cdef56c06872996f76f98802ff22939ebbf0d
checksum: aa4ef8d2aae064b50a50168094db1337762d91bd0cd06206cfbc96a97adca45b7036dc1871eab7e70878111eeedb8164fe267f5cc56cd9eb4225ed71c8966aa6
languageName: node
linkType: hard

Expand Down Expand Up @@ -8188,17 +8188,17 @@ __metadata:
languageName: node
linkType: hard

"terser@npm:^5.24.0":
version: 5.24.0
resolution: "terser@npm:5.24.0"
"terser@npm:^5.25.0":
version: 5.25.0
resolution: "terser@npm:5.25.0"
dependencies:
"@jridgewell/source-map": "npm:^0.3.3"
acorn: "npm:^8.8.2"
commander: "npm:^2.20.0"
source-map-support: "npm:~0.5.20"
bin:
terser: bin/terser
checksum: bd7ba6bfef58f8c179592894923c8c933d980e17287d3f2a9927550be853d1601beebb724cf015929599b32945641c44f9c3db8dd242c7933af3830bcb853510
checksum: 820623b22b7f04e207ca08643d1ba15a0f9e3c1e67b1727d82fe6292f4393b6a1dd08f459c3463fd3eeefa2b9eb12322bdef2f11940c46e0763922624a9b4e0c
languageName: node
linkType: hard

Expand Down Expand Up @@ -8614,13 +8614,13 @@ __metadata:
languageName: node
linkType: hard

"vite@npm:^5.0.4":
version: 5.0.4
resolution: "vite@npm:5.0.4"
"vite@npm:^5.0.5":
version: 5.0.5
resolution: "vite@npm:5.0.5"
dependencies:
esbuild: "npm:^0.19.3"
fsevents: "npm:~2.3.3"
postcss: "npm:^8.4.31"
postcss: "npm:^8.4.32"
rollup: "npm:^4.2.0"
peerDependencies:
"@types/node": ^18.0.0 || >=20.0.0
Expand Down Expand Up @@ -8650,7 +8650,7 @@ __metadata:
optional: true
bin:
vite: bin/vite.js
checksum: 3d1726e5ee09c99ca8f57ebb34428ceb23e51705cd9e39ee97cb123870caaff1e65fbeaed00658f8112dd6ac658e90cd020bd33c090ecd190fb962e43cc8d64c
checksum: f4cd6e6e38448bdb6dd4dc36c0b34a5c42944d88961b9df246e75a4c3237196b1c64b1afc563524405d1fe3f34e728b9dbfd8cbc5af4e0a03371033d8057fdfe
languageName: node
linkType: hard

Expand Down
34 changes: 31 additions & 3 deletions src/devices/boiler.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -232,8 +232,14 @@ Boiler::Boiler(uint8_t device_type, int8_t device_id, uint8_t product_id, const
DeviceValueTAG::TAG_DEVICE_DATA, &boilHystOff_, DeviceValueType::INT, FL_(boilHystOff), DeviceValueUOM::DEGREES_R, MAKE_CF_CB(set_hyst_off), 0, 20);
register_device_value(
DeviceValueTAG::TAG_DEVICE_DATA, &boil2HystOn_, DeviceValueType::INT, FL_(boil2HystOn), DeviceValueUOM::DEGREES_R, MAKE_CF_CB(set_hyst2_on), -20, 0);
register_device_value(
DeviceValueTAG::TAG_DEVICE_DATA, &boil2HystOff_, DeviceValueType::INT, FL_(boil2HystOff), DeviceValueUOM::DEGREES_R, MAKE_CF_CB(set_hyst2_off), 0, 20);
register_device_value(DeviceValueTAG::TAG_DEVICE_DATA,
&boil2HystOff_,
DeviceValueType::INT,
FL_(boil2HystOff),
DeviceValueUOM::DEGREES_R,
MAKE_CF_CB(set_hyst2_off),
0,
20);
}
register_device_value(DeviceValueTAG::TAG_DEVICE_DATA,
&heatingActivated_,
Expand Down Expand Up @@ -470,6 +476,12 @@ Boiler::Boiler(uint8_t device_type, int8_t device_id, uint8_t product_id, const
register_device_value(DeviceValueTAG::TAG_DEVICE_DATA, &nrgSuppCooling_, DeviceValueType::ULONG, FL_(nrgSuppCooling), DeviceValueUOM::KWH);
register_device_value(DeviceValueTAG::TAG_DEVICE_DATA, &nrgSuppPool_, DeviceValueType::ULONG, FL_(nrgSuppPool), DeviceValueUOM::KWH);
register_device_value(DeviceValueTAG::TAG_DEVICE_DATA, &hpPower_, DeviceValueType::UINT, DeviceValueNumOp::DV_NUMOP_DIV10, FL_(hpPower), DeviceValueUOM::KW);
register_device_value(DeviceValueTAG::TAG_DEVICE_DATA,
&hpMaxPower_,
DeviceValueType::UINT,
FL_(hpMaxPower),
DeviceValueUOM::PERCENT,
MAKE_CF_CB(set_hpMaxPower));
register_device_value(DeviceValueTAG::TAG_DEVICE_DATA, &hpCompOn_, DeviceValueType::BOOL, FL_(hpCompOn), DeviceValueUOM::NONE);
register_device_value(DeviceValueTAG::TAG_DEVICE_DATA, &hpActivity_, DeviceValueType::ENUM, FL_(enum_hpactivity), FL_(hpActivity), DeviceValueUOM::NONE);
// register_device_value(DeviceValueTAG::TAG_DEVICE_DATA, &hpHeatingOn_, DeviceValueType::BOOL, FL_(hpHeatingOn), DeviceValueUOM::NONE);
Expand Down Expand Up @@ -730,7 +742,13 @@ Boiler::Boiler(uint8_t device_type, int8_t device_id, uint8_t product_id, const
DeviceValueUOM::NONE,
MAKE_CF_CB(set_elHeatStep3));
register_device_value(DeviceValueTAG::TAG_DEVICE_DATA, &hpEA0_, DeviceValueType::BOOL, FL_(hpEA0), DeviceValueUOM::NONE);
register_device_value(DeviceValueTAG::TAG_DEVICE_DATA, &hpPumpMode_, DeviceValueType::ENUM, FL_(enum_hpPumpMode), FL_(hpPumpMode), DeviceValueUOM::NONE, MAKE_CF_CB(set_hpPumpMode));
register_device_value(DeviceValueTAG::TAG_DEVICE_DATA,
&hpPumpMode_,
DeviceValueType::ENUM,
FL_(enum_hpPumpMode),
FL_(hpPumpMode),
DeviceValueUOM::NONE,
MAKE_CF_CB(set_hpPumpMode));
// heatpump DHW settings
register_device_value(DeviceValueTAG::TAG_BOILER_DATA_WW,
&wwAlternatingOper_,
Expand Down Expand Up @@ -1822,6 +1840,7 @@ void Boiler::process_HpSilentMode(std::shared_ptr<const Telegram> telegram) {
has_update(telegram, hpHystCool_, 35); // is / 5, maybe offset swapped with pool
has_update(telegram, hpHystPool_, 33); // is / 5
has_update(telegram, hpCircPumpWw_, 46);
has_update(telegram, hpMaxPower_, 31);
has_update(telegram, silentFrom_, 52); // in steps of 15 min
has_update(telegram, silentTo_, 53); // in steps of 15 min
}
Expand Down Expand Up @@ -2887,6 +2906,15 @@ bool Boiler::set_hpPumpMode(const char * value, const int8_t id) {
return false;
}

bool Boiler::set_hpMaxPower(const char * value, const int8_t id) {
int v;
if (Helpers::value2number(value, v)) {
write_command(0x484, 31, v, 0x484);
return true;
}
return false;
}

bool Boiler::set_vp_cooling(const char * value, const int8_t id) {
bool v;
if (Helpers::value2bool(value, v)) {
Expand Down
2 changes: 2 additions & 0 deletions src/devices/boiler.h
Original file line number Diff line number Diff line change
Expand Up @@ -236,6 +236,7 @@ class Boiler : public EMSdevice {
uint8_t maxHeatComp_;
uint8_t maxHeatHeat_;
uint8_t maxHeatDhw_;
uint8_t hpMaxPower_;

uint8_t pvCooling_;
uint8_t manDefrost_;
Expand Down Expand Up @@ -434,6 +435,7 @@ class Boiler : public EMSdevice {
bool set_pvCooling(const char * value, const int8_t id);
bool set_hpCircPumpWw(const char * value, const int8_t id);
bool set_hpPumpMode(const char * value, const int8_t id);
bool set_hpMaxPower(const char * value, const int8_t id);

bool set_auxLimit(const char * value, const int8_t id);
inline bool set_auxMaxLimit(const char * value, const int8_t id) {
Expand Down
1 change: 1 addition & 0 deletions src/locale_translations.h
Original file line number Diff line number Diff line change
Expand Up @@ -386,6 +386,7 @@ MAKE_TRANSLATION(hpBrineOut, "hpbrineout", "brine out/condenser", "Sole aus/Kond
MAKE_TRANSLATION(hpSwitchValve, "hpswitchvalve", "switch valve", "Schaltventil", "schakelklep", "Växelventil", "zawór przełączający", "skifteventil", "valve de commutation", "ısı pompası aktivitesi", "valvola commutazione pompa di calore")
MAKE_TRANSLATION(hpActivity, "hpactivity", "compressor activity", "Kompressor-Betriebsmodus", "Compressoractiviteit", "Kompressoraktivitet", "pompa ciepła, aktywność sprężarki", "kompressoraktivitet", "", "hp ısı pompası", "attività compressore")

MAKE_TRANSLATION(hpMaxPower, "hpmaxpower", "compressor max power", "max. Kompressorleistung", "", "", "", "", "", "", "") // TODO translate
MAKE_TRANSLATION(hpPower, "hppower", "compressor power output", "Kompressorleistung", "Compressorvermogen", "Kompressoreffekt", "moc wyjściowa sprężarki", "kompressoreffekt", "puissance de sortie compresseur", "ısı pompası güç çıkışı", "potenza uscita compressore")
MAKE_TRANSLATION(hpTc0, "hptc0", "heat carrier return (TC0)", "Kältemittel Rücklauf (TC0)", "Koudemiddel retour (TC0)", "Värmebärare Retur (TC0)", "temperatura nośnika ciepła na powrocie (TC0)", "kjølemiddel retur (TC0)", "retour caloporteur (TC0)", "sıcak su dönüşü (TC0)", "ritorno del refrigerante (TC0)")
MAKE_TRANSLATION(hpTc1, "hptc1", "heat carrier forward (TC1)", "Kältemittel Vorlauf (TC1)", "Koudemiddel aanvoer (TC1)", "Värmebärare Framledning (TC1)", "temperatura nośnika ciepła pierwotna (TC1)", "kjølemiddel tur (TC1)", "avance caloporteur (TC1)", "sıcak su çıkışı (TC1)", "flusso di refrigerante (TC1)")
Expand Down

0 comments on commit c3ac215

Please sign in to comment.