zigbee-herdsman-converters 14.0.587 → 14.0.588

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.
@@ -8445,6 +8445,9 @@ const converters = {
8445
8445
  break;
8446
8446
  }
8447
8447
  break;
8448
+ case tuya.dataPoints.AM02AddRemoter: // DP 101: Ignore until need is defined
8449
+ case tuya.dataPoints.AM02TimeTotal: // DP 10: Ignore until need is defined
8450
+ break;
8448
8451
  default: // Unknown code
8449
8452
  meta.logger.warn(`ZMAM02_cover: Unhandled DP #${dp} for ${meta.device.manufacturerName}:
8450
8453
  ${JSON.stringify(dpValue)}`);
@@ -7,7 +7,7 @@ const e = exposes.presets;
7
7
 
8
8
  module.exports = [
9
9
  {
10
- zigbeeModel: ['5j6ifxj'],
10
+ zigbeeModel: ['5j6ifxj', '5j6ifxj\u0000'],
11
11
  model: 'BW-IS3',
12
12
  vendor: 'BlitzWolf',
13
13
  description: 'Rechargeable Zigbee PIR motion sensor',
package/devices/ikea.js CHANGED
@@ -5,7 +5,9 @@ const ota = require('../lib/ota');
5
5
  const constants = require('../lib/constants');
6
6
  const reporting = require('../lib/reporting');
7
7
  const {repInterval} = require('../lib/constants');
8
+ const utils = require('../lib/utils');
8
9
  const extend = require('../lib/extend');
10
+ const globalStore = require('../lib/store');
9
11
  const e = exposes.presets;
10
12
  const ea = exposes.access;
11
13
  const herdsman = require('zigbee-herdsman');
@@ -58,6 +60,39 @@ const configureRemote = async (device, coordinatorEndpoint, logger) => {
58
60
  await reporting.batteryPercentageRemaining(endpoint);
59
61
  };
60
62
 
63
+ const fzLocal = {
64
+ // The STYRBAR sends an on +- 500ms after the arrow release. We don't want to send the ON action in this case.
65
+ // https://github.com/Koenkk/zigbee2mqtt/issues/13335
66
+ STYRBAR_on: {
67
+ cluster: 'genOnOff',
68
+ type: 'commandOn',
69
+ convert: (model, msg, publish, options, meta) => {
70
+ if (utils.hasAlreadyProcessedMessage(msg)) return;
71
+ const arrowReleaseAgo = Date.now() - globalStore.getValue(msg.endpoint, 'arrow_release', 0);
72
+ if (arrowReleaseAgo > 700) {
73
+ return {action: 'on'};
74
+ }
75
+ },
76
+ },
77
+ STYRBAR_arrow_release: {
78
+ cluster: 'genScenes',
79
+ type: 'commandTradfriArrowRelease',
80
+ options: [exposes.options.legacy()],
81
+ convert: (model, msg, publish, options, meta) => {
82
+ if (utils.hasAlreadyProcessedMessage(msg)) return;
83
+ globalStore.putValue(msg.endpoint, 'arrow_release', Date.now());
84
+ const direction = globalStore.getValue(msg.endpoint, 'direction');
85
+ if (direction) {
86
+ globalStore.clearValue(msg.endpoint, 'direction');
87
+ const duration = msg.data.value / 1000;
88
+ const result = {action: `arrow_${direction}_release`, duration, action_duration: duration};
89
+ if (!utils.isLegacyEnabled(options)) delete result.duration;
90
+ return result;
91
+ }
92
+ },
93
+ },
94
+ };
95
+
61
96
  const tradfriExtend = {
62
97
  light_onoff_brightness: (options = {}) => ({
63
98
  ...extend.light_onoff_brightness(options),
@@ -571,9 +606,9 @@ module.exports = [
571
606
  zigbeeModel: ['Remote Control N2'],
572
607
  model: 'E2001/E2002',
573
608
  vendor: 'IKEA',
574
- description: 'STYRBAR remote control N2',
575
- fromZigbee: [fz.battery, fz.command_on, fz.command_off, fz.command_move, fz.command_stop, fz.ikea_arrow_click,
576
- fz.ikea_arrow_hold, fz.ikea_arrow_release],
609
+ description: 'STYRBAR remote control',
610
+ fromZigbee: [fz.battery, fzLocal.STYRBAR_on, fz.command_off, fz.command_move, fz.command_stop, fz.ikea_arrow_click,
611
+ fz.ikea_arrow_hold, fzLocal.STYRBAR_arrow_release],
577
612
  exposes: [e.battery(), e.action(['on', 'off', 'brightness_move_up', 'brightness_move_down',
578
613
  'brightness_stop', 'arrow_left_click', 'arrow_right_click', 'arrow_left_hold',
579
614
  'arrow_right_hold', 'arrow_left_release', 'arrow_right_release'])],
package/devices/namron.js CHANGED
@@ -8,6 +8,13 @@ const ea = exposes.access;
8
8
  const e = exposes.presets;
9
9
 
10
10
  module.exports = [
11
+ {
12
+ zigbeeModel: ['3308431'],
13
+ model: '3308431',
14
+ vendor: 'Namron',
15
+ description: 'Luna ceiling light',
16
+ extend: extend.light_onoff_brightness_colortemp({colorTempRange: [153, 370]}),
17
+ },
11
18
  {
12
19
  zigbeeModel: ['3802967'],
13
20
  model: '3802967',
@@ -154,10 +154,7 @@ module.exports = [
154
154
  },
155
155
  },
156
156
  {
157
- fingerprint: [
158
- {modelID: 'TS0601', manufacturerName: '_TZE200_iossyxra'},
159
- {modelID: 'TS0601', manufacturerName: '_TZE200_gubdgai2'},
160
- ],
157
+ fingerprint: [{modelID: 'TS0601', manufacturerName: '_TZE200_iossyxra'}],
161
158
  model: 'ZM-AM02_cover',
162
159
  vendor: 'Zemismart',
163
160
  description: 'Zigbee/RF curtain converter',
@@ -183,6 +180,18 @@ module.exports = [
183
180
  // exposes.enum('situation_set', ea.STATE, Object.values(tuya.ZMAM02.AM02Situation)),
184
181
  ],
185
182
  },
183
+ {
184
+ fingerprint: [{modelID: 'TS0601', manufacturerName: '_TZE200_gubdgai2'}],
185
+ model: 'M515EGBZTN',
186
+ vendor: 'Zemismart',
187
+ description: 'Roller shade driver',
188
+ fromZigbee: [fz.ZMAM02_cover],
189
+ toZigbee: [tz.ZMAM02_cover],
190
+ exposes: [e.cover_position().setAccess('position', ea.STATE_SET),
191
+ exposes.enum('motor_direction', ea.STATE_SET, Object.values(tuya.ZMLookups.AM02Direction)),
192
+ exposes.enum('border', ea.STATE_SET, Object.values(tuya.ZMLookups.AM02Border)),
193
+ ],
194
+ },
186
195
  {
187
196
  fingerprint: [{modelID: 'TS0601', manufacturerName: '_TZE200_fzo2pocs'}],
188
197
  model: 'ZM25TQ',
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "zigbee-herdsman-converters",
3
- "version": "14.0.587",
3
+ "version": "14.0.588",
4
4
  "description": "Collection of device converters to be used with zigbee-herdsman",
5
5
  "main": "index.js",
6
6
  "files": [