iobroker.zigbee2mqtt 2.10.1 → 2.11.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/README.md CHANGED
@@ -32,14 +32,23 @@ This adapter allows to control the data points of the devices of a Zigbee2MQTT i
32
32
  Placeholder for the next version (at the beginning of the line):
33
33
  ### **WORK IN PROGRESS**
34
34
  -->
35
+ ### 2.11.0 (2023-08-24)
36
+
37
+ - (o0shojo0o) added automatic download of device image from zigbee2mqtt to meta-storage
38
+ - (o0shojo0o) added option `Download device images from Zigbee2Mqtt and use them as object icons.`
39
+ - (o0shojo0o) fixed Hue_Move
40
+ - (o0shojo0o) added option `Generate simple 'Hold' and 'Release' states`
41
+ - (o0shojo0o) added option `Generate simple 'Move' and 'Stop' states`
42
+ - (o0shojo0o) added option `Generate simple 'Press' and 'Release' states`
43
+
35
44
  ### 2.10.1 (2023-08-13)
36
45
 
37
- - (o0shojo0o) fix type definitions (thx @arteck)
46
+ - (o0shojo0o) fixed type definitions (thx @arteck)
38
47
 
39
48
  ### 2.10.0 (2023-08-12)
40
49
 
41
50
  - (o0shojo0o) optimisation for the MQTT connection
