zigbee-herdsman-converters 14.0.663 → 14.0.665
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/converters/fromZigbee.js +12 -5
- package/devices/namron.js +3 -2
- package/devices/philips.js +7 -0
- package/devices/samotech.js +11 -0
- package/devices/sengled.js +16 -0
- package/devices/sonoff.js +20 -0
- package/devices/tuya.js +1 -1
- package/devices/yookee.js +1 -0
- package/package.json +1 -1
package/converters/fromZigbee.js
CHANGED
|
@@ -347,16 +347,16 @@ const converters = {
|
|
|
347
347
|
msg.data.batteryAlarmState & 1<<3
|
|
348
348
|
) > 0;
|
|
349
349
|
const battery2Low = (
|
|
350
|
-
msg.data.batteryAlarmState & 1<<9 ||
|
|
351
350
|
msg.data.batteryAlarmState & 1<<10 ||
|
|
352
351
|
msg.data.batteryAlarmState & 1<<11 ||
|
|
353
|
-
msg.data.batteryAlarmState & 1<<12
|
|
352
|
+
msg.data.batteryAlarmState & 1<<12 ||
|
|
353
|
+
msg.data.batteryAlarmState & 1<<13
|
|
354
354
|
) > 0;
|
|
355
355
|
const battery3Low = (
|
|
356
|
-
msg.data.batteryAlarmState & 1<<19 ||
|
|
357
356
|
msg.data.batteryAlarmState & 1<<20 ||
|
|
358
357
|
msg.data.batteryAlarmState & 1<<21 ||
|
|
359
|
-
msg.data.batteryAlarmState & 1<<22
|
|
358
|
+
msg.data.batteryAlarmState & 1<<22 ||
|
|
359
|
+
msg.data.batteryAlarmState & 1<<23
|
|
360
360
|
) > 0;
|
|
361
361
|
payload.battery_low = battery1Low || battery2Low || battery3Low;
|
|
362
362
|
}
|
|
@@ -4086,7 +4086,14 @@ const converters = {
|
|
|
4086
4086
|
case tuya.dataPoints.moesSvalvePosition:
|
|
4087
4087
|
return {position: value};
|
|
4088
4088
|
case tuya.dataPoints.moesScompensationTempSet:
|
|
4089
|
-
return {
|
|
4089
|
+
return {
|
|
4090
|
+
local_temperature_calibration: value,
|
|
4091
|
+
// local_temperature is now stale: the valve does not report the re-calibrated value until an actual temperature change
|
|
4092
|
+
// so update local_temperature by subtracting the old calibration and adding the new one
|
|
4093
|
+
...(meta && meta.state && meta.state.local_temperature != null && meta.state.local_temperature_calibration != null) ?
|
|
4094
|
+
{local_temperature: meta.state.local_temperature + (value - meta.state.local_temperature_calibration)} :
|
|
4095
|
+
{},
|
|
4096
|
+
};
|
|
4090
4097
|
case tuya.dataPoints.moesSecoMode:
|
|
4091
4098
|
return {eco_mode: value ? 'ON' : 'OFF'};
|
|
4092
4099
|
case tuya.dataPoints.moesSecoModeTempSet:
|
package/devices/namron.js
CHANGED
|
@@ -5,6 +5,7 @@ const tz = require('../converters/toZigbee');
|
|
|
5
5
|
const constants = require('../lib/constants');
|
|
6
6
|
const reporting = require('../lib/reporting');
|
|
7
7
|
const globalStore = require('../lib/store');
|
|
8
|
+
const utils = require('../lib/utils');
|
|
8
9
|
const extend = require('../lib/extend');
|
|
9
10
|
const ea = exposes.access;
|
|
10
11
|
const e = exposes.presets;
|
|
@@ -34,7 +35,7 @@ const fzLocal = {
|
|
|
34
35
|
result.window_open_check = lookup[data[0x1009]];
|
|
35
36
|
}
|
|
36
37
|
if (data.hasOwnProperty(0x100A)) { // Hysterersis
|
|
37
|
-
result.hysterersis = data[0x100A];
|
|
38
|
+
result.hysterersis = utils.precisionRound(data[0x100A], 2) / 10;
|
|
38
39
|
}
|
|
39
40
|
return result;
|
|
40
41
|
},
|
|
@@ -64,7 +65,7 @@ const tzLocal = {
|
|
|
64
65
|
const payload = {0x1009: {value: lookup[value], type: herdsman.Zcl.DataType.enum8}};
|
|
65
66
|
await entity.write('hvacThermostat', payload, sunricherManufacturer);
|
|
66
67
|
} else if (key==='hysterersis') {
|
|
67
|
-
const payload = {0x100A: {value: value, type: 0x20}};
|
|
68
|
+
const payload = {0x100A: {value: value * 10, type: 0x20}};
|
|
68
69
|
await entity.write('hvacThermostat', payload, sunricherManufacturer);
|
|
69
70
|
}
|
|
70
71
|
},
|
package/devices/philips.js
CHANGED
|
@@ -1700,6 +1700,13 @@ module.exports = [
|
|
|
1700
1700
|
description: 'Hue White & Color ambience Centris ceiling light (3 spots)',
|
|
1701
1701
|
extend: hueExtend.light_onoff_brightness_colortemp_color({colorTempRange: [153, 500]}),
|
|
1702
1702
|
},
|
|
1703
|
+
{
|
|
1704
|
+
zigbeeModel: ['5060831P7_01', '5060831P7_02', '5060831P7_03', '5060831P7_04'],
|
|
1705
|
+
model: '5060831P7',
|
|
1706
|
+
vendor: 'Philips',
|
|
1707
|
+
description: 'Hue White & Color ambience Centris ceiling light (3 spots)',
|
|
1708
|
+
extend: hueExtend.light_onoff_brightness_colortemp_color({colorTempRange: [153, 500]}),
|
|
1709
|
+
},
|
|
1703
1710
|
{
|
|
1704
1711
|
zigbeeModel: ['5061031P7_01', '5061031P7_02', '5061031P7_03'],
|
|
1705
1712
|
model: '5061031P7',
|
package/devices/samotech.js
CHANGED
|
@@ -13,6 +13,17 @@ module.exports = [
|
|
|
13
13
|
await reporting.bind(endpoint, coordinatorEndpoint, ['genBasic', 'genIdentify', 'genOnOff']);
|
|
14
14
|
},
|
|
15
15
|
},
|
|
16
|
+
{
|
|
17
|
+
zigbeeModel: ['SM308-S'],
|
|
18
|
+
model: 'SM308-S',
|
|
19
|
+
vendor: 'Samotech',
|
|
20
|
+
description: 'Zigbee in wall smart switch',
|
|
21
|
+
extend: extend.switch(),
|
|
22
|
+
configure: async (device, coordinatorEndpoint, logger) => {
|
|
23
|
+
const endpoint = device.getEndpoint(1);
|
|
24
|
+
await reporting.bind(endpoint, coordinatorEndpoint, ['genBasic', 'genIdentify', 'genOnOff']);
|
|
25
|
+
},
|
|
26
|
+
},
|
|
16
27
|
{
|
|
17
28
|
zigbeeModel: ['SM309-S'],
|
|
18
29
|
model: 'SM309-S',
|
package/devices/sengled.js
CHANGED
|
@@ -246,6 +246,22 @@ module.exports = [
|
|
|
246
246
|
await reporting.batteryPercentageRemaining(endpoint);
|
|
247
247
|
},
|
|
248
248
|
},
|
|
249
|
+
{
|
|
250
|
+
zigbeeModel: ['E2D-G73'],
|
|
251
|
+
model: 'E2D-G73',
|
|
252
|
+
vendor: 'Sengled',
|
|
253
|
+
description: 'Smart window and door sensor G2',
|
|
254
|
+
fromZigbee: [fz.ias_contact_alarm_1, fz.battery],
|
|
255
|
+
toZigbee: [],
|
|
256
|
+
ota: ota.zigbeeOTA,
|
|
257
|
+
exposes: [e.contact(), e.battery_low(), e.battery(), e.battery_voltage(), e.tamper()],
|
|
258
|
+
configure: async (device, coordinatorEndpoint, logger) => {
|
|
259
|
+
const endpoint = device.getEndpoint(1);
|
|
260
|
+
await reporting.bind(endpoint, coordinatorEndpoint, ['genPowerCfg']);
|
|
261
|
+
await reporting.batteryVoltage(endpoint);
|
|
262
|
+
await reporting.batteryPercentageRemaining(endpoint);
|
|
263
|
+
},
|
|
264
|
+
},
|
|
249
265
|
{
|
|
250
266
|
zigbeeModel: ['E1C-NB6'],
|
|
251
267
|
model: 'E1C-NB6',
|
package/devices/sonoff.js
CHANGED
|
@@ -60,6 +60,26 @@ module.exports = [
|
|
|
60
60
|
device.save();
|
|
61
61
|
},
|
|
62
62
|
},
|
|
63
|
+
{
|
|
64
|
+
zigbeeModel: ['ZBMINIL2'],
|
|
65
|
+
model: 'ZBMINIL2',
|
|
66
|
+
vendor: 'SONOFF',
|
|
67
|
+
description: 'Zigbee smart switch (no neutral)',
|
|
68
|
+
ota: ota.zigbeeOTA,
|
|
69
|
+
extend: extend.switch(),
|
|
70
|
+
toZigbee: extend.switch().toZigbee.concat([tz.power_on_behavior]),
|
|
71
|
+
fromZigbee: extend.switch().fromZigbee.concat([fz.power_on_behavior]),
|
|
72
|
+
exposes: extend.switch().exposes.concat([e.power_on_behavior()]),
|
|
73
|
+
configure: async (device, coordinatorEndpoint, logger) => {
|
|
74
|
+
// Unbind genPollCtrl to prevent device from sending checkin message.
|
|
75
|
+
// Zigbee-herdsmans responds to the checkin message which causes the device
|
|
76
|
+
// to poll slower.
|
|
77
|
+
// https://github.com/Koenkk/zigbee2mqtt/issues/11676
|
|
78
|
+
await device.getEndpoint(1).unbind('genPollCtrl', coordinatorEndpoint);
|
|
79
|
+
device.powerSource = 'Mains (single phase)';
|
|
80
|
+
device.save();
|
|
81
|
+
},
|
|
82
|
+
},
|
|
63
83
|
{
|
|
64
84
|
zigbeeModel: ['01MINIZB'],
|
|
65
85
|
model: 'ZBMINI',
|
package/devices/tuya.js
CHANGED
|
@@ -3364,7 +3364,7 @@ module.exports = [
|
|
|
3364
3364
|
{modelID: 'TS0601', manufacturerName: '_TZE200_wukb7rhc'},
|
|
3365
3365
|
{modelID: 'TS0601', manufacturerName: '_TZE204_ztc6ggyl'},
|
|
3366
3366
|
{modelID: 'TS0601', manufacturerName: '_TZE200_ztc6ggyl'}],
|
|
3367
|
-
model: '
|
|
3367
|
+
model: 'TS0601_smart_human_presence_sensor',
|
|
3368
3368
|
vendor: 'TuYa',
|
|
3369
3369
|
description: 'Smart Human presence sensor',
|
|
3370
3370
|
fromZigbee: [fz.tuya_smart_human_presense_sensor],
|
package/devices/yookee.js
CHANGED
|
@@ -12,6 +12,7 @@ module.exports = [
|
|
|
12
12
|
description: 'Smart blind controller',
|
|
13
13
|
fromZigbee: [fz.D10110_cover_position_tilt, fz.battery],
|
|
14
14
|
toZigbee: [tz.cover_state, tz.cover_position_tilt],
|
|
15
|
+
meta: {coverInverted: true},
|
|
15
16
|
configure: async (device, coordinatorEndpoint, logger) => {
|
|
16
17
|
const endpoint = device.getEndpoint(1);
|
|
17
18
|
await reporting.bind(endpoint, coordinatorEndpoint, ['genPowerCfg', 'closuresWindowCovering']);
|