zigbee-herdsman-converters 14.0.563 → 14.0.564

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.
@@ -1943,13 +1943,18 @@ const converters = {
1943
1943
  const dp = dpValue.dp;
1944
1944
  const value = tuya.getDataValue(dpValue);
1945
1945
  switch (dp) {
1946
- case 1:
1946
+ case tuya.dataPoints.tthTemperature:
1947
1947
  return {temperature: calibrateAndPrecisionRoundOptions(value / 10, options, 'temperature')};
1948
- case 2:
1948
+ case tuya.dataPoints.tthHumidity:
1949
1949
  return {humidity: calibrateAndPrecisionRoundOptions(
1950
1950
  (value / (meta.device.manufacturerName === '_TZE200_bjawzodf' ? 10 : 1)),
1951
1951
  options, 'humidity')};
1952
- case 4:
1952
+ case tuya.dataPoints.tthBatteryLevel:
1953
+ return {
1954
+ battery_level: {0: 'low', 1: 'middle', 2: 'high'}[value],
1955
+ battery_low: value === 0 ? true : false,
1956
+ };
1957
+ case tuya.dataPoints.tthBattery:
1953
1958
  return {battery: value};
1954
1959
  default:
1955
1960
  meta.logger.warn(`zigbee-herdsman-converters:maa_tuya_temp_sensor: NOT RECOGNIZED ` +
@@ -72,6 +72,26 @@ module.exports = [
72
72
  await reporting.activePower(endpoint, {change: 2}); // Power reports in 0.1W
73
73
  },
74
74
  },
75
+ {
76
+ zigbeeModel: ['4256050-RZHAC'],
77
+ model: '4256050-RZHAC',
78
+ vendor: 'Centralite',
79
+ description: '3-Series smart outlet appliance module',
80
+ fromZigbee: [fz.on_off, fz.electrical_measurement],
81
+ toZigbee: [tz.on_off],
82
+ exposes: [e.switch(), e.power(), e.voltage(), e.current()],
83
+ configure: async (device, coordinatorEndpoint, logger) => {
84
+ const endpoint = device.getEndpoint(1);
85
+ await reporting.bind(endpoint, coordinatorEndpoint, ['genOnOff', 'haElectricalMeasurement']);
86
+ await reporting.onOff(endpoint);
87
+ // 4256050-RZHAC doesn't support reading 'acVoltageMultiplier' or 'acVoltageDivisor'
88
+ await endpoint.read('haElectricalMeasurement', ['acCurrentMultiplier', 'acCurrentDivisor']);
89
+ await endpoint.read('haElectricalMeasurement', ['acPowerMultiplier', 'acPowerDivisor']);
90
+ await reporting.rmsVoltage(endpoint, {change: 2}); // Voltage reports in V
91
+ await reporting.rmsCurrent(endpoint, {change: 10}); // Current reports in mA
92
+ await reporting.activePower(endpoint, {change: 2}); // Power reports in 0.1W
93
+ },
94
+ },
75
95
  {
76
96
  zigbeeModel: ['4257050-ZHAC'],
77
97
  model: '4257050-ZHAC',
@@ -348,7 +348,7 @@ module.exports = [
348
348
  model: 'GL-S-004Z',
349
349
  vendor: 'Gledopto',
350
350
  description: 'Zigbee 4W MR16 Bulb 30deg RGB+CCT',
351
- extend: gledoptoExtend.light_onoff_brightness_colortemp_color(),
351
+ extend: gledoptoExtend.light_onoff_brightness_colortemp_color({disableColorTempStartup: false}),
352
352
  },
353
353
  {
354
354
  zigbeeModel: ['GL-S-005Z'],
@@ -537,6 +537,7 @@ module.exports = [
537
537
  zigbeeModel: ['GL-D-006P'],
538
538
  model: 'GL-D-006P',
539
539
  vendor: 'Gledopto',
540
+ ota: ota.zigbeeOTA,
540
541
  description: 'Zigbee 6W anti-glare downlight RGB+CCT (pro)',
541
542
  extend: gledoptoExtend.light_onoff_brightness_colortemp_color({colorTempRange: [158, 495]}),
542
543
  },
@@ -139,7 +139,7 @@ module.exports = [
139
139
  zigbeeModel: ['Tibea TW Z3'],
140
140
  model: '4058075168572',
141
141
  vendor: 'LEDVANCE',
142
- description: 'SMART+ lamp E27 turntable white',
142
+ description: 'SMART+ lamp E27 tuneable white',
143
143
  extend: extend.ledvance.light_onoff_brightness_colortemp({colorTempRange: [153, 370]}),
144
144
  ota: ota.ledvance,
145
145
  },
@@ -151,4 +151,12 @@ module.exports = [
151
151
  extend: extend.ledvance.light_onoff_brightness_colortemp({colorTempRange: [153, 370]}),
152
152
  ota: ota.ledvance,
153
153
  },
154
+ {
155
+ zigbeeModel: ['CLA60 RGBW JP'],
156
+ model: 'SMARTZBA60RGBW',
157
+ vendor: 'LEDVANCE',
158
+ description: 'SMART+ lamp E26 RGBW',
159
+ extend: extend.ledvance.light_onoff_brightness_colortemp_color({colorTempRange: [153, 526]}),
160
+ ota: ota.ledvance,
161
+ },
154
162
  ];
@@ -2427,6 +2427,13 @@ module.exports = [
2427
2427
  description: 'Akari downlight',
2428
2428
  extend: hueExtend.light_onoff_brightness_colortemp_color({colorTempRange: [153, 500]}),
2429
2429
  },
2430
+ {
2431
+ zigbeeModel: ['LCD006'],
2432
+ model: '9290031346',
2433
+ vendor: 'Philips',
2434
+ description: 'Hue white and color ambiance 5/6" retrofit recessed downlight',
2435
+ extend: hueExtend.light_onoff_brightness_colortemp_color({colorTempRange: [153, 500]}),
2436
+ },
2430
2437
  {
2431
2438
  zigbeeModel: ['LWE004'],
2432
2439
  model: '8719514302235',
package/devices/tuya.js CHANGED
@@ -319,13 +319,22 @@ module.exports = [
319
319
  },
320
320
  {
321
321
  fingerprint: [{modelID: 'TS0601', manufacturerName: '_TZE200_bq5c8xfe'},
322
- {modelID: 'TS0601', manufacturerName: '_TZE200_bjawzodf'}],
322
+ {modelID: 'TS0601', manufacturerName: '_TZE200_bjawzodf'},
323
+ {modelID: 'TS0601', manufacturerName: '_TZE200_qyflbnbj'}],
323
324
  model: 'TS0601_temperature_humidity_sensor',
324
325
  vendor: 'TuYa',
325
326
  description: 'Temperature & humidity sensor',
326
327
  fromZigbee: [fz.tuya_temperature_humidity_sensor],
327
328
  toZigbee: [],
328
- exposes: [e.temperature(), e.humidity(), e.battery()],
329
+ exposes: (device, options) => {
330
+ const exps = [e.temperature(), e.humidity(), e.battery()];
331
+ if (!device || device.manufacturerName === '_TZE200_qyflbnbj') {
332
+ exps.push(e.battery_low());
333
+ exps.push(exposes.enum('battery_level', ea.STATE, ['low', 'middle', 'high']).withDescription('Battery level state'));
334
+ }
335
+ exps.push(e.linkquality());
336
+ return exps;
337
+ },
329
338
  },
330
339
  {
331
340
  fingerprint: [{modelID: 'TS0601', manufacturerName: '_TZE200_vzqtvljm'}],
package/lib/tuya.js CHANGED
@@ -626,6 +626,11 @@ const dataPoints = {
626
626
  nousHumiAlarm: 15,
627
627
  nousTempSensitivity: 19,
628
628
  nousReportInterval: 17,
629
+ // TUYA Temperature and Humidity Sensor
630
+ tthTemperature: 1,
631
+ tthHumidity: 2,
632
+ tthBatteryLevel: 3,
633
+ tthBattery: 4,
629
634
  // TUYA / HUMIDITY/ILLUMINANCE/TEMPERATURE SENSOR
630
635
  thitBatteryPercentage: 3,
631
636
  thitIlluminanceLux: 7,
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "zigbee-herdsman-converters",
3
- "version": "14.0.563",
3
+ "version": "14.0.564",
4
4
  "description": "Collection of device converters to be used with zigbee-herdsman",
5
5
  "main": "index.js",
6
6
  "files": [