Skip to content

Commit cd41782

Browse files
authored
Support for linp.remote.k9b1
1 parent 8e7b1a5 commit cd41782

File tree

1 file changed

+14
-0
lines changed

1 file changed

+14
-0
lines changed

custom_components/xiaomi_gateway3/core/devices.py

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1540,6 +1540,20 @@
15401540
MathConv("humidity", mi="3.p.1008", round=1),
15411541
BaseConv("battery", mi="2.p.1003"),
15421542
],
1543+
}, {
1544+
# linp.remote.k9b1
1545+
5480: ["Linptech", "Wireless Button", "k9b1"],
1546+
"spec": [
1547+
# mibeacon2 spec
1548+
BLEMapConv("action", "sensor", mi=4097, map={"000000": BUTTON_1_SINGLE, "000001": BUTTON_1_HOLD, "000002": BUTTON_1_DOUBLE}),
1549+
BLEByteConv("battery", "sensor", mi=18435, entity=ENTITY_LAZY), # uint8
1550+
# miot spec
1551+
ConstConv("action", mi="2.e.1", value=BUTTON_1_SINGLE),
1552+
ConstConv("action", mi="2.e.2", value=BUTTON_1_DOUBLE),
1553+
ConstConv("action", mi="2.e.3", value=BUTTON_1_HOLD),
1554+
BaseConv("battery", mi="3.p.1003"),
1555+
],
1556+
# "ttl": "6h" # battery every 6 hours
15431557
}, {
15441558
# linp.remote.k9b11
15451559
5481: ["Linptech", "Wireless Button", "k9b11"],

0 commit comments

Comments
 (0)