iobroker.keenergy 0.2.1 → 0.3.0

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/LICENSE CHANGED
@@ -1,7 +1,7 @@
1
1
  GNU GENERAL PUBLIC LICENSE
2
2
  Version 3, 29 June 2007
3
3
 
4
- Copyright (C) 2024 jb-io
4
+ Copyright (C) 2007 Free Software Foundation, Inc. <https://fsf.org/>
5
5
  Everyone is permitted to copy and distribute verbatim copies
6
6
  of this license document, but changing it is not allowed.
7
7
 
@@ -631,8 +631,8 @@ to attach them to the start of each source file to most effectively
631
631
  state the exclusion of warranty; and each file should have at least
632
632
  the "copyright" line and a pointer to where the full notice is found.
633
633
 
634
- <one line to give the program's name and a brief idea of what it does.>
635
- Copyright (C) <year> <name of author>
634
+ ioBroker.keenergy - Adapter for KEBA KeEnergy Web HMI - Remote Control
635
+ Copyright (C) 2022-2026 jb-io
636
636
 
637
637
  This program is free software: you can redistribute it and/or modify
638
638
  it under the terms of the GNU General Public License as published by
@@ -652,7 +652,7 @@ Also add information on how to contact you by electronic and paper mail.
652
652
  If the program does terminal interaction, make it output a short
653
653
  notice like this when it starts in an interactive mode:
654
654
 
655
- <program> Copyright (C) <year> <name of author>
655
+ ioBroker.keenergy Copyright (C) 2022-2026 jb-io
656
656
  This program comes with ABSOLUTELY NO WARRANTY; for details type `show w'.
657
657
  This is free software, and you are welcome to redistribute it
658
658
  under certain conditions; type `show c' for details.