42
- - (o0shojo0o) fix for MQTT output type: attribute_and_json ([#87](https://github.com/o0shojo0o/ioBroker.zigbee2mqtt/issues/87))
51
+ - (o0shojo0o) fixed for MQTT output type: attribute_and_json ([#87](https://github.com/o0shojo0o/ioBroker.zigbee2mqtt/issues/87))
43
52
  - (o0shojo0o) added support for external MQTT-Server credentials ([#148](https://github.com/o0shojo0o/ioBroker.zigbee2mqtt/issues/148))
44
53
  - *After update, Websocket Auth-Token must be set again, if used.*
45
54
 
@@ -58,7 +67,7 @@ This adapter allows to control the data points of the devices of a Zigbee2MQTT i
58
67
 
59
68
  ### 2.7.4 (2023-03-05)
60
69
 
61
- - (o0shojo0o) fix for Aqara presence detector FP1 `reset_nopresence_status`
70
+ - (o0shojo0o) fixed for Aqara presence detector FP1 `reset_nopresence_status`
62
71
 
63
72
  ### 2.7.3 (2023-02-18)
64
73
 
@@ -85,7 +94,7 @@ This adapter allows to control the data points of the devices of a Zigbee2MQTT i
85
94
  - (o0shojo0o) added state `transition` for transition overwrite (-1 disabled overwrite) ([#101](https://github.com/o0shojo0o/ioBroker.zigbee2mqtt/issues/101))
86
95
  - (o0shojo0o) consideration of the description when creating the friendly name ([#105](https://github.com/o0shojo0o/ioBroker.zigbee2mqtt/issues/105))
87
96
  - (o0shojo0o) added state `effect` for groups ([#101](https://github.com/o0shojo0o/ioBroker.zigbee2mqtt/issues/101))
88
- - (o0shojo0o) fix state contact
97
+ - (o0shojo0o) fixed state contact
89
98
  - (o0shojo0o) added handling for disabled devices
90
99
 
91
100
  ### 2.5.0 (2023-01-02)
@@ -104,20 +113,20 @@ This adapter allows to control the data points of the devices of a Zigbee2MQTT i
104
113
 
105
114
  ### 2.4.3 (2022-11-23)
106
115
 
107
- - (o0shojo0o) fix availability when `friendly_name` `/` contains
116
+ - (o0shojo0o) fixed availability when `friendly_name` `/` contains
108
117
 
109
118
  ### 2.4.2 (2022-11-20)
110
119
 
111
120
  - (o0shojo0o) added correct handling of `move_to_saturation`, `hue_move` and `brightness_move_to_level` ([#68](https://github.com/o0shojo0o/ioBroker.zigbee2mqtt/issues/68))
112
- - (o0shojo0o) fix when `friendly_name` `/` contains
121
+ - (o0shojo0o) fixed when `friendly_name` `/` contains
113
122
 
114
123
  ### 2.4.1 (2022-11-16)
115
124
 
116
- - (o0shojo0o) fix based on [review](https://github.com/ioBroker/ioBroker.repositories/pull/1976#issuecomment-1316656378)
125
+ - (o0shojo0o) fixed based on [review](https://github.com/ioBroker/ioBroker.repositories/pull/1976#issuecomment-1316656378)
117
126
 
118
127
  ### 2.4.0 (2022-11-08)
119
128
 
120
- - (o0shojo0o) fix for devices with multiple endpoints ([#57](https://github.com/o0shojo0o/ioBroker.zigbee2mqtt/issues/57)).
129
+ - (o0shojo0o) fixed for devices with multiple endpoints ([#57](https://github.com/o0shojo0o/ioBroker.zigbee2mqtt/issues/57)).
121
130
  - (o0shojo0o) added option `Brightness move should also turn the light on or off`
122
131
  - (o0shojo0o) added state toggle for groups
123
132
  - (o0shojo0o) more dynamic during data point creation ([#48](https://github.com/o0shojo0o/ioBroker.zigbee2mqtt/issues/48)).
@@ -129,9 +138,9 @@ This adapter allows to control the data points of the devices of a Zigbee2MQTT i
129
138
 
130
139
  ### 2.2.1 (2022-10-25)
131
140
 
132
- - (o0shojo0o) fix state roles and access
133
- - (o0shojo0o) fix state handling
134
- - (o0shojo0o) fix createZ2MMessage
141
+ - (o0shojo0o) fixed state roles and access
142
+ - (o0shojo0o) fixed state handling
143
+ - (o0shojo0o) fixed createZ2MMessage
135
144
 
136
145
  ### 2.2.0 (2022-10-20)
137
146
 
@@ -147,7 +156,7 @@ This adapter allows to control the data points of the devices of a Zigbee2MQTT i
147
156
  ### 2.1.0 (2022-10-14)
148
157
 
149
158
  - (o0shojo0o) added option for color temperature sync with color
150
- - (o0shojo0o) fix logfilter and debugDevices
159
+ - (o0shojo0o) fixed logfilter and debugDevices
151
160
  - (o0shojo0o) lots of bugfixes
152
161
  - (o0shojo0o) now set the correct min/max at color temp
153
162
  - (o0shojo0o) better error handling for the connections
@@ -186,8 +195,8 @@ This adapter allows to control the data points of the devices of a Zigbee2MQTT i
186
195
  - (arteck) added debugmessage for specific device functionality
187
196
  - (arteck) added some states are default false
188
197
  - (o0shojo0o) added support for scenes defined on a device
189
- - (o0shojo0o) fix available state role
190
- - (o0shojo0o) fix subscribeWritableStates
198
+ - (o0shojo0o) fixed available state role
199
+ - (o0shojo0o) fixed edsubscribeWritableStates
191
200
 
192
201
  ### 0.1.0 (2022-09-29)
193
202
 
@@ -29,5 +29,13 @@
29
29
  "Scheme": "Scheme",
30
30
  "Use MQTT Credentials": "MQTT-Anmeldeinformationen verwenden",
31
31
  "MQTT Username": "MQTT-Benutzername",
32
- "MQTT Password": "MQTT-Passwort"
33
- }
32
+ "MQTT Password": "MQTT-Passwort",
33
+ "Download device images from Zigbee2Mqtt and use them as object icons.": "Device Bilder von Zigbee2Mqtt herunterladen und als Objektsymbole verwenden.",
34
+ "Generate simple 'Hold' and 'Release' states": "Generiert einfache „Hold“ und „Release“ States",
35
+ "When enabled, the 'Hold' and 'Release' states are combined and the 'Hold' data point remains true until the 'Release' event arrives.": "Bei Aktivierung werden die Datenpunkte „Hold“ und „Release“ kombiniert und der Datenpunkt „Hold“ bleibt true, bis das Ereignis „Release“ eintrifft.",
36
+ "Generate simple 'Move' and 'Stop' states": "Generiert einfache „Move“ und „Stop“ States",
37
+ "When enabled, the 'Move' and 'Stop' states are combined and the 'Move' data point remains true until the 'Stop' event arrives.": "Bei Aktivierung werden die Datenpunkte „Move“ und „Stop“ kombiniert und der Datenpunkt „Move“ bleibt true, bis das Ereignis „Stop“ eintrifft.",
38
+ "State configurations": "State konfigurationen",
39
+ "Generate simple 'Press' and 'Release' states": "Generieren einfache „Press“ und „Release“ States",
40
+ "When enabled, the 'Press' and 'Release' states are combined and the 'Press' data point remains true until the 'Release' event arrives.": "Wenn diese Option aktiviert ist, werden die Zustände „Press“ und „Release“ kombiniert und der Datenpunkt „Press“ bleibt true, bis das Ereignis „Release“ eintrifft."
41
+ }
@@ -29,5 +29,13 @@
29
29
  "Scheme": "Scheme",
30
30
  "Use MQTT Credentials": "Use MQTT Credentials",
31
31
  "MQTT Username": "MQTT Username",
32
- "MQTT Password": "MQTT Password"
32
+ "MQTT Password": "MQTT Password",
33
+ "Download device images from Zigbee2Mqtt and use them as object icons.": "Download device images from Zigbee2Mqtt and use them as object icons.",
34
+ "Generate simple 'Hold' and 'Release' states": "Generate simple 'Hold' and 'Release' states",
35
+ "When enabled, the 'Hold' and 'Release' states are combined and the 'Hold' data point remains true until the 'Release' event arrives.": "When enabled, the 'Hold' and 'Release' states are combined and the 'Hold' data point remains true until the 'Release' event arrives.",
36
+ "Generate simple 'Move' and 'Stop' states": "Generate simple 'Move' and 'Stop' states",
37
+ "When enabled, the 'Move' and 'Stop' states are combined and the 'Move' data point remains true until the 'Stop' event arrives.": "When enabled, the 'Move' and 'Stop' states are combined and the 'Move' data point remains true until the 'Stop' event arrives.",
38
+ "State configurations": "State configurations",
39
+ "Generate simple 'Press' and 'Release' states": "Generate simple 'Press' and 'Release' states",
40
+ "When enabled, the 'Press' and 'Release' states are combined and the 'Press' data point remains true until the 'Release' event arrives.": "When enabled, the 'Press' and 'Release' states are combined and the 'Press' data point remains true until the 'Release' event arrives."
33
41
  }
@@ -29,5 +29,13 @@
29
29
  "Scheme": "Esquema",
30
30
  "Use MQTT Credentials": "Usar credenciales MQTT",
31
31
  "MQTT Username": "Nombre de usuario MQTT",
32
- "MQTT Password": "Contraseña MQTT"
32
+ "MQTT Password": "Contraseña MQTT",
33
+ "Download device images from Zigbee2Mqtt and use them as object icons.": "Descargue imágenes de dispositivos de Zigbee2Mqtt y utilícelas como íconos de objetos.",
34
+ "Generate simple 'Hold' and 'Release' states": "Genere estados simples de 'Retener' y 'Liberar'",
35
+ "When enabled, the 'Hold' and 'Release' states are combined and the 'Hold' data point remains true until the 'Release' event arrives.": "Cuando está habilitado, los estados 'Retener' y 'Liberar' se combinan y el punto de datos 'Retener' permanece verdadero hasta que llega el evento 'Liberar'.",
36
+ "Generate simple 'Move' and 'Stop' states": "Genere estados simples de 'Mover' y 'Detener'",
37
+ "When enabled, the 'Move' and 'Stop' states are combined and the 'Move' data point remains true until the 'Stop' event arrives.": "Cuando está habilitado, los estados 'Mover' y 'Detener' se combinan y el punto de datos 'Mover' permanece verdadero hasta que llega el evento 'Detener'.",
38
+ "State configurations": "Configuraciones de estado",
39
+ "Generate simple 'Press' and 'Release' states": "Genere estados simples de \"Presionar\" y \"Liberar\"",
40
+ "When enabled, the 'Press' and 'Release' states are combined and the 'Press' data point remains true until the 'Release' event arrives.": "Cuando está habilitado, los estados \"Presionar\" y \"Liberar\" se combinan y el punto de datos \"Presionar\" permanece verdadero hasta que llega el evento \"Liberar\"."
33
41
  }
@@ -29,5 +29,13 @@
29
29
  "Scheme": "Schème",
30
30
  "Use MQTT Credentials": "Utiliser les identifiants MQTT",
31
31
  "MQTT Username": "Nom d'utilisateur MQTT",
32
- "MQTT Password": "Mot de passe MQTT"
32
+ "MQTT Password": "Mot de passe MQTT",
33
+ "Download device images from Zigbee2Mqtt and use them as object icons.": "Téléchargez des images d'appareils à partir de Zigbee2Mqtt et utilisez-les comme icônes d'objets.",
34
+ "Generate simple 'Hold' and 'Release' states": "Générer des états simples 'Hold' et 'Release'",
35
+ "When enabled, the 'Hold' and 'Release' states are combined and the 'Hold' data point remains true until the 'Release' event arrives.": "Lorsqu'il est activé, les états 'Hold' et 'Release' sont combinés et le point de données 'Hold' reste vrai jusqu'à ce que l'événement 'Release' arrive.",
36
+ "Generate simple 'Move' and 'Stop' states": "Générer des états simples 'Move' et 'Stop'",
37
+ "When enabled, the 'Move' and 'Stop' states are combined and the 'Move' data point remains true until the 'Stop' event arrives.": "Lorsqu'il est activé, les états 'Move' et 'Stop' sont combinés et le point de données 'Move' reste vrai jusqu'à ce que l'événement 'Stop' arrive.",
38
+ "State configurations": "Configurations d'état",
39
+ "Generate simple 'Press' and 'Release' states": "Générer des états simples « Presser » et « Relâcher »",
40
+ "When enabled, the 'Press' and 'Release' states are combined and the 'Press' data point remains true until the 'Release' event arrives.": "Lorsqu'ils sont activés, les états « Press » et « Release » sont combinés et le point de données « Press » reste vrai jusqu'à ce que l'événement « Release » arrive."
33
41
  }
@@ -29,5 +29,13 @@
29
29
  "Scheme": "schema",
30
30
  "Use MQTT Credentials": "Usa le credenziali MQTT",
31
31
  "MQTT Username": "Nome utente MQTT",
32
- "MQTT Password": "Password MQTT"
32
+ "MQTT Password": "Password MQTT",
33
+ "Download device images from Zigbee2Mqtt and use them as object icons.": "Scarica le immagini del dispositivo da Zigbee2Mqtt e usale come icone degli oggetti.",
34
+ "Generate simple 'Hold' and 'Release' states": "Genera semplici stati \"Hold\" e \"Release\".",
35
+ "When enabled, the 'Hold' and 'Release' states are combined and the 'Hold' data point remains true until the 'Release' event arrives.": "Se abilitato, gli stati \"Hold\" e \"Release\" vengono combinati e il punto dati \"Hold\" rimane vero fino all'arrivo dell'evento \"Release\".",
36
+ "Generate simple 'Move' and 'Stop' states": "Genera semplici stati 'Move' e 'Stop'",
37
+ "When enabled, the 'Move' and 'Stop' states are combined and the 'Move' data point remains true until the 'Stop' event arrives.": "Se abilitato, gli stati 'Move' e 'Stop' vengono combinati e il punto dati 'Move' rimane vero fino all'arrivo dell'evento 'Stop'.",
38
+ "State configurations": "Configurazioni di stato",
39
+ "Generate simple 'Press' and 'Release' states": "Genera semplici stati \"Stampa\" e \"Rilascio\".",
40
+ "When enabled, the 'Press' and 'Release' states are combined and the 'Press' data point remains true until the 'Release' event arrives.": "Se abilitati, gli stati \"Press\" e \"Rilascio\" vengono combinati e il punto dati \"Press\" rimane vero fino all'arrivo dell'evento \"Rilascio\"."
33
41
  }
@@ -29,5 +29,13 @@
29
29
  "Scheme": "Schema",
30
30
  "Use MQTT Credentials": "Gebruik MQTT-referenties",
31
31
  "MQTT Username": "MQTT-gebruikersnaam",
32
- "MQTT Password": "MQTT-wachtwoord"
32
+ "MQTT Password": "MQTT-wachtwoord",
33
+ "Download device images from Zigbee2Mqtt and use them as object icons.": "Download apparaatafbeeldingen van Zigbee2Mqtt en gebruik ze als objectpictogrammen.",
34
+ "Generate simple 'Hold' and 'Release' states": "Genereer eenvoudige 'Hold' en 'Release' statussen",
35
+ "When enabled, the 'Hold' and 'Release' states are combined and the 'Hold' data point remains true until the 'Release' event arrives.": "Indien ingeschakeld, worden de toestanden 'Hold' en 'Release' gecombineerd en blijft het datapunt 'Hold' waar totdat de 'Release'-gebeurtenis arriveert.",
36
+ "Generate simple 'Move' and 'Stop' states": "Genereer eenvoudige 'Move' en 'Stop' toestanden",
37
+ "When enabled, the 'Move' and 'Stop' states are combined and the 'Move' data point remains true until the 'Stop' event arrives.": "Indien ingeschakeld, worden de toestanden 'Verplaatsen' en 'Stop' gecombineerd en blijft het gegevenspunt 'Verplaatsen' waar totdat de gebeurtenis 'Stop' arriveert.",
38
+ "State configurations": "Staat configuraties",
39
+ "Generate simple 'Press' and 'Release' states": "Genereer eenvoudige 'Druk'- en 'loslaat'-statussen",
40
+ "When enabled, the 'Press' and 'Release' states are combined and the 'Press' data point remains true until the 'Release' event arrives.": "Indien ingeschakeld, worden de statussen 'Press' en 'Release' gecombineerd en blijft het datapunt 'Press' waar totdat de gebeurtenis 'Release' arriveert."
33
41
  }
@@ -29,5 +29,13 @@
29
29
  "Scheme": "Schemat",
30
30
  "Use MQTT Credentials": "Użyj poświadczeń MQTT",
31
31
  "MQTT Username": "Nazwa użytkownika MQTT",
32
- "MQTT Password": "Hasło MQTT"
32
+ "MQTT Password": "Hasło MQTT",
33
+ "Download device images from Zigbee2Mqtt and use them as object icons.": "Pobierz obrazy urządzeń z Zigbee2Mqtt i użyj ich jako ikon obiektów.",
34
+ "Generate simple 'Hold' and 'Release' states": "Generuj proste stany „Wstrzymaj” i „Zwolnij”.",
35
+ "When enabled, the 'Hold' and 'Release' states are combined and the 'Hold' data point remains true until the 'Release' event arrives.": "Po włączeniu stany „Wstrzymaj” i „Zwolnij” są łączone, a punkt danych „Wstrzymaj” pozostaje prawdziwy do momentu nadejścia zdarzenia „Zwolnij”.",
36
+ "Generate simple 'Move' and 'Stop' states": "Generuj proste stany „Przenieś” i „Zatrzymaj”.",
37
+ "When enabled, the 'Move' and 'Stop' states are combined and the 'Move' data point remains true until the 'Stop' event arrives.": "Po włączeniu stany „Przenieś” i „Zatrzymaj” są łączone, a punkt danych „Przenieś” pozostaje prawdziwy do momentu nadejścia zdarzenia „Zatrzymaj”.",
38
+ "State configurations": "Konfiguracje stanów",
39
+ "Generate simple 'Press' and 'Release' states": "Generuj proste stany „Naciśnij” i „Zwolnij”.",
40
+ "When enabled, the 'Press' and 'Release' states are combined and the 'Press' data point remains true until the 'Release' event arrives.": "Po włączeniu stany „Naciśnij” i „Zwolnij” są łączone, a punkt danych „Naciśnij” pozostaje prawdziwy do momentu pojawienia się zdarzenia „Zwolnij”."
33
41
  }
@@ -29,5 +29,13 @@
29
29
  "Scheme": "Esquema",
30
30
  "Use MQTT Credentials": "Usar credenciais MQTT",
31
31
  "MQTT Username": "Nome de usuário MQTT",
32
- "MQTT Password": "Senha do MQTT"
32
+ "MQTT Password": "Senha do MQTT",
33
+ "Download device images from Zigbee2Mqtt and use them as object icons.": "Baixe imagens de dispositivos do Zigbee2Mqtt e use-as como ícones de objetos.",
34
+ "Generate simple 'Hold' and 'Release' states": "Gerar estados simples 'Hold' e 'Release'",
35
+ "When enabled, the 'Hold' and 'Release' states are combined and the 'Hold' data point remains true until the 'Release' event arrives.": "Quando ativado, os estados 'Hold' e 'Release' são combinados e o ponto de dados 'Hold' permanece verdadeiro até que o evento 'Release' chegue.",
36
+ "Generate simple 'Move' and 'Stop' states": "Gerar estados simples 'Mover' e 'Parar'",
37
+ "When enabled, the 'Move' and 'Stop' states are combined and the 'Move' data point remains true until the 'Stop' event arrives.": "Quando ativado, os estados 'Mover' e 'Parar' são combinados e o ponto de dados 'Mover' permanece verdadeiro até que o evento 'Parar' chegue.",
38
+ "State configurations": "configurações de estado",
39
+ "Generate simple 'Press' and 'Release' states": "Gere estados simples de 'Pressionar' e 'Liberar'",
40
+ "When enabled, the 'Press' and 'Release' states are combined and the 'Press' data point remains true until the 'Release' event arrives.": "Quando ativado, os estados 'Press' e 'Release' são combinados e o ponto de dados 'Press' permanece verdadeiro até que o evento 'Release' chegue."
33
41
  }
@@ -29,5 +29,13 @@
29
29
  "Scheme": "Схема",
30
30
  "Use MQTT Credentials": "Используйте учетные данные MQTT",
31
31
  "MQTT Username": "Имя пользователя MQTT",
32
- "MQTT Password": "MQTT-пароль"
32
+ "MQTT Password": "MQTT-пароль",
33
+ "Download device images from Zigbee2Mqtt and use them as object icons.": "Загрузите изображения устройств с Zigbee2Mqtt и используйте их в качестве значков объектов.",
34
+ "Generate simple 'Hold' and 'Release' states": "Создавайте простые состояния «Hold» и «Release»",
35
+ "When enabled, the 'Hold' and 'Release' states are combined and the 'Hold' data point remains true until the 'Release' event arrives.": "Когда эта функция включена, состояния «Hold» и «Release» объединяются, а точка данных «Hold» остается истинной до тех пор, пока не наступит событие «Release».",
36
+ "Generate simple 'Move' and 'Stop' states": "Создавайте простые состояния «Переместить» и «Стоп»",
37
+ "When enabled, the 'Move' and 'Stop' states are combined and the 'Move' data point remains true until the 'Stop' event arrives.": "Когда эта функция включена, состояния «Перемещение» и «Стоп» объединяются, и точка данных «Перемещение» остается истинной до тех пор, пока не наступит событие «Стоп».",
38
+ "State configurations": "Конфигурации состояния",
39
+ "Generate simple 'Press' and 'Release' states": "Создавайте простые состояния «Нажмите» и «Отпустите».",
40
+ "When enabled, the 'Press' and 'Release' states are combined and the 'Press' data point remains true until the 'Release' event arrives.": "Если этот параметр включен, состояния «Нажатие» и «Отпуск» объединяются, и точка данных «Нажатие» остается истинной до тех пор, пока не произойдет событие «Отпуск»."
33
41
  }
@@ -29,5 +29,13 @@
29
29
  "Scheme": "Схема",
30
30
  "Use MQTT Credentials": "Використовуйте облікові дані MQTT",
31
31
  "MQTT Username": "Ім'я користувача MQTT",
32
- "MQTT Password": "Пароль MQTT"
32
+ "MQTT Password": "Пароль MQTT",
33
+ "Download device images from Zigbee2Mqtt and use them as object icons.": "Завантажуйте зображення пристроїв із Zigbee2Mqtt і використовуйте їх як значки об’єктів.",
34
+ "Generate simple 'Hold' and 'Release' states": "Створюйте прості стани «Утримувати» та «Відпускати».",
35
+ "When enabled, the 'Hold' and 'Release' states are combined and the 'Hold' data point remains true until the 'Release' event arrives.": "Якщо ввімкнено, стани «Утримувати» та «Вивільнити» об’єднуються, а точка даних «Утримувати» залишається істинною, доки не надійде подія «Вивільнення».",
36
+ "Generate simple 'Move' and 'Stop' states": "Створення простих станів «Переміщення» та «Зупинка».",
37
+ "When enabled, the 'Move' and 'Stop' states are combined and the 'Move' data point remains true until the 'Stop' event arrives.": "Якщо ввімкнено, стани «Переміщення» та «Зупинити» поєднуються, а точка даних «Переміщення» залишається істинною, доки не надійде подія «Зупинити».",
38
+ "State configurations": "Конфігурації стану",
39
+ "Generate simple 'Press' and 'Release' states": "Створення простих станів «Натиснути» та «Випустити».",
40
+ "When enabled, the 'Press' and 'Release' states are combined and the 'Press' data point remains true until the 'Release' event arrives.": "Якщо ввімкнено, стани «Натиснути» та «Випустити» поєднуються, а точка даних «Натиснути» залишається істинною, доки не надійде подія «Випуск»."
33
41
  }
@@ -29,5 +29,13 @@
29
29
  "Scheme": "方案",
30
30
  "Use MQTT Credentials": "使用 MQTT 凭证",
31
31
  "MQTT Username": "MQTT 用户名",
32
- "MQTT Password": "MQTT 密码"
32
+ "MQTT Password": "MQTT 密码",
33
+ "Download device images from Zigbee2Mqtt and use them as object icons.": "从 Zigbee2Mqtt 下载设备图像并将其用作对象图标。",
34
+ "Generate simple 'Hold' and 'Release' states": "生成简单的“保持”和“释放”状态",
35
+ "When enabled, the 'Hold' and 'Release' states are combined and the 'Hold' data point remains true until the 'Release' event arrives.": "启用后,“保持”和“释放”状态会结合在一起,并且“保持”数据点保持为真,直到“释放”事件到达。",
36
+ "Generate simple 'Move' and 'Stop' states": "生成简单的“移动”和“停止”状态",
37
+ "When enabled, the 'Move' and 'Stop' states are combined and the 'Move' data point remains true until the 'Stop' event arrives.": "启用后,“移动”和“停止”状态将组合在一起,并且“移动”数据点保持为真,直到“停止”事件到达。",
38
+ "State configurations": "状态配置",
39
+ "Generate simple 'Press' and 'Release' states": "生成简单的“按下”和“释放”状态",
40
+ "When enabled, the 'Press' and 'Release' states are combined and the 'Press' data point remains true until the 'Release' event arrives.": "启用后,“按下”和“释放”状态将组合在一起,并且“按下”数据点保持为真,直到“释放”事件到达。"
33
41
  }
@@ -186,6 +186,30 @@
186
186
  "label": "Use Kelvin instead of mired for the color temps",
187
187
  "newLine": true
188
188
  },
189
+ "stateHeader": {
190
+ "type": "header",
191
+ "text": "State configurations",
192
+ "size": 2,
193
+ "newLine": true
194
+ },
195
+ "simpleHoldReleaseState": {
196
+ "type": "checkbox",
197
+ "label": "Generate simple 'Hold' and 'Release' states",
198
+ "help": "When enabled, the 'Hold' and 'Release' states are combined and the 'Hold' data point remains true until the 'Release' event arrives.",
199
+ "newLine": true
200
+ },
201
+ "simpleMoveStopState": {
202
+ "type": "checkbox",
203
+ "label": "Generate simple 'Move' and 'Stop' states",
204
+ "help": "When enabled, the 'Move' and 'Stop' states are combined and the 'Move' data point remains true until the 'Stop' event arrives.",
205
+ "newLine": true
206
+ },
207
+ "simplePressReleaseState": {
208
+ "type": "checkbox",
209
+ "label": "Generate simple 'Press' and 'Release' states",
210
+ "help": "When enabled, the 'Press' and 'Release' states are combined and the 'Press' data point remains true until the 'Release' event arrives.",
211
+ "newLine": true
212
+ },
189
213
  "otherHeader": {
190
214
  "type": "header",
191
215
  "text": "Other configurations",
@@ -211,6 +235,11 @@
211
235
  "type": "checkbox",
212
236
  "label": "The events such as 'Device removed' or 'Disabled' are displayed in the description instead of in the name.",
213
237
  "newLine": true
238
+ },
239
+ "useDeviceIcons": {
240
+ "type": "checkbox",
241
+ "label": "Download device images from Zigbee2Mqtt and use them as object icons.",
242
+ "newLine": true
214
243
  }
215
244
  }
216
245
  }
package/io-package.json CHANGED
@@ -1,8 +1,21 @@
1
1
  {
2
2
  "common": {
3
3
  "name": "zigbee2mqtt",
4
- "version": "2.10.1",
4
+ "version": "2.11.0",
5
5
  "news": {
6
+ "2.11.0": {
7
+ "en": "added automatic download of device image from zigbee2mqtt to meta-storage\nadded option `Download device images from Zigbee2Mqtt and use them as object icons.`\nfixed Hue_Move \nadded option `Generate simple 'Hold' and 'Release' states`\nadded option `Generate simple 'Move' and 'Stop' states`\nadded option `Generate simple 'Press' and 'Release' states`",
8
+ "de": "automatischer download des gerätebildes von zigbee2mqtt zu meta-storage\n` Gerätebilder von Zigbee2Mqtt herunterladen und als Objektsymbole verwenden. `\nhue_Move\nzusatzoption `Generieren Sie einfache Halte- und Freigabezustände `\nzusätzliche Option `Generieren Sie einfache Verschiebe- und Stopp-Zustände `\nzusätzliche Option `Generieren Sie einfache Presse- und Freigabezustände `",
9
+ "ru": "добавлена автоматическая загрузка изображения устройства от zigbee2mqtt до meta-storage\nдобавлена опция `Скачать изображения устройства от Zigbee2Mqtt и использовать их как иконки объекта. »\nфиксированный Hue_Move\nдобавлена опция `Generate simple Hold and Release состояния »\nдобавлена опция `Generate simple Move and Stop состояния`\nдобавлена опция `Generate simple Press and Release состояния »",
10
+ "pt": "adicionado download automático da imagem do dispositivo de zigbee2mqtt para meta-armazenagem\nopção adicionada `Baixar imagens de dispositivo de Zigbee2Mqtt e usá-las como ícones de objeto. \"\nfixo Hue_Move\nopção adicionada `Gerar simples Hold and Release states \"\nopção adicionada `Gerar simples Mover e parar estados`\nopção adicionada `Gerar estados simples de imprensa e lançamento \"",
11
+ "nl": "voegde automatische download van het apparaat van zigbee2mqt toe aan meta-storage\nvoegde optie 'Download apparatuur van Zigbee2Mqt toe en gebruik ze als object iconen. _\nvertaling:\nvoegde optie 'Generate Sim Hold and Release staten _\nvoegde optie \"Generate Sim Move and Stop states\"\nvoegde optie 'Generate Sim Press and Release staten _",
12
+ "fr": "téléchargement automatique de l'image de périphérique de zigbee2mqt à meta-storage\noption ajoutée `Télécharger les images de périphérique de Zigbee2Mqt et les utiliser comme des icônes d'objet. `\nhue_Move\noption ajoutée `Generate simple Hold and Release états `\noption ajoutée `Generate simple Déplacer et arrêter les états`\noption ajoutée `Generate simple Press et les états de publication `",
13
+ "it": "download automatico dell'immagine del dispositivo da zigbee2mqt a meta-storage\nopzione aggiunta `Scaricare le immagini del dispositivo da Zigbee2Mqt e usarle come icone dell'oggetto. #\nfisso Hue_Move\nopzione aggiunta `Generate simple Hold and Release stati #\nopzione aggiunta `Generate simple Move and Stop stati`\nopzione aggiunta `Generate simple Press and Release stati #",
14
+ "es": "añadido descarga automática de la imagen del dispositivo desde zigbee2mqt a meta-storage\nopción agregada `Descargar imágenes de dispositivo de Zigbee2Mqtt y utilizarlas como iconos de objetos. `\nhue_Move fijo\nopción agregada `Generate simple Hold and Release states `\nopción agregada `Generate simple Move and Stop states`\nopción agregada `Generate simple Estados de prensa y liberación `",
15
+ "pl": "dodał automatyczny pobranie obrazu zigbee2mqtt na meta-storage\ndodał dodatki do opcjonalnych zdjęć z Zigbee2Mqtt i używał ich jako ikon obiektowych. `\nugruntowany\ndodano opcjonalne stany Hold i Release. `\ndodano możliwość generowanego prostego Move'a i Stop states'\ndodał opcję \"Generate simple Press and Release states\". `",
16
+ "uk": "додано автоматичне завантаження зображення пристрою з zigbee2mqtt до мета-сторage\nдодано опцію `Завантажити зображення пристроїв з Zigbee2Mqtt і використовувати їх як іконки об'єкта. й\nфіксована Hue_Move\nдодано варіант `Generate simple Hold and Release State й\nдодано варіант `Generate Simple Move and Stop State`\nдодано варіант `Generate simple Press and Release State й",
17
+ "zh-cn": "加上自齐格贝德二米克特自动下载器图像\n添加了“Zigbee2Mqt的载荷装置图像”的备选办法,并将这些图像作为目标。 目 录\n固定的He_Move\n增加“简单的霍乱和释放国”的选择 目 录\n增加“简单的摩托和托儿”\n增加的“简单新闻”选择 目 录"
18
+ },
6
19
  "2.10.1": {
7
20
  "en": "fix type definitions (thx @arteck)",
8
21
  "de": "fix typdefinitionen (thx @arteck)",
@@ -80,19 +93,6 @@
80
93
  "pl": "reset_nopresence_status (ang.)",
81
94
  "uk": "фіксація для датчика присутності Aqara FP1 скидання_nopresence_status",
82
95
  "zh-cn": "fix Aqara存在探测器FP1 重新定位_nopreence_status"
83
- },
84
- "2.7.3": {
85
- "en": "hotfix for Aqara presence detector FP1",
86
- "de": "hotfix für Aqara Präsenzmelder FP1",
87
- "ru": "hotfix для детектора присутствия Aqara FP1",
88
- "pt": "hotfix para detector de presença Aqara FP1",
89
- "nl": "quality over Quanteur FP1",
90
- "fr": "hotfix pour détecteur de présence Aqara FP1",
91
- "it": "hotfix per rilevatore di presenza Aqara FP1",
92
- "es": "hotfix para detector de presencia Aqara FP1",
93
- "pl": "hotfix",
94
- "uk": "hotfix для датчика присутності Aqara FP1",
95
- "zh-cn": "aqara存在侦查员FP1"
96
96
  }
97
97
  },
98
98
  "messages": [
@@ -247,7 +247,11 @@
247
247
  "colorTempSyncColor": false,
248
248
  "brightnessMoveOnOff": false,
249
249
  "brightnessStepOnOff": false,
250
- "useEventInDesc": true
250
+ "useEventInDesc": true,
251
+ "useDeviceIcons": false,
252
+ "simpleHoldReleaseState": true,
253
+ "simpleMoveStopState": false,
254
+ "simplePressReleaseState": false
251
255
  },
252
256
  "protectedNative": [
253
257
  "externalMqttServerPassword",
@@ -303,6 +307,27 @@
303
307
  "def": ""
304
308
  },
305
309
  "native": {}
310
+ },
311
+ {
312
+ "_id": "",
313
+ "type": "meta",
314
+ "common": {
315
+ "name": {
316
+ "en": "File storage",
317
+ "de": "Dateispeicher",
318
+ "ru": "Хранение файлов",
319
+ "pt": "Armazenamento de arquivos",
320
+ "nl": "Veldopslag",
321
+ "fr": "Stockage de fichiers",
322
+ "it": "Archiviazione file",
323
+ "es": "Almacenamiento de archivos",
324
+ "pl": "Storage room",
325
+ "uk": "Зберігання файлів",
326
+ "zh-cn": "储存"
327
+ },
328
+ "type": "meta.user"
329
+ },
330
+ "native": {}
306
331
  }
307
332
  ]
308
333
  }
@@ -3,6 +3,7 @@ const createDeviceFromExposes = require('./exposes').createDeviceFromExposes;
3
3
  const utils = require('./utils');
4
4
  const colors = require('./colors.js');
5
5
  const rgb = require('./rgb.js');
6
+ const ImageController = require('./imageController').ImageController;
6
7
 
7
8
  class DeviceController {
8
9
  constructor(adapter, deviceCache, groupCache, config, logCustomizations, createCache) {
@@ -12,9 +13,10 @@ class DeviceController {
12
13
  this.config = config;
13
14
  this.logCustomizations = logCustomizations;
14
15
  this.createCache = createCache;
16
+ this.imageController = new ImageController(adapter);
15
17
  }
16
18
 
17
- createDeviceDefinitions(devicesMessage) {
19
+ async createDeviceDefinitions(devicesMessage) {
18
20
  utils.clearArray(this.deviceCache);
19
21
  for (const devicesMessag of devicesMessage) {
20
22
  if (this.logCustomizations.debugDevices.includes(devicesMessag.ieee_address)) {
@@ -27,14 +29,14 @@ class DeviceController {
27
29
 
28
30
  if (devicesMessag.definition.exposes) {
29
31
  try {
30
- const newDevice = createDeviceFromExposes(devicesMessag, this.config);
32
+ const newDevice = await createDeviceFromExposes(devicesMessag, this.adapter);
33
+ newDevice.icon = await this.imageController.getDeviceIcon(devicesMessag);
31
34
  this.deviceCache.push(newDevice);
32
35
  } catch (err) {
33
36
  this.adapter.log.warn(`Cannot ${devicesMessag.friendly_name} create Device from Exposes!`);
34
37
  this.adapter.log.debug(JSON.stringify(devicesMessag));
35
38
  this.adapter.log.debug(err);
36
39
  }
37
-
38
40
  }
39
41
  }
40
42
  }
@@ -47,7 +49,7 @@ class DeviceController {
47
49
  const newDevice = {
48
50
  id: groupID,
49
51
  ieee_address: ieee_address,
50
- icon: undefined,
52
+ icon: undefined, // await imageController.getDeviceIcon(devicesMessag), device.definition.model
51
53
  optionsValues: {},
52
54
  states: [
53
55
  states.brightness,
@@ -239,6 +241,7 @@ class DeviceController {
239
241
  const deviceObj = {
240
242
  type: 'device',
241
243
  common: {
244
+ icon: device.icon,
242
245
  name: deviceName,
243
246
  desc: description,
244
247
  statusStates: { onlineId: '' }
package/lib/exposes.js CHANGED
@@ -171,9 +171,10 @@ function genState(expose, role, name, desc) {
171
171
  return state;
172
172
  }
173
173
 
174
- function createDeviceFromExposes(devicesMessag, config) {
174
+ async function createDeviceFromExposes(devicesMessag, adapter) {
175
175
  const states = [];
176
176
  let scenes = [];
177
+ const config = adapter.config;
177
178
  const deviceID = devicesMessag.friendly_name;
178
179
  const ieee_address = devicesMessag.ieee_address;
179
180
  const definition = devicesMessag.definition;
@@ -181,6 +182,7 @@ function createDeviceFromExposes(devicesMessag, config) {
181
182
  const disabled = devicesMessag.disabled && devicesMessag.disabled == true;
182
183
  const description = devicesMessag.description ? devicesMessag.description : undefined;
183
184
 
185
+
184
186
  function pushToStates(state, access) {
185
187
  if (state === undefined) {
186
188
  return 0;
@@ -663,17 +665,25 @@ function createDeviceFromExposes(devicesMessag, config) {
663
665
  break;
664
666
  }
665
667
 
666
- const hasHold = expose.values.find((actionName) => actionName.includes('hold'));
667
- const hasRelease = expose.values.find((actionName) => actionName.includes('release'));
668
-
669
668
  for (const actionName of expose.values) {
670
- // is release state ? - skip
671
- if (hasHold && hasRelease && actionName.includes('release')) {
669
+
670
+ // is release -> hold state? - skip
671
+ if (config.simpleHoldReleaseState == true && actionName.endsWith('release') && expose.values.find((x) => x == actionName.replace('release', 'hold'))) {
672
+ continue;
673
+ }
674
+
675
+ // is stop - move state? - skip
676
+ if (config.simpleMoveStopState == true && actionName.endsWith('stop') && expose.values.find((x) => x.includes(actionName.replace('stop', 'move')))) {
677
+ continue;
678
+ }
679
+
680
+ // is release -> press state? - skip
681
+ if (config.simplePressReleaseState == true && actionName.endsWith('release') && expose.values.find((x) => x == actionName.replace('release', 'press'))) {
672
682
  continue;
673
683
  }
674
684
 
675
- // is hold state ?
676
- if (hasHold && hasRelease && actionName.includes('hold')) {
685
+ // is hold -> release state ?
686
+ if (config.simpleHoldReleaseState == true && actionName.endsWith('hold') && expose.values.find((x) => x == actionName.replace('hold', 'release'))) {
677
687
  pushToStates({
678
688
  id: actionName.replace(/\*/g, ''),
679
689
  prop: 'action',
@@ -698,6 +708,52 @@ function createDeviceFromExposes(devicesMessag, config) {
698
708
  },
699
709
  }, expose.access);
700
710
  }
711
+ // is move -> stop state ?
712
+ else if (config.simpleMoveStopState == true && actionName.includes('move') && expose.values.find((x) => x == `${actionName.split('_')[0]}_stop`)) {
713
+ pushToStates({
714
+ id: actionName.replace(/\*/g, ''),
715
+ prop: 'action',
716
+ name: actionName,
717
+ icon: undefined,
718
+ role: 'button',
719
+ write: false,
720
+ read: true,
721
+ def: false,
722
+ type: 'boolean',
723
+ getter: (payload) => {
724
+ if (payload.action === actionName) {
725
+ return true;
726
+ }
727
+ if (payload.action === `${actionName.split('_')[0]}_stop`) {
728
+ return false;
729
+ }
730
+ return undefined;
731
+ },
732
+ }, expose.access);
733
+ }
734
+ // is press -> release state ?
735
+ else if (config.simplePressReleaseState == true && actionName.endsWith('press') && expose.values.find((x) => x == actionName.replace('press', 'release'))) {
736
+ pushToStates({
737
+ id: actionName.replace(/\*/g, ''),
738
+ prop: 'action',
739
+ name: actionName,
740
+ icon: undefined,
741
+ role: 'button',
742
+ write: false,
743
+ read: true,
744
+ def: false,
745
+ type: 'boolean',
746
+ getter: (payload) => {
747
+ if (payload.action === actionName) {
748
+ return true;
749
+ }
750
+ if (payload.action === actionName.replace('press', 'release')) {
751
+ return false;
752
+ }
753
+ return undefined;
754
+ },
755
+ }, expose.access);
756
+ }
701
757
  else if (actionName == 'color_temperature_move') {
702
758
  pushToStates({
703
759
  id: 'color_temperature_move',
@@ -810,32 +866,32 @@ function createDeviceFromExposes(devicesMessag, config) {
810
866
  }
811
867
  }, expose.access);
812
868
  }
813
- else if (actionName == 'hue_move') {
814
- pushToStates({
815
- id: 'hue_move',
816
- name: 'Hue move rate',
817
- icon: undefined,
818
- role: 'level.color.hue',
819
- write: false,
820
- read: true,
821
- type: 'number',
822
- min: 0,
823
- max: 360,
824
- def: 0,
825
- isEvent: true,
826
- getter: (payload) => {
827
- if (payload.action != 'hue_move') {
828
- return undefined;
829
- }
830
-
831
- if (payload.action_level) {
832
- return payload.action_rate;
833
- } else {
834
- return undefined;
835
- }
836
- }
837
- }, expose.access);
838
- }
869
+ // else if (actionName == 'hue_move') {
870
+ // pushToStates({
871
+ // id: 'hue_move',
872
+ // name: 'Hue move rate',
873
+ // icon: undefined,
874
+ // role: 'level.color.hue',
875
+ // write: false,
876
+ // read: true,
877
+ // type: 'number',
878
+ // min: 0,
879
+ // max: 360,
880
+ // def: 0,
881
+ // isEvent: true,
882
+ // getter: (payload) => {
883
+ // if (payload.action != 'hue_move') {
884
+ // return undefined;
885
+ // }
886
+
887
+ // if (payload.action_level) {
888
+ // return payload.action_level;
889
+ // } else {
890
+ // return undefined;
891
+ // }
892
+ // }
893
+ // }, expose.access);
894
+ // }
839
895
  else {
840
896
  pushToStates({
841
897
  id: actionName.replace(/\*/g, ''),
@@ -0,0 +1,110 @@
1
+ const axios = require('axios').default;
2
+ const sharp = require('sharp');
3
+
4
+ class ImageController {
5
+ constructor(adapter) {
6
+ this.adapter = adapter;
7
+ }
8
+
9
+ sanitizeModelIDForImageUrl(modelName) {
10
+ return modelName.replace('/', '_');
11
+ }
12
+
13
+ sanitizeZ2MDeviceName(deviceName) {
14
+ return deviceName ? deviceName.replace(/:|\s|\//g, '-') : 'NA';
15
+ }
16
+
17
+ getZ2mDeviceImage(device) {
18
+ if (device && device.definition && device.definition.model) {
19
+ return `https://www.zigbee2mqtt.io/images/devices/${this.sanitizeZ2MDeviceName(device.definition.model)}.jpg`;
20
+ }
21
+ }
22
+
23
+ getSlsDeviceImage(device) {
24
+ if (device && device.model_id) {
25
+ return `https://slsys.github.io/Gateway/devices/png/${this.sanitizeModelIDForImageUrl(device.model_id)}.png`;
26
+ }
27
+ }
28
+
29
+ async getDeviceIcon(device) {
30
+
31
+ if (this.adapter.config.useDeviceIcons == false) {
32
+ return '';
33
+ }
34
+
35
+ const z2mIconFileName = `${this.sanitizeZ2MDeviceName(device.definition.model)}.jpg`;
36
+ const slsIconFileName = `${this.sanitizeModelIDForImageUrl(device.model_id)}.png`;
37
+
38
+ let icon;
39
+ let iconFileName;
40
+ // Check whether an image has already been downloaded from Z2M.
41
+ if (await this.adapter.fileExistsAsync(this.adapter.namespace, z2mIconFileName)) {
42
+ iconFileName = z2mIconFileName;
43
+ }
44
+ // Check whether an image has already been downloaded from SLSys.
45
+ else if (await this.adapter.fileExistsAsync(this.adapter.namespace, slsIconFileName)) {
46
+ iconFileName = slsIconFileName;
47
+ }
48
+ // If not donwload image
49
+ else {
50
+ let iconUrl = this.getZ2mDeviceImage(device);
51
+ if (!iconUrl) {
52
+ iconUrl = this.getSlsDeviceImage(device);
53
+ }
54
+ this.adapter.log.info(`Download image for device model: ${device.definition.model}`);
55
+ await this.downloadIcon(this.adapter, iconUrl, this.adapter.namespace);
56
+ iconFileName = this.getFileNameWithExtension(iconUrl);
57
+ }
58
+
59
+ if ((await this.adapter.fileExistsAsync(this.adapter.namespace, iconFileName)) == false) {
60
+ this.adapter.log.warn(`No image for device model: ${device.definition.model} found!`);
61
+ return '';
62
+ }
63
+
64
+ try {
65
+ // Load image from the Meta-Store
66
+ icon = await this.adapter.readFileAsync(this.adapter.namespace, iconFileName);
67
+ // Load Image Metadata
68
+ const origIconMeta = await sharp(icon.file).metadata();
69
+ // Check whether the image needs to be resized
70
+ if ((origIconMeta.height && origIconMeta.height > 28) || (origIconMeta.width && origIconMeta.width > 28)) {
71
+ // Resize image to 28x28 pixel
72
+ this.adapter.log.info(`Resize image for device model ${device.definition.model} from: ${origIconMeta.width}x${origIconMeta.height} to 28x28`);
73
+ icon.file = await sharp(icon.file)
74
+ .resize({
75
+ width: 28,
76
+ height: 28,
77
+ fit: sharp.fit.cover,
78
+ position: sharp.strategy.entropy
79
+ })
80
+ .toBuffer();
81
+ // Replace the original image with the resize image.
82
+ await this.adapter.writeFileAsync(this.adapter.namespace, iconFileName, icon.file);
83
+ }
84
+ } catch (error) {
85
+ this.adapter.log.warn(error);
86
+ return '';
87
+ }
88
+ // Create and output Base64
89
+ return `data:image/png;base64,${icon.file.toString('base64')}`;
90
+
91
+ }
92
+ getFileNameWithExtension(url) {
93
+ const path = new URL(url).pathname;
94
+ const filename = path.split('/').pop();
95
+ return filename;
96
+ }
97
+
98
+ async downloadIcon(adapter, url, namespace) {
99
+ try {
100
+ const res = await axios.get(url, { responseType: 'arraybuffer' });
101
+ await adapter.writeFileAsync(namespace, this.getFileNameWithExtension(url), res.data);
102
+ }
103
+ catch (ex) {
104
+ adapter.log.warn(ex);
105
+ }
106
+ }
107
+ }
108
+ module.exports = {
109
+ ImageController,
110
+ };
package/lib/messages.js CHANGED
@@ -25,6 +25,14 @@ async function adapterInfo(config, log) {
25
25
  log.info(`|| Zigbee2MQTT Debug Log: ${config.debugLogEnabled ? 'activated' : 'deactivated'}`);
26
26
  log.info(`|| Proxy Zigbee2MQTT Logs to ioBroker Logs: ${config.proxyZ2MLogs ? 'activated' : 'deactivated'}`);
27
27
  log.info(`|| Use Kelvin: ${config.useKelvin ? 'yes' : 'no'}`);
28
+ log.info(`|| Use ColorTemperature ColorSync: ${config.colorTempSyncColor ? 'yes' : 'no'}`);
29
+ log.info(`|| Use BrightnessMove OnOff: ${config.brightnessMoveOnOff ? 'yes' : 'no'}`);
30
+ log.info(`|| Use BrightnessStep OnOff: ${config.brightnessStepOnOff ? 'yes' : 'no'}`);
31
+ log.info(`|| Use Event In Desc: ${config.useEventInDesc ? 'yes' : 'no'}`);
32
+ log.info(`|| Use Device Icons: ${config.useDeviceIcons ? 'yes' : 'no'}`);
33
+ log.info(`|| Use Simple Hold/Release State: ${config.simpleHoldReleaseState ? 'yes' : 'no'}`);
34
+ log.info(`|| Use Simple Move/Stop State: ${config.simpleMoveStopState ? 'yes' : 'no'}`);
35
+ log.info(`|| Use Simple Press/Release State: ${config.simplePressReleaseState ? 'yes' : 'no'}`);
28
36
  log.info('==================================================================================');
29
37
  }
30
38
 
@@ -61,7 +61,7 @@ class StatesController {
61
61
  if (state.prop && state.prop == 'action') {
62
62
  if (state.isEvent && state.isEvent == true) {
63
63
  if (state.type == 'boolean') {
64
- await this.setStateWithTimeoutAsync(stateName, state.getter(messageObj.payload), 300);
64
+ await this.setStateWithTimeoutAsync(stateName, state.getter(messageObj.payload), 450);
65
65
  }
66
66
  else {
67
67
  await this.setStateSafelyAsync(stateName, state.getter(messageObj.payload));
package/lib/utils.js CHANGED
@@ -88,24 +88,6 @@ function getAdId(adapter, id) {
88
88
  return adapter.namespace + '.' + id.split('.')[2]; // iobroker device id
89
89
  }
90
90
 
91
- function sanitizeImageParameter(parameter) {
92
- const replaceByDash = [/\?/g, /&/g, /[^a-z\d\-_./:]/gi, /[/]/gi];
93
- let sanitized = parameter;
94
- replaceByDash.forEach((r) => sanitized = sanitized.replace(r, '-'));
95
- return sanitized;
96
- }
97
-
98
- function getDeviceIcon(definition) {
99
- let icon = definition.icon;
100
- if (icon) {
101
- icon = icon.replace('${model}', sanitizeImageParameter(definition.model));
102
- }
103
- if (!icon) {
104
- icon = `https://www.zigbee2mqtt.io/images/devices/${sanitizeImageParameter(definition.model)}.jpg`;
105
- }
106
- return icon;
107
- }
108
-
109
91
  function clearArray(array) {
110
92
  while (array.length > 0) {
111
93
  array.pop();
@@ -142,7 +124,6 @@ module.exports = {
142
124
  decimalToHex,
143
125
  getZbId,
144
126
  getAdId,
145
- getDeviceIcon,
146
127
  clearArray,
147
128
  moveArray,
148
129
  isObject,
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "iobroker.zigbee2mqtt",
3
- "version": "2.10.1",
3
+ "version": "2.11.0",
4
4
  "description": "Zigbee2MQTT adapter for ioBroker",
5
5
  "author": {
6
6
  "name": "Dennis Rathjen",
@@ -22,8 +22,9 @@
22
22
  "@iobroker/adapter-core": "^3.0.3",
23
23
  "aedes": "^0.50.0",
24
24
  "aedes-persistence-nedb": "^2.0.3",
25
- "mqtt": "^5.0.2",
25
+ "mqtt": "^5.0.3",
26
26
  "net": "^1.0.2",
27
+ "sharp": "^0.32.5",
27
28
  "ws": "^8.13.0"
28
29
  },
29
30
  "devDependencies": {
@@ -37,21 +38,21 @@
37
38
  "@types/chai": "^4.3.5",
38
39
  "@types/chai-as-promised": "^7.1.5",
39
40
  "@types/mocha": "^10.0.1",
40
- "@types/node": "^20.4.10",
41
+ "@types/node": "^20.5.4",
41
42
  "@types/proxyquire": "^1.3.28",
42
43
  "@types/sinon": "^10.0.16",
43
44
  "@types/sinon-chai": "^3.2.9",
44
- "chai": "^4.3.7",
45
+ "chai": "^4.3.8",
45
46
  "chai-as-promised": "^7.1.1",
46
47
  "eslint": "^8.47.0",
47
48
  "eslint-config-prettier": "^9.0.0",
48
49
  "eslint-plugin-prettier": "^5.0.0",
49
50
  "mocha": "^10.2.0",
50
- "prettier": "^3.0.1",
51
+ "prettier": "^3.0.2",
51
52
  "proxyquire": "^2.1.3",
52
53
  "sinon": "^15.2.0",
53
54
  "sinon-chai": "^3.7.0",
54
- "typescript": "~5.1.6"
55
+ "typescript": "~5.2.2"
55
56
  },
56
57
  "main": "main.js",
57
58
  "files": [