From c4a121699729d657b3264bdd2fb384dbbe4d1913 Mon Sep 17 00:00:00 2001 From: Koen Kanters Date: Thu, 19 Apr 2018 23:00:07 +0200 Subject: [PATCH] Support MCCGQ11LM. #4 --- lib/converters/zigbee2mqtt.js | 8 ++++---- lib/devices.js | 6 ++++++ support/docgen.js | 6 ------ 3 files changed, 10 insertions(+), 10 deletions(-) diff --git a/lib/converters/zigbee2mqtt.js b/lib/converters/zigbee2mqtt.js index 0b36b4672f..7576334880 100644 --- a/lib/converters/zigbee2mqtt.js +++ b/lib/converters/zigbee2mqtt.js @@ -26,7 +26,7 @@ const store = {} const parsers = [ { - devices: ['WXKG01LM', 'RTCGQ01LM', 'WSDCGQ01LM', 'MCCGQ01LM', 'WXKG11LM'], + devices: ['WXKG01LM', 'RTCGQ01LM', 'WSDCGQ01LM', 'MCCGQ01LM', 'WXKG11LM', 'MCCGQ11LM'], cid: 'genBasic', type: 'attReport', disablePublish: true, @@ -108,7 +108,7 @@ const parsers = [ } }, { - devices: ['MCCGQ01LM'], + devices: ['MCCGQ01LM', 'MCCGQ11LM'], cid: 'genOnOff', type: 'attReport', convert: (msg) => {return {state: msg.data.data['onOff'] ? 'open' : 'closed'}} @@ -147,13 +147,13 @@ const parsers = [ // Ignore parsers (these message dont need parsing). { - devices: ['WXKG11LM'], + devices: ['WXKG11LM', 'MCCGQ11LM'], cid: 'genOnOff', type: 'devChange', convert: () => null }, { - devices: ['WXKG11LM'], + devices: ['WXKG11LM', 'MCCGQ11LM'], cid: 'genBasic', type: 'devChange', convert: () => null diff --git a/lib/devices.js b/lib/devices.js index 731047dd6c..5fc198ddcc 100644 --- a/lib/devices.js +++ b/lib/devices.js @@ -29,6 +29,12 @@ const devices = { description: 'MiJia door & window contact sensor', supports: 'open and closed state', }, + 'lumi.sensor_magnet.aq2': { + model: 'MCCGQ11LM', + vendor: 'Xiaomi', + description: 'Aqara door & window contact sensor', + supports: 'open and closed state', + }, 'TRADFRI bulb E27 WS opal 980lm': { model: 'LED1545G12', vendor: 'IKEA', diff --git a/support/docgen.js b/support/docgen.js index e868a1d88c..b3dfa53961 100644 --- a/support/docgen.js +++ b/support/docgen.js @@ -10,12 +10,6 @@ const plannedToSupport = [ supports: '-', vendor: 'Xiaomi', }, - { - model: 'MCCGQ11LM', - description: 'Aqara door & window contact sensor', - supports: '-', - vendor: 'Xiaomi', - }, { model: 'RTCGQ11LM', description: 'Aqara human body movement and illuminance sensor',