diff --git a/custom_components/xiaomi_gateway3/core/devices.py b/custom_components/xiaomi_gateway3/core/devices.py index 91c6626d..dd1d9825 100644 --- a/custom_components/xiaomi_gateway3/core/devices.py +++ b/custom_components/xiaomi_gateway3/core/devices.py @@ -2050,6 +2050,17 @@ BaseConv("filter_life_level", "sensor", mi="3.p.1076"), BaseConv("battery_level", "sensor", mi="5.p.1003"), ], + # rhj.sensor_occupy.l730a + # https://home.miot-spec.com/s/rhj.sensor_occupy.l730a + 20179: ["LeTianPai", "Presence Sensor POP", "rhj.sensor_occupy.l730a"], + "spec": [ + MathConv("temperature", "sensor", mi="7.p.1001", round=1), + BaseConv("humidity", "sensor", mi="7.p.1002"), + BaseConv("illuminance", "sensor", mi="2.p.1005"), + MapConv("occupancy_status", "sensor", mi="2.p.1078", map={0: "NoOne", 1: "HasSomeone", 2: "MinorMotion", 3: "MovingAway", 4: "Approaching", 5: "StaticMotion", 6: "Moving", 7:"EnterIn"}), + BaseConv("no-one-duration", "sensor", mi="2.p.1079"), + BaseConv("has-someone-duration", "sensor", mi="2.p.1080") + ] }, { # BLE devices can be supported witout spec. New spec will be added "on the fly" when # device sends them. But better to rewrite right spec for each device