package/README.md CHANGED
@@ -5,6 +5,7 @@
5
5
  [![Downloads](https://img.shields.io/npm/dm/iobroker.keenergy.svg)](https://www.npmjs.com/package/iobroker.keenergy)
6
6
  ![Number of Installations](https://iobroker.live/badges/keenergy-installed.svg)
7
7
  ![Current version in stable repository](https://iobroker.live/badges/keenergy-stable.svg)
8
+ [![License: GPL v3](https://img.shields.io/badge/License-GPLv3-blue.svg)](https://www.gnu.org/licenses/gpl-3.0)
8
9
 
9
10
  [![NPM](https://nodei.co/npm/iobroker.keenergy.png?downloads=true)](https://nodei.co/npm/iobroker.keenergy/)
10
11
 
@@ -19,13 +20,19 @@ Adapter for KEBA KeEnergy Web HMI - Remote Control
19
20
  **This adapter connects to your KeEnergy Web HMI in your local network (no cloud access!) and provides the states in your ioBroker.
20
21
  You can also change certain states if allowed by definition of your Web HMI.**
21
22
 
23
+ ## Requirements
24
+
25
+ - KEBA KeEnergy Web HMI (e.g. M-TEC heat pumps) reachable via HTTP on the local network
26
+ - Node.js >= 22
27
+ - js-controller >= 6.0.11, admin >= 7.6.20
28
+
22
29
  ## Configuration
23
30
 
24
31
  ![Configuration](./doc/settings.png)
25
32
 
26
33
  ### Host
27
34
 
28
- This can either be a IP-address or a hostname to the webinterface of your Web HMI
35
+ This can either be an IP address or a hostname to the webinterface of your Web HMI
29
36
 
30
37
  ### Connection timeout
31
38
 
@@ -36,6 +43,8 @@ Large timeouts may block your system. Too small timeouts may break your connecti
36
43
 
37
44
  You can adapt this timeout depending on your network speed.
38
45
 
46
+ **Note:** the setting is currently not applied, requests use a fixed timeout of 3000 ms.
47
+
39
48
  ### Update interval
40
49
 
41
50
  **UNIT:** seconds
@@ -69,16 +78,29 @@ The following user levels are known:
69
78
  By setting this option, all data points are removed on restarting your adapter.
70
79
  This may be helpful if the system unit or language has changed or for debugging purpose.
71
80
 
72
- ## Contribution and Development
81
+ ## States
73
82
 
74
- If you want to contribute have a look at the [Developer Guide](./doc/CONTRIBUTE.md)
83
+ | State | Type | Description |
84
+ |---|---|---|
85
+ | `info.connection` | boolean | Web HMI reachable |
86
+ | `APPL.*` | number / boolean / string | Variables of the Web HMI, e.g. `APPL.CtrlAppl.sParam.options.hasSolar`. Array indices become path segments (`…[0].…` → `….0.…`). |
75
87
 
76
- ## Changelog
88
+ Which variables are created is taken from the Web HMI's own mask tree (`DetailMask.xml`),
89
+ filtered by the configured display level. Names, units and value lists come from the Web HMI
90
+ in the configured language and system unit. States are writable if the variable is writable on
91
+ the Web HMI and the configured input level allows it; written values are read back from the
92
+ device and confirmed with `ack: true`.
77
93
 
94
+ ## Changelog
78
95
  <!--
79
- Placeholder for the next version (at the beginning of the line):
80
- ### **WORK IN PROGRESS**
96
+ Placeholder for the next version (at the beginning of the line):
97
+ ### **WORK IN PROGRESS**
81
98
  -->
99
+ ### 0.3.0 (2026-11-28)
100
+ * [TASK] Harmonize project structure, tooling and tests
101
+ * [TASK] Require js-controller >= 6.0.11 and admin >= 7.6.20
102
+ * [TASK] Test on Node.js 22.x, 24.x and 26.x, publish to npm via trusted publishing and update the Dependabot configuration
103
+
82
104
  ### 0.2.1 (2024-09-18)
83
105
  * (jb-io) bugfix missing dependencies
84
106
 
@@ -97,4 +119,4 @@ If you want to contribute have a look at the [Developer Guide](./doc/CONTRIBUTE.
97
119
 
98
120
  ## License
99
121
 
100
- [Licensed under GPLv3](LICENSE) Copyright (c) 2024 jb-io
122
+ [Licensed under GPLv3](LICENSE) Copyright (c) 2022-2026 jb-io
package/io-package.json CHANGED
@@ -1,8 +1,21 @@
1
1
  {
2
2
  "common": {
3
3
  "name": "keenergy",
4
- "version": "0.2.1",
4
+ "version": "0.3.0",
5
5
  "news": {
6
+ "0.3.0": {
7
+ "en": "[TASK] Harmonize project structure, tooling and tests\n[TASK] Require js-controller >= 6.0.11 and admin >= 7.6.20\n[TASK] Test on Node.js 22.x, 24.x and 26.x, publish to npm via trusted publishing and update the Dependabot configuration",
8
+ "de": "[TASK] Projektstruktur, Tools und Tests harmonisieren\n[TASK] JS-Controller >= 6.0.11 und Admin >= 7.6.20\n[TASK] Testen Sie auf Node.js 22.x, 24.x und 26.x, veröffentlichen Sie auf NPM und aktualisieren Sie Dependabot",
9
+ "ru": "[TASK] Согласование структуры проекта, инструментов и тестов\n[TASK] Требуется js-контроллер >= 6.0.11 и администратор >= 7.6.20\n[TASK] Протестируйте Node.js 22.x, 24.x и 26.x, опубликуйте в npm с помощью доверенной публикации и обновите конфигурацию Dependabot",
10
+ "pt": "[TASK] Harmonize projetos, ferramentas e testes\n[TASK] Exigir js-controller >= 6.0.11 e admin >= 7.6.20\n[TASK] Teste no Node.js 22.x, 24.x e 26.x, publique no npm via Trusted Publishing e atualize o Dependabot",
11
+ "nl": "[TASK] De projectstructuur, tools en tests harmoniseren\n[TASK] Vereist een js-controller >= 6.0.11 en admin >= 7.6.20\n[TASK] Test op Node.js 22.x, 24.x en 26.x, publiceer naar npm via Trusted Publishing en werk de Dependabot-configuratie bij",
12
+ "fr": "[TASK] Harmoniser le projet, l'outillage et les tests\n[TASK] Exige js-Controller version 6.0.11 et admin version 7.6.20\n[TASK] Testez Node.js 22.x, 24.x et 26.x, publiez sur npm via Trusted Publishing et mettez à jour la configuration Dependabot",
13
+ "it": "[TASK] Armonizzare struttura, strumenti e test\n[TASK] Richiede js-controller >= 6.0.11 e admin >= 7.6.20\n[TASK] Test su Node.js 22.x, 24.x e 26.x, pubblica su npm tramite Trusted Publishing e aggiorna la configurazione Dependabot",
14
+ "es": "[TASK] Armonizar la estructura, herramientas y pruebas del proyecto\n[TASK] Necesita js-controller >= 6.0.11 y admin >= 7.6.20\n[TASK] Probar en Node.js 22.x, 24.x y 26.x, publicar en npm mediante Trusted Publishing y actualizar la configuración del Dependabot",
15
+ "pl": "[TASK] Zharmonizuj strukturę projektu, oprzyrządowanie i testy\n[TASK] Wymagaj js-controller >= 6.0.11 i admin >= 7.6.20\n[TASK] Przetestuj na Node.js 22.x, 24.x i 26.x, opublikuj do npm poprzez zaufane publikowanie i zaktualizuj konfigurację Dependabot",
16
+ "uk": "[TASK] Гармонізувати структуру проекту, інструменти та тести\n[TASK] Потрібен js-контролер >= 6.0.11 і адміністратор> = 7.6.20\n[TASK] Тест на Node.js 22.x, 24.x та 26.x, публікуйте в npm через довірену публікацію та оновіть конфігурацію Dependabot",
17
+ "zh-cn": "[TASK] 协调项目结构、工具和测试\n[TASK] 需要 js-controller >= 6.0.11 和管理员 >= 7.6.20\n[TASK] 在 Node.js 22.x、24.x 和 26.x 上测试,通过可信发布到 npm 并更新 Dependabot 配置"
18
+ },
6
19
  "0.2.1": {
7
20
  "en": "bugfix missing dependencies",
8
21
  "de": "bugfix fehlende abhängigkeiten",
@@ -121,12 +134,12 @@
121
134
  },
122
135
  "dependencies": [
123
136
  {
124
- "js-controller": ">=5.0.0"
137
+ "js-controller": ">=6.0.11"
125
138
  }
126
139
  ],
127
140
  "globalDependencies": [
128
141
  {
129
- "admin": ">=6.0.0"
142
+ "admin": ">=7.6.20"
130
143
  }
131
144
  ]
132
145
  },
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "iobroker.keenergy",
3
- "version": "0.2.1",
3
+ "version": "0.3.0",
4
4
  "description": "Adapter for KEBA KeEnergy Web HMI - Remote Control",
5
5
  "author": {
6
6
  "name": "jb-io",
@@ -19,46 +19,46 @@
19
19
  "url": "git@github.com:jb-io/ioBroker.keenergy.git"
20
20
  },
21
21
  "engines": {
22
- "node": ">= 20"
22
+ "node": ">= 22"
23
23
  },
24
24
  "dependencies": {
25
25
  "@iobroker/adapter-core": "^3.1.6",
26
+ "@iobroker/types": "^7.2.2",
26
27
  "xmldom": "^0.6.0",
27
28
  "xpath.js": "^1.1.0"
28
29
  },
29
30
  "devDependencies": {
30
- "@alcalzone/release-script": "^3.8.0",
31
- "@alcalzone/release-script-plugin-iobroker": "^3.7.2",
32
- "@alcalzone/release-script-plugin-license": "^3.7.0",
33
- "@alcalzone/release-script-plugin-manual-review": "^3.7.0",
34
- "@iobroker/adapter-dev": "^1.3.0",
35
- "@iobroker/testing": "^4.1.3",
36
- "@iobroker/types": "^6.0.11",
37
- "@tsconfig/node20": "^20.1.4",
38
- "@types/chai": "^4.3.19",
39
- "@types/chai-as-promised": "^8.0.0",
31
+ "@alcalzone/release-script": "^5.2.1",
32
+ "@alcalzone/release-script-plugin-iobroker": "^5.2.0",
33
+ "@alcalzone/release-script-plugin-license": "^5.2.2",
34
+ "@alcalzone/release-script-plugin-manual-review": "^5.2.0",
35
+ "@iobroker/adapter-dev": "^1.5.0",
36
+ "@iobroker/eslint-config": "^2.3.4",
37
+ "@iobroker/testing": "^5.3.0",
38
+ "@tsconfig/node22": "^22.0.7",
39
+ "@types/chai": "^4.3.16",
40
+ "@types/chai-as-promised": "^7.1.8",
40
41
  "@types/lodash": "^4.17.7",
41
- "@types/mocha": "^10.0.7",
42
- "@types/node": "^20.16.5",
42
+ "@types/mocha": "^10.0.10",
43
+ "@types/node": "^22.20.7",
43
44
  "@types/proxyquire": "^1.3.31",
44
- "@types/sinon": "^17.0.3",
45
+ "@types/sinon": "^22.0.0",
45
46
  "@types/sinon-chai": "^3.2.12",
46
47
  "@types/xmldom": "^0.1.34",
47
- "@typescript-eslint/eslint-plugin": "^8.4.0",
48
- "@typescript-eslint/parser": "^8.4.0",
49
48
  "axios": "^1.7.7",
50
- "chai": "^4.5.0",
51
- "chai-as-promised": "^8.0.0",
52
- "eslint": "^9.10.0",
49
+ "chai": "^4.4.1",
50
+ "chai-as-promised": "^7.1.2",
51
+ "eslint": "^9.39.5",
53
52
  "lodash": "^4.17.21",
54
- "mocha": "^10.7.3",
53
+ "mocha": "^11.8.0",
54
+ "prettier": "^3.9.6",
55
55
  "proxyquire": "^2.1.3",
56
- "rimraf": "^6.0.1",
57
- "sinon": "^18.0.0",
56
+ "rimraf": "^6.1.3",
57
+ "sinon": "^22.1.0",
58
58
  "sinon-chai": "^3.7.0",
59
59
  "source-map-support": "^0.5.21",
60
60
  "ts-node": "^10.9.2",
61
- "typescript": "~5.6.2"
61
+ "typescript": "~5.9.3"
62
62
  },
63
63
  "main": "build/main.js",
64
64
  "files": [
@@ -76,12 +76,14 @@
76
76
  "prebuild:ts": "rimraf build",
77
77
  "build:ts": "build-adapter ts",
78
78
  "watch:ts": "build-adapter ts --watch",
79
- "test:ts": "mocha --config test/mocharc.custom.json src/**/*.test.ts",
79
+ "test:ts": "mocha --config test/mocharc.custom.json",
80
80
  "test:package": "mocha test/package --exit",
81
- "test:integration": "mocha test/integration --exit",
81
+ "test:integration": "mocha test/integration.js --exit",
82
82
  "test": "npm run test:ts && npm run test:package",
83
83
  "check": "tsc --noEmit",
84
- "lint": "eslint --ext .ts src/",
84
+ "lint": "eslint .",
85
+ "lint:fix": "eslint . --fix",
86
+ "format": "prettier --write .",
85
87
  "translate": "translate-adapter",
86
88
  "release": "release-script"
87
89
  },