diff --git a/interface/package.json b/interface/package.json index 128ff5c98..9537b36fd 100644 --- a/interface/package.json +++ b/interface/package.json @@ -26,13 +26,13 @@ "@babel/core": "^7.23.9", "@emotion/react": "^11.11.3", "@emotion/styled": "^11.11.0", - "@mui/icons-material": "^5.15.6", - "@mui/material": "^5.15.6", + "@mui/icons-material": "^5.15.7", + "@mui/material": "^5.15.7", "@table-library/react-table-library": "4.1.7", "@types/imagemin": "^8.0.5", "@types/lodash-es": "^4.17.12", - "@types/node": "^20.11.10", - "@types/react": "^18.2.48", + "@types/node": "^20.11.16", + "@types/react": "^18.2.52", "@types/react-dom": "^18.2.18", "@types/react-router-dom": "^5.3.3", "alova": "^2.17.0", @@ -45,7 +45,7 @@ "react-dom": "latest", "react-dropzone": "^14.2.3", "react-icons": "^5.0.1", - "react-router-dom": "^6.21.3", + "react-router-dom": "^6.22.0", "react-toastify": "^10.0.4", "sockette": "^2.0.6", "typesafe-i18n": "^5.26.2", diff --git a/interface/src/project/DashboardDevicesDialog.tsx b/interface/src/project/DashboardDevicesDialog.tsx index aab6fa30d..dbc943b78 100644 --- a/interface/src/project/DashboardDevicesDialog.tsx +++ b/interface/src/project/DashboardDevicesDialog.tsx @@ -26,7 +26,7 @@ import type { ValidateFieldsError } from 'async-validator'; import { dialogStyle } from 'CustomTheme'; import { ValidatedTextField } from 'components'; import { useI18nContext } from 'i18n/i18n-react'; -import { updateValue } from 'utils'; +import { updateValue, numberValue } from 'utils'; import { validate } from 'validators'; @@ -133,7 +133,7 @@ const DashboardDevicesDialog = ({ fieldErrors={fieldErrors} name="v" label={LL.VALUE(1)} - value={Math.round(editItem.v * 10) / 10} + value={numberValue(Math.round(editItem.v * 10) / 10)} autoFocus disabled={!writeable} type="number" diff --git a/interface/yarn.lock b/interface/yarn.lock index 12ed905ad..2eeff3c6f 100644 --- a/interface/yarn.lock +++ b/interface/yarn.lock @@ -401,12 +401,12 @@ __metadata: languageName: node linkType: hard -"@babel/runtime@npm:^7.23.8": - version: 7.23.8 - resolution: "@babel/runtime@npm:7.23.8" +"@babel/runtime@npm:^7.23.9": + version: 7.23.9 + resolution: "@babel/runtime@npm:7.23.9" dependencies: regenerator-runtime: "npm:^0.14.0" - checksum: ec8f1967a36164da6cac868533ffdff97badd76d23d7d820cc84f0818864accef972f22f9c6a710185db1e3810e353fc18c3da721e5bb3ee8bc61bdbabce03ff + checksum: 9a520fe1bf72249f7dd60ff726434251858de15cccfca7aa831bd19d0d3fb17702e116ead82724659b8da3844977e5e13de2bae01eb8a798f2823a669f122be6 languageName: node linkType: hard @@ -863,38 +863,38 @@ __metadata: languageName: node linkType: hard -"@floating-ui/core@npm:^1.5.3": - version: 1.5.3 - resolution: "@floating-ui/core@npm:1.5.3" +"@floating-ui/core@npm:^1.6.0": + version: 1.6.0 + resolution: "@floating-ui/core@npm:1.6.0" dependencies: - "@floating-ui/utils": "npm:^0.2.0" - checksum: 7d9feaca2565a2a71bf03d23cd292c03def63097d7fde7d62909cdb8ddb84664781f3922086bcf10443f3310cb92381a0ecf745b2774edb917fa74fe61015c56 + "@floating-ui/utils": "npm:^0.2.1" + checksum: d6a47cacde193cd8ccb4c268b91ccc4ca254dffaec6242b07fd9bcde526044cc976d27933a7917f9a671de0a0e27f8d358f46400677dbd0c8199de293e9746e1 languageName: node linkType: hard -"@floating-ui/dom@npm:^1.5.4": - version: 1.5.4 - resolution: "@floating-ui/dom@npm:1.5.4" +"@floating-ui/dom@npm:^1.6.1": + version: 1.6.1 + resolution: "@floating-ui/dom@npm:1.6.1" dependencies: - "@floating-ui/core": "npm:^1.5.3" - "@floating-ui/utils": "npm:^0.2.0" - checksum: 3ba02ba2b4227c1e18df6ccdd029a1c100058db2e76ca1dac60a593ec72b2d4d995fa5c2d1639a5c38adb17e12398fbfe4f6cf5fd45f2ee6170ed0cf64acea06 + "@floating-ui/core": "npm:^1.6.0" + "@floating-ui/utils": "npm:^0.2.1" + checksum: c010feb55be37662eb4cc8d0a22e21359c25247bbdcd9557617fd305cf08c8f020435b17e4b4f410201ba9abe3a0dd96b5c42d56e85f7a5e11e7d30b85afc116 languageName: node linkType: hard -"@floating-ui/react-dom@npm:^2.0.6": - version: 2.0.6 - resolution: "@floating-ui/react-dom@npm:2.0.6" +"@floating-ui/react-dom@npm:^2.0.8": + version: 2.0.8 + resolution: "@floating-ui/react-dom@npm:2.0.8" dependencies: - "@floating-ui/dom": "npm:^1.5.4" + "@floating-ui/dom": "npm:^1.6.1" peerDependencies: react: ">=16.8.0" react-dom: ">=16.8.0" - checksum: 4a3f828370c1b14af0e4d24df18de7b2cfd6695c189532d5949daaa43cba13ce7f231c71783b47e8c54baefcc2542650d82a4a6cebcf3d9091673f2a53d3a2cb + checksum: e57b2a498aecf8de0ec28adf434257fca7893bd9bd7e78b63ac98c63b29b9fc086fc175630154352f3610f5c4a0d329823837f4f6c235cc0459fde6417065590 languageName: node linkType: hard -"@floating-ui/utils@npm:^0.2.0": +"@floating-ui/utils@npm:^0.2.1": version: 0.2.1 resolution: "@floating-ui/utils@npm:0.2.1" checksum: 33c9ab346e7b05c5a1e6a95bc902aafcfc2c9d513a147e2491468843bd5607531b06d0b9aa56aa491cbf22a6c2495c18ccfc4c0344baec54a689a7bb8e4898d6 @@ -992,14 +992,14 @@ __metadata: languageName: node linkType: hard -"@mui/base@npm:5.0.0-beta.33": - version: 5.0.0-beta.33 - resolution: "@mui/base@npm:5.0.0-beta.33" +"@mui/base@npm:5.0.0-beta.34": + version: 5.0.0-beta.34 + resolution: "@mui/base@npm:5.0.0-beta.34" dependencies: - "@babel/runtime": "npm:^7.23.8" - "@floating-ui/react-dom": "npm:^2.0.6" + "@babel/runtime": "npm:^7.23.9" + "@floating-ui/react-dom": "npm:^2.0.8" "@mui/types": "npm:^7.2.13" - "@mui/utils": "npm:^5.15.6" + "@mui/utils": "npm:^5.15.7" "@popperjs/core": "npm:^2.11.8" clsx: "npm:^2.1.0" prop-types: "npm:^15.8.1" @@ -1010,22 +1010,22 @@ __metadata: peerDependenciesMeta: "@types/react": optional: true - checksum: 8898430f4c8f6d9ce2aa46f621e7a84e800ee2a08fd6ce121e999494c77256060376d11e4d05640e8848eca1d8d553e95c2a150ce68d6416a1517136e8253ef8 + checksum: 8705872e4290bec1a0e19cdb62cf0ead3b18c2fc4d404a4c2913107cc3418524d2f53c337878636af59595c5ac3631d1f108cbc236f6f9cd51b6efe768b65ea5 languageName: node linkType: hard -"@mui/core-downloads-tracker@npm:^5.15.6": - version: 5.15.6 - resolution: "@mui/core-downloads-tracker@npm:5.15.6" - checksum: 38833a893c82e6244814be8321819fd08379a872068e06e1511f01ce243e21258b108fe5ddc66a02fddf07bba95b6cb6e9fc59538733c6072cab59b701ccb5c1 +"@mui/core-downloads-tracker@npm:^5.15.7": + version: 5.15.7 + resolution: "@mui/core-downloads-tracker@npm:5.15.7" + checksum: cdaea04222020086fd68e25bdf0f4dfdfc9a3b58a558297ef0a247f02cce8ea7671f9a31c07c5b53cfe553d24110baed2b03b701b1bea60f5c2b2e3ba56ba6fc languageName: node linkType: hard -"@mui/icons-material@npm:^5.15.6": - version: 5.15.6 - resolution: "@mui/icons-material@npm:5.15.6" +"@mui/icons-material@npm:^5.15.7": + version: 5.15.7 + resolution: "@mui/icons-material@npm:5.15.7" dependencies: - "@babel/runtime": "npm:^7.23.8" + "@babel/runtime": "npm:^7.23.9" peerDependencies: "@mui/material": ^5.0.0 "@types/react": ^17.0.0 || ^18.0.0 @@ -1033,20 +1033,20 @@ __metadata: peerDependenciesMeta: "@types/react": optional: true - checksum: b7a39bbf86beac98ac0160e6bf4c6130fae16527cbd4e545e2fbcf07105c44c86364a0e03d27120225d30e01ca1a127caf693ba5ee6d0ac34421bc6db14cdb55 + checksum: d6c612aab0f10f57462e5bd467f8e32240123bc59728d471b7ae3724be4b02247db694e21e03ab58341e7737da87cef3aab35f98bbed14883688b8d667ff0f30 languageName: node linkType: hard -"@mui/material@npm:^5.15.6": - version: 5.15.6 - resolution: "@mui/material@npm:5.15.6" +"@mui/material@npm:^5.15.7": + version: 5.15.7 + resolution: "@mui/material@npm:5.15.7" dependencies: - "@babel/runtime": "npm:^7.23.8" - "@mui/base": "npm:5.0.0-beta.33" - "@mui/core-downloads-tracker": "npm:^5.15.6" - "@mui/system": "npm:^5.15.6" + "@babel/runtime": "npm:^7.23.9" + "@mui/base": "npm:5.0.0-beta.34" + "@mui/core-downloads-tracker": "npm:^5.15.7" + "@mui/system": "npm:^5.15.7" "@mui/types": "npm:^7.2.13" - "@mui/utils": "npm:^5.15.6" + "@mui/utils": "npm:^5.15.7" "@types/react-transition-group": "npm:^4.4.10" clsx: "npm:^2.1.0" csstype: "npm:^3.1.2" @@ -1066,16 +1066,16 @@ __metadata: optional: true "@types/react": optional: true - checksum: c6aff7dc5b65c68b4a6e1d0b4cc9712b906f0d3d57dcda49d7d4dee15e53872dec292e71bbdb38800849dccb0565aa259635e00332e85c1a8ba372322c8eeab8 + checksum: bc7a31e53770b27b49786567d4d2912d6ecf163a438d75806ec98dea8fa2f0e0b2daeb6ee97cba57c9636ed2d7e3b42c5c801f9d3479f02716933f839b7df6a4 languageName: node linkType: hard -"@mui/private-theming@npm:^5.15.6": - version: 5.15.6 - resolution: "@mui/private-theming@npm:5.15.6" +"@mui/private-theming@npm:^5.15.7": + version: 5.15.7 + resolution: "@mui/private-theming@npm:5.15.7" dependencies: - "@babel/runtime": "npm:^7.23.8" - "@mui/utils": "npm:^5.15.6" + "@babel/runtime": "npm:^7.23.9" + "@mui/utils": "npm:^5.15.7" prop-types: "npm:^15.8.1" peerDependencies: "@types/react": ^17.0.0 || ^18.0.0 @@ -1083,15 +1083,15 @@ __metadata: peerDependenciesMeta: "@types/react": optional: true - checksum: f56b4c99c4a634a29ff84e8d75940a6972a270ba896dae8d38ac8dc8663fe5c3c97db847c545302c80e831350b867b87c8cad6afc25eeb97ee6e0291bb274528 + checksum: 07d85483924f1ab641ff9810f5379d28bd0661db1b42604e1c1602d610d114396c1bd187eefd26b9c303727d7d16a4758ca5c8ffbc1b410cbae156edf8b9472f languageName: node linkType: hard -"@mui/styled-engine@npm:^5.15.6": - version: 5.15.6 - resolution: "@mui/styled-engine@npm:5.15.6" +"@mui/styled-engine@npm:^5.15.7": + version: 5.15.7 + resolution: "@mui/styled-engine@npm:5.15.7" dependencies: - "@babel/runtime": "npm:^7.23.8" + "@babel/runtime": "npm:^7.23.9" "@emotion/cache": "npm:^11.11.0" csstype: "npm:^3.1.2" prop-types: "npm:^15.8.1" @@ -1104,19 +1104,19 @@ __metadata: optional: true "@emotion/styled": optional: true - checksum: 0c932a6aff4fdacc0f1dcf02768ef3d56dbed4cd58c8040e2ea33d1e0284d18183d759af240fc4a891469e0ace3a32e1b9403951ed996e6e8a736b45ccf20ecc + checksum: 965e5738577db0d40904554b341395d337c93d7b4ebba783cb5362b6aa7f7e0be2cf1999d7c14daca6caba37a51f13188eaf260ff5b4099a269b1c155eee3773 languageName: node linkType: hard -"@mui/system@npm:^5.15.6": - version: 5.15.6 - resolution: "@mui/system@npm:5.15.6" +"@mui/system@npm:^5.15.7": + version: 5.15.7 + resolution: "@mui/system@npm:5.15.7" dependencies: - "@babel/runtime": "npm:^7.23.8" - "@mui/private-theming": "npm:^5.15.6" - "@mui/styled-engine": "npm:^5.15.6" + "@babel/runtime": "npm:^7.23.9" + "@mui/private-theming": "npm:^5.15.7" + "@mui/styled-engine": "npm:^5.15.7" "@mui/types": "npm:^7.2.13" - "@mui/utils": "npm:^5.15.6" + "@mui/utils": "npm:^5.15.7" clsx: "npm:^2.1.0" csstype: "npm:^3.1.2" prop-types: "npm:^15.8.1" @@ -1132,7 +1132,7 @@ __metadata: optional: true "@types/react": optional: true - checksum: 742133972a60e2c137be9daf231dee47d296acb98742c6c198db94999119883bd36c24e5392eafa9c99e8fb3225883b5a20a282baf56fb29cf0a0ce51740df51 + checksum: 49db180adf1e3341cf14791c93711d16c76aad371dd43966da49c8727751d5c611835be8bac61278269414820c8f6bbd41481fa615df9a1cbc79be5846ef8896 languageName: node linkType: hard @@ -1148,11 +1148,11 @@ __metadata: languageName: node linkType: hard -"@mui/utils@npm:^5.15.6": - version: 5.15.6 - resolution: "@mui/utils@npm:5.15.6" +"@mui/utils@npm:^5.15.7": + version: 5.15.7 + resolution: "@mui/utils@npm:5.15.7" dependencies: - "@babel/runtime": "npm:^7.23.8" + "@babel/runtime": "npm:^7.23.9" "@types/prop-types": "npm:^15.7.11" prop-types: "npm:^15.8.1" react-is: "npm:^18.2.0" @@ -1162,7 +1162,7 @@ __metadata: peerDependenciesMeta: "@types/react": optional: true - checksum: 7ed0131bc776f01ad64615cca21b6813d44b792d61bd5a17f8b4aab8387c8c72581322c2d0f4cd9664dfecec13268c2a00b50d8991f93a9abddaf22579d68c45 + checksum: 34f4ed23d1ac8ed7cc4c027789ea60def6a85d922f742ff57a614c0a77a839d38de40031895a867c0dadc1e5f226ac7044f2fea084297201326f0201c3f85237 languageName: node linkType: hard @@ -1299,10 +1299,10 @@ __metadata: languageName: node linkType: hard -"@remix-run/router@npm:1.14.2": - version: 1.14.2 - resolution: "@remix-run/router@npm:1.14.2" - checksum: 422844e88b985f1e287301b302c6cf8169c9eea792f80d40464f97b25393bb2e697228ebd7a7b61444d5a51c5873c4a637aad20acde5886a5caf62e833c5ceee +"@remix-run/router@npm:1.15.0": + version: 1.15.0 + resolution: "@remix-run/router@npm:1.15.0" + checksum: 5cadae0c90874966ebd6b1b202284a337da32a68fc95af502859cd6158d3c254fbb4f76fa1844c837205dbc8a8120223360b9287a3d6aa0c747d02767c4c072c languageName: node linkType: hard @@ -1590,12 +1590,12 @@ __metadata: languageName: node linkType: hard -"@types/node@npm:^20.11.10": - version: 20.11.10 - resolution: "@types/node@npm:20.11.10" +"@types/node@npm:^20.11.16": + version: 20.11.16 + resolution: "@types/node@npm:20.11.16" dependencies: undici-types: "npm:~5.26.4" - checksum: 41ca9c7e7c95bf070ad747ab266f267f41950e01f5ddda739d0665c2ed39acc45cce46f78e33ffa2bf2dacd74a8493044b967c86358017dacce12958e49db664 + checksum: 751f50ec5c9332b11515e82fe37c71479ac4449b711280aa3c7910edf67b1e3f5ac00041512add543f9a892096a68356406998bf02a2c809a73d176c44c28414 languageName: node linkType: hard @@ -1670,14 +1670,14 @@ __metadata: languageName: node linkType: hard -"@types/react@npm:^18.2.48": - version: 18.2.48 - resolution: "@types/react@npm:18.2.48" +"@types/react@npm:^18.2.52": + version: 18.2.52 + resolution: "@types/react@npm:18.2.52" dependencies: "@types/prop-types": "npm:*" "@types/scheduler": "npm:*" csstype: "npm:^3.0.2" - checksum: 2e56ea6bd821ae96bd943f727a59d85384eaf5f8a3e6fce4fa1d34453e32d8eedda742432b3857fa0de7a4214bf84ce4239757eb52918e76452c00384731e585 + checksum: 0ab90a37fd82028c3559f18ce50790d01b262589a2ea49d014d8888291f47d9c91e65cb7db031a3e5d58818cb5376577afb4b593068473abfd0c695fa7e6b7c4 languageName: node linkType: hard @@ -1851,15 +1851,15 @@ __metadata: "@babel/core": "npm:^7.23.9" "@emotion/react": "npm:^11.11.3" "@emotion/styled": "npm:^11.11.0" - "@mui/icons-material": "npm:^5.15.6" - "@mui/material": "npm:^5.15.6" + "@mui/icons-material": "npm:^5.15.7" + "@mui/material": "npm:^5.15.7" "@preact/compat": "npm:^17.1.2" "@preact/preset-vite": "npm:^2.8.1" "@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.11.10" - "@types/react": "npm:^18.2.48" + "@types/node": "npm:^20.11.16" + "@types/react": "npm:^18.2.52" "@types/react-dom": "npm:^18.2.18" "@types/react-router-dom": "npm:^5.3.3" "@typescript-eslint/eslint-plugin": "npm:^6.20.0" @@ -1888,7 +1888,7 @@ __metadata: react-dom: "npm:latest" react-dropzone: "npm:^14.2.3" react-icons: "npm:^5.0.1" - react-router-dom: "npm:^6.21.3" + react-router-dom: "npm:^6.22.0" react-toastify: "npm:^10.0.4" rollup-plugin-visualizer: "npm:^5.12.0" sockette: "npm:^2.0.6" @@ -7240,27 +7240,27 @@ __metadata: languageName: node linkType: hard -"react-router-dom@npm:^6.21.3": - version: 6.21.3 - resolution: "react-router-dom@npm:6.21.3" +"react-router-dom@npm:^6.22.0": + version: 6.22.0 + resolution: "react-router-dom@npm:6.22.0" dependencies: - "@remix-run/router": "npm:1.14.2" - react-router: "npm:6.21.3" + "@remix-run/router": "npm:1.15.0" + react-router: "npm:6.22.0" peerDependencies: react: ">=16.8" react-dom: ">=16.8" - checksum: 6e23e35d02e5c83847c8e47d7912d1f6c2c42a35f2317802031bdd993a8205468138a045ff34f67fe807fe9f7dc9d0995ee05bab25aedc0bf978e620ac132815 + checksum: 32ba0386d400354094116fa7dd98f1d23bc7cf683b0f4509694be5f730d4957fcb8cc73e35946576fc3f48b4d36743422f1b9bcdc37ad77f04bde0bde5d9102e languageName: node linkType: hard -"react-router@npm:6.21.3": - version: 6.21.3 - resolution: "react-router@npm:6.21.3" +"react-router@npm:6.22.0": + version: 6.22.0 + resolution: "react-router@npm:6.22.0" dependencies: - "@remix-run/router": "npm:1.14.2" + "@remix-run/router": "npm:1.15.0" peerDependencies: react: ">=16.8" - checksum: 3d5107cfdb440519d84e6ad6d95454e3bf41ec97677b95f7b2a7f281f8ddf191b765cf1b599ead951f3cd33ed4429f140590d74a01cfdf835dc2f812023a978a + checksum: 627c25533667da0c8008587208e0d5633409173969fd579de706cde355465f6d1245e2b1a7ca2adeb96201f2858932b59ce3402482786cd20c4bf278562976dd languageName: node linkType: hard diff --git a/lib/PButton/PButon.cpp b/lib/PButton/PButon.cpp index dfbf4f898..61b8001d2 100644 --- a/lib/PButton/PButon.cpp +++ b/lib/PButton/PButon.cpp @@ -55,7 +55,7 @@ bool PButton::init(uint8_t pin, bool pullMode) { #if defined(ESP32) pinMode(pin_, pullMode ? INPUT_PULLUP : INPUT_PULLDOWN); -#else // esp8266 and standalone +#else // esp8266 and standalone pinMode(pin_, pullMode ? INPUT_PULLUP : INPUT); #endif enabled_ = (digitalRead(pin_) == pullMode); // see if a button is connected @@ -91,6 +91,12 @@ bool PButton::check(void) { int resultEvent = 0; long millisRes = millis(); + // make sure the pin is still input +#if defined(ESP32) + pinMode(pin_, pullMode_ ? INPUT_PULLUP : INPUT_PULLDOWN); +#else // esp8266 and standalone + pinMode(pin_, pullMode_ ? INPUT_PULLUP : INPUT); +#endif state_ = digitalRead(pin_) == pullMode_; // Button pressed down diff --git a/src/command.cpp b/src/command.cpp index 3287f02a6..9b5037060 100644 --- a/src/command.cpp +++ b/src/command.cpp @@ -176,7 +176,7 @@ uint8_t Command::process(const char * path, const bool is_admin, const JsonObjec String dat = output["api_data"]; output.clear(); input["data"] = dat.c_str(); - data = input["data"]; + data = input["data"]; } } } diff --git a/src/devices/boiler.cpp b/src/devices/boiler.cpp index 49bea1edd..d66e1432c 100644 --- a/src/devices/boiler.cpp +++ b/src/devices/boiler.cpp @@ -806,6 +806,30 @@ Boiler::Boiler(uint8_t device_type, int8_t device_id, uint8_t product_id, const MAKE_CF_CB(set_wwEcoPlusOffTemp), 48, 63); + register_device_value(DeviceValueTAG::TAG_BOILER_DATA_WW, + &wwComfDiffTemp_, + DeviceValueType::UINT, + FL_(wwComfDiffTemp), + DeviceValueUOM::K, + MAKE_CF_CB(set_wwComfDiffTemp), + 6, + 12); + register_device_value(DeviceValueTAG::TAG_BOILER_DATA_WW, + &wwEcoDiffTemp_, + DeviceValueType::UINT, + FL_(wwEcoDiffTemp), + DeviceValueUOM::K, + MAKE_CF_CB(set_wwEcoDiffTemp), + 6, + 12); + register_device_value(DeviceValueTAG::TAG_BOILER_DATA_WW, + &wwEcoPlusDiffTemp_, + DeviceValueType::UINT, + FL_(wwEcoPlusDiffTemp), + DeviceValueUOM::K, + MAKE_CF_CB(set_wwEcoPlusDiffTemp), + 6, + 12); register_device_value(DeviceValueTAG::TAG_BOILER_DATA_WW, &hpCircPumpWw_, DeviceValueType::BOOL, @@ -1906,6 +1930,10 @@ void Boiler::process_HpDhwSettings(std::shared_ptr telegram) { has_update(telegram, wwComfOffTemp_, 1); has_update(telegram, wwEcoOffTemp_, 0); has_update(telegram, wwEcoPlusOffTemp_, 5); + // https://github.com/emsesp/EMS-ESP32/issues/1597 + has_update(telegram, wwComfDiffTemp_, 12); + has_update(telegram, wwEcoDiffTemp_, 13); + has_update(telegram, wwEcoPlusDiffTemp_, 14); } // 0x49C: @@ -2918,6 +2946,15 @@ bool Boiler::set_tempDiff(const char * value, const int8_t id) { } bool Boiler::set_wwOffTemp(const char * value, const int8_t id) { + int v; + if (Helpers::value2temperature(value, v)) { + write_command(0x499, id, v, 0x499); + return true; + } + return false; +} + +bool Boiler::set_wwDiffTemp(const char * value, const int8_t id) { int v; if (Helpers::value2number(value, v)) { write_command(0x499, id, v, 0x499); diff --git a/src/devices/boiler.h b/src/devices/boiler.h index 106764a72..ff9f7f66b 100644 --- a/src/devices/boiler.h +++ b/src/devices/boiler.h @@ -265,6 +265,9 @@ class Boiler : public EMSdevice { uint8_t wwComfOffTemp_; uint8_t wwEcoOffTemp_; uint8_t wwEcoPlusOffTemp_; + uint8_t wwComfDiffTemp_; + uint8_t wwEcoDiffTemp_; + uint8_t wwEcoPlusDiffTemp_; uint8_t vp_cooling_; uint8_t heatCable_; @@ -475,6 +478,16 @@ class Boiler : public EMSdevice { inline bool set_wwEcoPlusOffTemp(const char * value, const int8_t id) { return set_wwOffTemp(value, 5); } + bool set_wwDiffTemp(const char * value, const int8_t id); + inline bool set_wwComfDiffTemp(const char * value, const int8_t id) { + return set_wwDiffTemp(value, 12); + } + inline bool set_wwEcoDiffTemp(const char * value, const int8_t id) { + return set_wwDiffTemp(value, 13); + } + inline bool set_wwEcoPlusDiffTemp(const char * value, const int8_t id) { + return set_wwDiffTemp(value, 14); + } bool set_vp_cooling(const char * value, const int8_t id); bool set_heatCable(const char * value, const int8_t id); bool set_VC0valve(const char * value, const int8_t id); diff --git a/src/emsesp.cpp b/src/emsesp.cpp index 0418a6e4f..c643d9ffc 100644 --- a/src/emsesp.cpp +++ b/src/emsesp.cpp @@ -747,10 +747,20 @@ std::string EMSESP::pretty_telegram(std::shared_ptr telegram) { for (const auto & emsdevice : emsdevices) { if (telegram->operation != Telegram::Operation::RX_READ && emsdevice->is_device_id(src)) { type_name = emsdevice->telegram_type_name(telegram); + break; } } } + if (type_name.empty()) { + // 2nd fallback, get the type name from dest + for (const auto & emsdevice : emsdevices) { + if (telegram->operation != Telegram::Operation::RX_READ && emsdevice->is_device_id(dest)) { + type_name = emsdevice->telegram_type_name(telegram); + break; + } + } + } // if we can't find names for the devices, use their hex values if (src_name.empty()) { src_name = device_tostring(src); diff --git a/src/locale_translations.h b/src/locale_translations.h index ab982664a..dbefa1ed9 100644 --- a/src/locale_translations.h +++ b/src/locale_translations.h @@ -437,6 +437,9 @@ MAKE_TRANSLATION(silentTo, "silentto", "silent mode to", "Silentmodus Ende", "Ei MAKE_TRANSLATION(wwComfOffTemp, "wwcomfoff", "comfort switch off", "Komfort Ausschalttemp", "Comfort Uitschakeltemp.", "Komfortläge avstängingstemp.", "temperatura wyłączania w trybie komfort", "eco modus utkoblingstem", "Confort Temp. d'arrêt", "konfor kapalı", "spegnimento modalità comfort", "komfortné vypnutie") MAKE_TRANSLATION(wwEcoOffTemp, "wwecooff", "eco switch off", "ECO Ausschalttemp", "Eco Uitschakeltemp.", "Ekoläge avstängningstemp.", "temperatura wyłączania w trybie eko", "Øko avstengningstemp.", "Eco Temp. d'arrêt", "eko kapalı", "spegnimento modalità ECO", "eko vypínač") MAKE_TRANSLATION(wwEcoPlusOffTemp, "wwecoplusoff", "eco+ switch off", "ECO+ Ausschalttemp", "Eco+ Uitschakeltemp.", "Eko+ avstängningstemp.", "temperatura wyłączania w trybie eko+", "Øko+ avstengningstemp.", "Eco+ Temp. d'arrêt", "eko+ kapalı", "spegnimento modalità ECO+", "eko+ vypnutie") +MAKE_TRANSLATION(wwComfDiffTemp, "wwcomfdiff", "comfort diff", "Komfort Differenztemp", "", "", "", "", "", "", "", "") // TODO translate +MAKE_TRANSLATION(wwEcoDiffTemp, "wwecodiff", "eco diff", "ECO Differenztemp", "", "", "", "", "", "", "", "") // TODO translate +MAKE_TRANSLATION(wwEcoPlusDiffTemp, "wwecoplusdiff", "eco+ diff", "ECO+ Differenztemp", "", "", "", "", "", "", "", "") // TODO translate MAKE_TRANSLATION(auxHeatMode, "auxheatrmode", "aux heater mode", "Modus Zusatzheizer", "Modus bijverwarmer", "", "tryb pracy dogrzewacza po blokadzie z Zakładu Energetycznego", "tilleggsvarmer modus", "", "ilave ısıtıcı modu", "modalità riscaldatore addizionale", "režim pomocného ohrievača") // TODO translate MAKE_TRANSLATION(auxMaxLimit, "auxmaxlimit", "aux heater max limit", "Zusatzheizer max. Grenze", "Bijverwarmer grensinstelling maximaal", "", "dogrzewacz, maksymalny limit", "tillegsvarme maksgrense", "", "ilave ısıtıcı maks limit", "limite massimo riscaldatore addizionale", "maximálny limit pomocného ohrievača") // TODO translate