zigbee-herdsman-converters 14.0.339 → 14.0.343

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.
@@ -2735,7 +2735,7 @@ const converters = {
2735
2735
  const currentTime = new Date().getTime();
2736
2736
  const utcTime = Math.round((currentTime - OneJanuary2000) / 1000);
2737
2737
  const localTime = Math.round(currentTime / 1000) - (new Date()).getTimezoneOffset() * 60;
2738
- const endpoint = msg.device.getEndpoint(1);
2738
+ const endpoint = msg.endpoint;
2739
2739
  const payload = {
2740
2740
  payloadSize: 8,
2741
2741
  payload: [
@@ -4927,6 +4927,11 @@ const converters = {
4927
4927
  value = data.readUInt32LE(i+2);
4928
4928
  i += 5;
4929
4929
  break;
4930
+ case 36:
4931
+ // 0x24 Zcl40BitUint
4932
+ value = [data.readUInt32LE(i+2), data.readUInt8(i+6)];
4933
+ i += 6;
4934
+ break;
4930
4935
  case 39:
4931
4936
  // 0x27 Zcl64BitUint
4932
4937
  value = data.readBigUInt64BE(i+2);
@@ -269,4 +269,25 @@ module.exports = [
269
269
  },
270
270
  exposes: [e.soil_moisture(), e.battery()],
271
271
  },
272
+ {
273
+ zigbeeModel: ['EFEKTA_eON213wz'],
274
+ model: 'EFEKTA_eON213wz',
275
+ vendor: 'Custom devices (DiY)',
276
+ description: '[Mini weather station, digital barometer, forecast, charts, temperature, humidity](http://efektalab.com/eON213wz)',
277
+ fromZigbee: [fz.temperature, fz.humidity, fz.pressure, fz.battery],
278
+ toZigbee: [tz.factory_reset],
279
+ configure: async (device, coordinatorEndpoint, logger) => {
280
+ const endpoint = device.getEndpoint(1);
281
+ await reporting.bind(endpoint, coordinatorEndpoint, [
282
+ 'genPowerCfg', 'msTemperatureMeasurement', 'msRelativeHumidity', 'msPressureMeasurement']);
283
+ const overides = {min: 0, max: 21600, change: 0};
284
+ await reporting.batteryVoltage(endpoint, overides);
285
+ await reporting.batteryPercentageRemaining(endpoint, overides);
286
+ await reporting.temperature(endpoint, overides);
287
+ await reporting.humidity(endpoint, overides);
288
+ await reporting.pressureExtended(endpoint, overides);
289
+ await endpoint.read('msPressureMeasurement', ['scale']);
290
+ },
291
+ exposes: [e.battery(), e.temperature(), e.humidity(), e.pressure()],
292
+ },
272
293
  ];
@@ -20,6 +20,21 @@ module.exports = [
20
20
  device.skipDefaultResponse = true;
21
21
  },
22
22
  },
23
+ {
24
+ zigbeeModel: ['SWITCH-ZR02'],
25
+ model: 'SWITCH-ZR02',
26
+ vendor: 'eWeLink',
27
+ description: 'Zigbee smart switch',
28
+ extend: extend.switch(),
29
+ fromZigbee: [fz.on_off_skip_duplicate_transaction],
30
+ configure: async (device, coordinatorEndpoint, logger) => {
31
+ const endpoint = device.getEndpoint(1);
32
+ await reporting.bind(endpoint, coordinatorEndpoint, ['genOnOff']);
33
+ },
34
+ onEvent: async (type, data, device) => {
35
+ device.skipDefaultResponse = true;
36
+ },
37
+ },
23
38
  {
24
39
  zigbeeModel: ['ZB-SW01'],
25
40
  model: 'ZB-SW01',
package/devices/heiman.js CHANGED
@@ -73,6 +73,7 @@ module.exports = [
73
73
  globalStore.clearValue(device, 'interval');
74
74
  } else if (!globalStore.hasValue(device, 'interval')) {
75
75
  const seconds = options && options.measurement_poll_interval ? options.measurement_poll_interval : 60;
76
+ if (seconds === -1) return;
76
77
  const interval = setInterval(async () => {
77
78
  try {
78
79
  await endpoint.read('haElectricalMeasurement', ['rmsVoltage', 'rmsCurrent', 'activePower']);
@@ -85,7 +86,8 @@ module.exports = [
85
86
  },
86
87
  {
87
88
  zigbeeModel: ['SMOK_V16', 'SMOK_V15', 'b5db59bfd81e4f1f95dc57fdbba17931', '98293058552c49f38ad0748541ee96ba', 'SMOK_YDLV10',
88
- 'FB56-SMF02HM1.4', 'SmokeSensor-N-3.0', '319fa36e7384414a9ea62cba8f6e7626', 'c3442b4ac59b4ba1a83119d938f283ab'],
89
+ 'FB56-SMF02HM1.4', 'SmokeSensor-N-3.0', '319fa36e7384414a9ea62cba8f6e7626', 'c3442b4ac59b4ba1a83119d938f283ab',
90
+ 'SmokeSensor-EF-3.0'],
89
91
  model: 'HS1SA',
90
92
  vendor: 'HEIMAN',
91
93
  description: 'Smoke detector',
@@ -99,7 +101,7 @@ module.exports = [
99
101
  exposes: [e.smoke(), e.battery_low(), e.battery()],
100
102
  },
101
103
  {
102
- zigbeeModel: ['SmokeSensor-N', 'SmokeSensor-EF-3.0', 'SmokeSensor-EM'],
104
+ zigbeeModel: ['SmokeSensor-N', 'SmokeSensor-EM'],
103
105
  model: 'HS3SA',
104
106
  vendor: 'HEIMAN',
105
107
  description: 'Smoke detector',
package/devices/ikea.js CHANGED
@@ -32,6 +32,19 @@ const bulbOnEvent = async (type, data, device) => {
32
32
  }
33
33
  };
34
34
 
35
+ const configureRemote = async (device, coordinatorEndpoint, logger) => {
36
+ // Firmware 2.3.75 >= only supports binding to endpoint, before only to group
37
+ // - https://github.com/Koenkk/zigbee2mqtt/issues/2772#issuecomment-577389281
38
+ // - https://github.com/Koenkk/zigbee2mqtt/issues/7716
39
+ const endpoint = device.getEndpoint(1);
40
+ const version = device.softwareBuildID.split('.').map((n) => Number(n));
41
+ const bindTarget = version[0] > 2 || (version[0] == 2 && version[1] > 3) || (version[0] == 2 && version[1] == 3 && version[2] >= 75) ?
42
+ coordinatorEndpoint : constants.defaultBindGroup;
43
+ await endpoint.bind('genOnOff', bindTarget);
44
+ await reporting.bind(endpoint, coordinatorEndpoint, ['genPowerCfg']);
45
+ await reporting.batteryPercentageRemaining(endpoint);
46
+ };
47
+
35
48
  const tradfriExtend = {
36
49
  light_onoff_brightness: (options = {}) => ({
37
50
  ...extend.light_onoff_brightness(options),
@@ -302,10 +315,10 @@ module.exports = [
302
315
  extend: tradfriExtend.light_onoff_brightness_colortemp(),
303
316
  },
304
317
  {
305
- zigbeeModel: ['TRADFRI bulb E14 WS 470lm', 'TRADFRI bulb E12 WS 450lm'],
318
+ zigbeeModel: ['TRADFRI bulb E14 WS 470lm', 'TRADFRI bulb E12 WS 450lm', 'TRADFRI bulb E17 WS 440lm'],
306
319
  model: 'LED1903C5/LED1835C6',
307
320
  vendor: 'IKEA',
308
- description: 'TRADFRI bulb E12/E14 WS 450/470 lumen, dimmable, white spectrum, opal white',
321
+ description: 'TRADFRI bulb E12/E14/E17 WS 450/470/440 lumen, dimmable, white spectrum, opal white',
309
322
  extend: tradfriExtend.light_onoff_brightness_colortemp(),
310
323
  },
311
324
  {
@@ -518,14 +531,7 @@ module.exports = [
518
531
  toZigbee: [],
519
532
  ota: ota.tradfri,
520
533
  meta: {battery: {dontDividePercentage: true}},
521
- configure: async (device, coordinatorEndpoint, logger) => {
522
- const endpoint = device.getEndpoint(1);
523
- // See explanation in E1743, only applies to E1810 (for E1524 it has no effect)
524
- // https://github.com/Koenkk/zigbee2mqtt/issues/2772#issuecomment-577389281
525
- await endpoint.bind('genOnOff', constants.defaultBindGroup);
526
- await reporting.bind(endpoint, coordinatorEndpoint, ['genPowerCfg']);
527
- await reporting.batteryPercentageRemaining(endpoint);
528
- },
534
+ configure: configureRemote,
529
535
  },
530
536
  {
531
537
  zigbeeModel: ['Remote Control N2'],
@@ -540,12 +546,7 @@ module.exports = [
540
546
  toZigbee: [],
541
547
  ota: ota.tradfri,
542
548
  meta: {battery: {dontDividePercentage: true}},
543
- configure: async (device, coordinatorEndpoint, logger) => {
544
- const endpoint = device.getEndpoint(1);
545
- await endpoint.bind('genOnOff', constants.defaultBindGroup);
546
- await reporting.bind(endpoint, coordinatorEndpoint, ['genPowerCfg']);
547
- await reporting.batteryPercentageRemaining(endpoint);
548
- },
549
+ configure: configureRemote,
549
550
  },
550
551
  {
551
552
  zigbeeModel: ['TRADFRI on/off switch'],
@@ -558,16 +559,7 @@ module.exports = [
558
559
  toZigbee: [],
559
560
  ota: ota.tradfri,
560
561
  meta: {disableActionGroup: true, battery: {dontDividePercentage: true}},
561
- configure: async (device, coordinatorEndpoint, logger) => {
562
- const endpoint = device.getEndpoint(1);
563
- // By default this device controls group 0, some devices are by default in
564
- // group 0 causing the remote to control them.
565
- // By binding it to a random group, e.g. 901, it will send the commands to group 901 instead of 0
566
- // https://github.com/Koenkk/zigbee2mqtt/issues/2772#issuecomment-577389281
567
- await endpoint.bind('genOnOff', constants.defaultBindGroup);
568
- await reporting.bind(endpoint, coordinatorEndpoint, ['genPowerCfg']);
569
- await reporting.batteryPercentageRemaining(endpoint);
570
- },
562
+ configure: configureRemote,
571
563
  },
572
564
  {
573
565
  zigbeeModel: ['KNYCKLAN Open/Close remote'],
@@ -579,16 +571,7 @@ module.exports = [
579
571
  toZigbee: [],
580
572
  ota: ota.tradfri,
581
573
  meta: {disableActionGroup: true, battery: {dontDividePercentage: true}},
582
- configure: async (device, coordinatorEndpoint, logger) => {
583
- const endpoint = device.getEndpoint(1);
584
- // By default this device controls group 0, some devices are by default in
585
- // group 0 causing the remote to control them.
586
- // By binding it to a random group, e.g. 901, it will send the commands to group 901 instead of 0
587
- // https://github.com/Koenkk/zigbee2mqtt/issues/2772#issuecomment-577389281
588
- await endpoint.bind('genOnOff', constants.defaultBindGroup);
589
- await reporting.bind(endpoint, coordinatorEndpoint, ['genPowerCfg']);
590
- await reporting.batteryPercentageRemaining(endpoint);
591
- },
574
+ configure: configureRemote,
592
575
  },
593
576
  {
594
577
  zigbeeModel: ['KNYCKLAN receiver'],
@@ -613,14 +596,7 @@ module.exports = [
613
596
  toZigbee: [],
614
597
  ota: ota.tradfri,
615
598
  meta: {disableActionGroup: true, battery: {dontDividePercentage: true}},
616
- configure: async (device, coordinatorEndpoint, logger) => {
617
- const endpoint = device.getEndpoint(1);
618
- // By default this device controls group 0, some devices are by default in
619
- // group 0 causing the remote to control them.
620
- // By binding it to a random group, e.g. 901, it will send the commands to group 901 instead of 0
621
- await reporting.bind(endpoint, constants.defaultBindGroup, ['genPowerCfg']);
622
- await reporting.batteryPercentageRemaining(endpoint);
623
- },
599
+ configure: configureRemote,
624
600
  },
625
601
  {
626
602
  zigbeeModel: ['SYMFONISK Sound Controller'],
@@ -722,16 +698,7 @@ module.exports = [
722
698
  toZigbee: [],
723
699
  meta: {battery: {dontDividePercentage: true}},
724
700
  ota: ota.tradfri,
725
- configure: async (device, coordinatorEndpoint, logger) => {
726
- const endpoint = device.getEndpoint(1);
727
- // By default this device controls group 0, some devices are by default in
728
- // group 0 causing the remote to control them.
729
- // By binding it to a random group, e.g. 901, it will send the commands to group 901 instead of 0
730
- // https://github.com/Koenkk/zigbee2mqtt/issues/2772#issuecomment-577389281
731
- await endpoint.bind('genOnOff', constants.defaultBindGroup);
732
- await reporting.bind(endpoint, coordinatorEndpoint, ['genPowerCfg']);
733
- await reporting.batteryPercentageRemaining(endpoint);
734
- },
701
+ configure: configureRemote,
735
702
  },
736
703
  {
737
704
  zigbeeModel: ['GUNNARP panel round'],
package/devices/namron.js CHANGED
@@ -184,6 +184,13 @@ module.exports = [
184
184
  return {l1: 1, l2: 2, l3: 3, l4: 4};
185
185
  },
186
186
  },
187
+ {
188
+ zigbeeModel: ['3802961'],
189
+ model: '3802961',
190
+ vendor: 'Namron',
191
+ description: 'LED 9W CCT E27',
192
+ extend: extend.light_onoff_brightness_colortemp({colorTempRange: [153, 370]}),
193
+ },
187
194
  {
188
195
  zigbeeModel: ['3802962'],
189
196
  model: '3802962',
package/devices/nue_3a.js CHANGED
@@ -157,7 +157,7 @@ module.exports = [
157
157
  },
158
158
  },
159
159
  {
160
- zigbeeModel: ['FNB56-ZSW02LX2.0', 'LXN-2S27LX1.0'],
160
+ zigbeeModel: ['FNB56-ZSW02LX2.0'],
161
161
  model: 'HGZB-42',
162
162
  vendor: 'Nue / 3A',
163
163
  description: 'Smart light switch - 2 gang v2.0',
@@ -282,4 +282,16 @@ module.exports = [
282
282
  description: '9W RGB LED downlight',
283
283
  extend: extend.light_onoff_brightness_colortemp_color({colorTempRange: [153, 370]}),
284
284
  },
285
+ {
286
+ zigbeeModel: ['LXN-2S27LX1.0'],
287
+ model: 'NUE-AUWZO2',
288
+ vendor: 'Nue / 3A',
289
+ description: 'Smart Zigbee double power point',
290
+ extend: extend.switch(),
291
+ exposes: [e.switch().withEndpoint('left'), e.switch().withEndpoint('right')],
292
+ meta: {multiEndpoint: true},
293
+ endpoint: (device) => {
294
+ return {left: 1, right: 2};
295
+ },
296
+ },
285
297
  ];
@@ -368,6 +368,15 @@ module.exports = [
368
368
  extend: hueExtend.light_onoff_brightness_colortemp_color({colorTempRange: [153, 500]}),
369
369
  ota: ota.zigbeeOTA,
370
370
  },
371
+ {
372
+ zigbeeModel: ['1743730P7'],
373
+ model: '1743730P7',
374
+ vendor: 'Philips',
375
+ description: 'Hue Calla outdoor',
376
+ meta: {turnsOffAtBrightness1: true},
377
+ extend: hueExtend.light_onoff_brightness_colortemp_color({colorTempRange: [153, 500]}),
378
+ ota: ota.zigbeeOTA,
379
+ },
371
380
  {
372
381
  zigbeeModel: ['1744130P7'],
373
382
  model: '1744130P7',
@@ -404,6 +413,15 @@ module.exports = [
404
413
  extend: hueExtend.light_onoff_brightness_colortemp_color(),
405
414
  ota: ota.zigbeeOTA,
406
415
  },
416
+ {
417
+ zigbeeModel: ['1743430P7'],
418
+ model: '1743430P7',
419
+ vendor: 'Philips',
420
+ description: 'Hue Impress outdoor Pedestal',
421
+ meta: {turnsOffAtBrightness1: true},
422
+ extend: hueExtend.light_onoff_brightness_colortemp_color({colorTempRange: [153, 500]}),
423
+ ota: ota.zigbeeOTA,
424
+ },
407
425
  {
408
426
  zigbeeModel: ['1740193P0'],
409
427
  model: '1740193P0',
@@ -834,7 +852,7 @@ module.exports = [
834
852
  ota: ota.zigbeeOTA,
835
853
  },
836
854
  {
837
- zigbeeModel: ['LCT024', '440400982841'],
855
+ zigbeeModel: ['LCT024', '440400982841', '440400982842'],
838
856
  model: '915005733701',
839
857
  vendor: 'Philips',
840
858
  description: 'Hue White and color ambiance Play Lightbar',
package/devices/tuya.js CHANGED
@@ -80,12 +80,16 @@ module.exports = [
80
80
  },
81
81
  {
82
82
  fingerprint: [{modelID: 'TS011F', manufacturerName: '_TZ3000_mvn6jl7x'},
83
- {modelID: 'TS011F', manufacturerName: '_TZ3000_raviyuvk'}, {modelID: 'TS011F', manufacturerName: '_TYZB01_hlla45kx'}],
83
+ {modelID: 'TS011F', manufacturerName: '_TZ3000_raviyuvk'}, {modelID: 'TS011F', manufacturerName: '_TYZB01_hlla45kx'},
84
+ {modelID: 'TS011F', manufacturerName: '_TZ3000_92qd4sqa'}],
84
85
  model: 'TS011F_2_gang_wall',
85
86
  vendor: 'TuYa',
86
87
  description: '2 gang wall outlet',
87
- extend: extend.switch(),
88
- exposes: [e.switch().withEndpoint('l1'), e.switch().withEndpoint('l2')],
88
+ toZigbee: extend.switch().toZigbee.concat([tz.moes_power_on_behavior, tz.tuya_backlight_mode]),
89
+ fromZigbee: extend.switch().fromZigbee.concat([fz.moes_power_on_behavior, fz.tuya_backlight_mode]),
90
+ exposes: [e.switch().withEndpoint('l1'), e.switch().withEndpoint('l2'),
91
+ exposes.enum('power_on_behavior', ea.ALL, ['on', 'off', 'previous']),
92
+ exposes.enum('backlight_mode', ea.ALL, ['LOW', 'MEDIUM', 'HIGH'])],
89
93
  whiteLabel: [{vendor: 'ClickSmart+', model: 'CMA30036'}],
90
94
  endpoint: (device) => {
91
95
  return {'l1': 1, 'l2': 2};
@@ -118,6 +122,7 @@ module.exports = [
118
122
  {modelID: 'TS0505B', manufacturerName: '_TZ3000_x2fqbdun'},
119
123
  {modelID: 'TS0505B', manufacturerName: '_TZ3000_589kq4ul'},
120
124
  {modelID: 'TS0505B', manufacturerName: '_TZ3000_1mtktxdk'},
125
+ {modelID: 'TS0505B', manufacturerName: '_TZ3210_0rn9qhnu'},
121
126
  {modelID: 'TS0505B', manufacturerName: '_TZ3210_bicjqpg4'},
122
127
  {modelID: 'TS0505B', manufacturerName: '_TZ3000_cmaky9gq'},
123
128
  {modelID: 'TS0505B', manufacturerName: '_TZ3000_tza2vjxx'}],
@@ -984,6 +989,7 @@ module.exports = [
984
989
  globalStore.clearValue(device, 'interval');
985
990
  } else if (!globalStore.hasValue(device, 'interval')) {
986
991
  const seconds = options && options.measurement_poll_interval ? options.measurement_poll_interval : 60;
992
+ if (seconds === -1) return;
987
993
  const interval = setInterval(async () => {
988
994
  try {
989
995
  await endpoint.read('haElectricalMeasurement', ['rmsVoltage', 'rmsCurrent', 'activePower']);
@@ -1080,6 +1086,7 @@ module.exports = [
1080
1086
  globalStore.clearValue(device, 'interval');
1081
1087
  } else if (!globalStore.hasValue(device, 'interval')) {
1082
1088
  const seconds = options && options.measurement_poll_interval ? options.measurement_poll_interval : 60;
1089
+ if (seconds === -1) return;
1083
1090
  const interval = setInterval(async () => {
1084
1091
  try {
1085
1092
  await endpoint.read('haElectricalMeasurement', ['rmsVoltage', 'rmsCurrent', 'activePower']);
@@ -1226,7 +1233,8 @@ module.exports = [
1226
1233
  },
1227
1234
  },
1228
1235
  {
1229
- fingerprint: [{modelID: 'TS0011', manufacturerName: '_TZ3000_ji4araar'}, {modelID: 'TS0011', manufacturerName: '_TZ3000_qmi1cfuq'}],
1236
+ fingerprint: [{modelID: 'TS0011', manufacturerName: '_TZ3000_ji4araar'}, {modelID: 'TS0011', manufacturerName: '_TZ3000_qmi1cfuq'},
1237
+ {modelID: 'TS0011', manufacturerName: '_TZ3000_txpirhfq'}],
1230
1238
  model: 'TS0011_switch_module',
1231
1239
  vendor: 'TuYa',
1232
1240
  description: '1 gang switch module - (without neutral)',
@@ -1237,7 +1245,7 @@ module.exports = [
1237
1245
  exposes.presets.power_on_behavior(),
1238
1246
  exposes.presets.switch_type_2(),
1239
1247
  ],
1240
- whiteLabel: [{vendor: 'AVATTO', model: '1gang N-ZLWSM01'}],
1248
+ whiteLabel: [{vendor: 'AVATTO', model: '1gang N-ZLWSM01'}, {vendor: 'SMATRUL', model: 'TMZ02L-16A-W'}],
1241
1249
  configure: async (device, coordinatorEndpoint, logger) => {
1242
1250
  await reporting.bind(device.getEndpoint(1), coordinatorEndpoint, ['genOnOff']);
1243
1251
  device.powerSource = 'Mains (single phase)';
package/lib/exposes.js CHANGED
@@ -495,7 +495,7 @@ module.exports = {
495
495
  no_position_support: () => new Binary('no_position_support', access.SET, true, false).withDescription('Set to true when your device only reports position 0, 100 and 50 (in this case your device has an older firmware) (default false).'),
496
496
  transition: () => new Numeric(`transition`, access.SET).withValueMin(0).withDescription('Controls the transition time (in seconds) of on/off, brightness, color temperature (if applicable) and color (if applicable) changes. Defaults to `0` (no transition).'),
497
497
  legacy: () => new Binary(`legacy`, access.SET, true, false).withDescription(`Set to false to disable the legacy integration (highly recommended), will change structure of the published payload (default true).`),
498
- measurement_poll_interval: () => new Numeric(`measurement_poll_interval`, access.SET).withValueMin(0).withDescription(`This device does not support reporting electric measurements so it is polled instead. The default poll interval is 60 seconds.`),
498
+ measurement_poll_interval: () => new Numeric(`measurement_poll_interval`, access.SET).withValueMin(-1).withDescription(`This device does not support reporting electric measurements so it is polled instead. The default poll interval is 60 seconds, set to -1 to disable.`),
499
499
  illuminance_below_threshold_check: () => new Binary(`illuminance_below_threshold_check`, access.SET, true, false).withDescription(`Set to false to also send messages when illuminance is above threshold in night mode (default true).`),
500
500
  },
501
501
  presets: {
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "zigbee-herdsman-converters",
3
- "version": "14.0.339",
3
+ "version": "14.0.343",
4
4
  "lockfileVersion": 1,
5
5
  "requires": true,
6
6
  "dependencies": {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "zigbee-herdsman-converters",
3
- "version": "14.0.339",
3
+ "version": "14.0.343",
4
4
  "description": "Collection of device converters to be used with zigbee-herdsman",
5
5
  "main": "index.js",
6
6
  "files": [