From 5ff3e9f569011610c80eda9943b61c6d2e717fb5 Mon Sep 17 00:00:00 2001 From: Koen Kanters Date: Fri, 25 Oct 2024 22:58:36 +0200 Subject: [PATCH] feat(add): SQ510A https://github.com/Koenkk/zigbee2mqtt/issues/24141 --- src/devices/ewelink.ts | 16 +++++++++++++++- 1 file changed, 15 insertions(+), 1 deletion(-) diff --git a/src/devices/ewelink.ts b/src/devices/ewelink.ts index 1efe1a4fdc86a..281bfa9569f4c 100644 --- a/src/devices/ewelink.ts +++ b/src/devices/ewelink.ts @@ -1,7 +1,7 @@ import fz from '../converters/fromZigbee'; import * as exposes from '../lib/exposes'; import {logger} from '../lib/logger'; -import {deviceEndpoints, onOff} from '../lib/modernExtend'; +import {battery, deviceEndpoints, iasZoneAlarm, onOff} from '../lib/modernExtend'; import {DefinitionWithExtend, Fz} from '../lib/types'; const e = exposes.presets; @@ -156,6 +156,20 @@ const definitions: DefinitionWithExtend[] = [ toZigbee: [], exposes: [e.rain()], }, + { + fingerprint: [ + { + type: 'EndDevice', + manufacturerName: 'eWeLink', + modelID: 'SNZB-03', + endpoints: [{ID: 1, profileID: 260, deviceID: 1026, inputClusters: [0, 3, 1, 1280, 32], outputClusters: [25]}], + }, + ], + model: 'SQ510A', + vendor: 'eWeLink', + description: 'Water leak sensor', + extend: [iasZoneAlarm({zoneAttributes: ['alarm_1', 'battery_low', 'tamper'], zoneType: 'water_leak'}), battery()], + }, ]; export default definitions;