mirror of
https://github.com/Koenkk/zigbee2mqtt.git
synced 2026-08-27 21:20:03 +00:00
Add ssIasZone parser for SJCGQ11LM to directly detect water_leak. #17
This commit is contained in:
@@ -43,7 +43,7 @@ const store = {}
|
||||
|
||||
const parsers = [
|
||||
{
|
||||
devices: ['WXKG01LM', 'RTCGQ01LM', 'WSDCGQ01LM', 'MCCGQ01LM', 'WXKG11LM', 'MCCGQ11LM', 'RTCGQ11LM', 'WSDCGQ11LM'],
|
||||
devices: ['WXKG01LM', 'RTCGQ01LM', 'WSDCGQ01LM', 'MCCGQ01LM', 'WXKG11LM', 'MCCGQ11LM', 'RTCGQ11LM', 'WSDCGQ11LM', 'SJCGQ11LM'],
|
||||
cid: 'genBasic',
|
||||
type: 'attReport',
|
||||
disablePublish: true,
|
||||
@@ -204,12 +204,13 @@ const parsers = [
|
||||
devices: ['SJCGQ11LM'],
|
||||
cid: 'genBasic',
|
||||
type: 'attReport',
|
||||
convert: (msg) => {
|
||||
return {
|
||||
battery: toPercentage(msg.data.data['65281']['1'], battery.min, battery.max),
|
||||
water_leak: msg.data.data['65281']['100'] === 1,
|
||||
};
|
||||
}
|
||||
convert: (msg) => {return {water_leak: msg.data.data['65281']['100'] === 1}}
|
||||
},
|
||||
{
|
||||
devices: ['SJCGQ11LM'],
|
||||
cid: 'ssIasZone',
|
||||
type: 'statusChange',
|
||||
convert: (msg) => {return {water_leak: msg.data.zoneStatus === 1}}
|
||||
},
|
||||
{
|
||||
devices: ['ZNCZ02LM', 'QBCZ11LM'],
|
||||
|
||||
Reference in New Issue
Block a user