zigbee-herdsman-converters 14.0.419 → 14.0.420
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/toZigbee.js +4 -0
- package/devices/profalux.js +34 -0
- package/devices/xiaomi.js +7 -1
- package/npm-shrinkwrap.json +1 -1
- package/package.json +1 -1
package/converters/toZigbee.js
CHANGED
|
@@ -299,6 +299,10 @@ const converters = {
|
|
|
299
299
|
convertSet: async (entity, key, value, meta) => {
|
|
300
300
|
if (typeof value !== 'number') {
|
|
301
301
|
value = value.toLowerCase();
|
|
302
|
+
if (value === 'stop') {
|
|
303
|
+
await entity.command('genLevelCtrl', 'stop', {}, utils.getOptions(meta.mapped, entity));
|
|
304
|
+
return;
|
|
305
|
+
}
|
|
302
306
|
const lookup = {'open': 100, 'close': 0};
|
|
303
307
|
utils.validateValue(value, Object.keys(lookup));
|
|
304
308
|
value = lookup[value];
|
|
@@ -0,0 +1,34 @@
|
|
|
1
|
+
const fz = require('zigbee-herdsman-converters/converters/fromZigbee');
|
|
2
|
+
const tz = require('zigbee-herdsman-converters/converters/toZigbee');
|
|
3
|
+
const exposes = require('zigbee-herdsman-converters/lib/exposes');
|
|
4
|
+
const reporting = require('zigbee-herdsman-converters/lib/reporting');
|
|
5
|
+
const e = exposes.presets;
|
|
6
|
+
const ea = exposes.access;
|
|
7
|
+
|
|
8
|
+
module.exports = [
|
|
9
|
+
{
|
|
10
|
+
fingerprint: [{manufId: 4368, endpoints: [{ID: 1, profileID: 260, deviceID: 513, inputClusters: [0, 3, 21],
|
|
11
|
+
outputClusters: [3, 4, 5, 6, 8, 256, 64544, 64545]}]}],
|
|
12
|
+
model: 'NB102',
|
|
13
|
+
vendor: 'Profalux',
|
|
14
|
+
description: 'Cover remote',
|
|
15
|
+
fromZigbee: [],
|
|
16
|
+
toZigbee: [],
|
|
17
|
+
exposes: [],
|
|
18
|
+
},
|
|
19
|
+
{
|
|
20
|
+
fingerprint: [{manufId: 4368, endpoints: [{ID: 1, profileID: 260, deviceID: 512,
|
|
21
|
+
inputClusters: [0, 3, 4, 5, 6, 8, 10, 21, 256, 64544, 64545], outputClusters: [3, 64544]}]}],
|
|
22
|
+
model: 'NSAV061',
|
|
23
|
+
vendor: 'Profalux',
|
|
24
|
+
description: 'Cover',
|
|
25
|
+
fromZigbee: [fz.cover_position_via_brightness, fz.cover_state_via_onoff],
|
|
26
|
+
toZigbee: [tz.cover_via_brightness],
|
|
27
|
+
exposes: [e.cover_position().setAccess('state', ea.ALL)],
|
|
28
|
+
configure: async (device, coordinatorEndpoint, logger) => {
|
|
29
|
+
const endpoint = device.getEndpoint(1);
|
|
30
|
+
await reporting.bind(endpoint, coordinatorEndpoint, ['genLevelCtrl']);
|
|
31
|
+
await reporting.brightness(endpoint);
|
|
32
|
+
},
|
|
33
|
+
},
|
|
34
|
+
];
|
package/devices/xiaomi.js
CHANGED
|
@@ -54,9 +54,15 @@ module.exports = [
|
|
|
54
54
|
model: 'MCCGQ13LM',
|
|
55
55
|
vendor: 'Xiaomi',
|
|
56
56
|
description: 'Aqara P1 door & window contact sensor',
|
|
57
|
-
fromZigbee: [fz.ias_contact_alarm_1, fz.aqara_opple],
|
|
57
|
+
fromZigbee: [fz. xiaomi_contact, fz.ias_contact_alarm_1, fz.aqara_opple, fz.battery],
|
|
58
58
|
toZigbee: [],
|
|
59
|
+
meta: {battery: {voltageToPercentage: '3V_2850_3200'}},
|
|
59
60
|
exposes: [e.contact(), e.battery(), e.battery_voltage()],
|
|
61
|
+
configure: async (device, coordinatorEndpoint, logger) => {
|
|
62
|
+
const endpoint = device.getEndpoint(1);
|
|
63
|
+
await reporting.bind(endpoint, coordinatorEndpoint, ['genPowerCfg']);
|
|
64
|
+
await reporting.batteryVoltage(endpoint);
|
|
65
|
+
},
|
|
60
66
|
},
|
|
61
67
|
{
|
|
62
68
|
zigbeeModel: ['lumi.dimmer.rcbac1'],
|
package/npm-shrinkwrap.json
CHANGED