hass-xiaomi-miot icon indicating copy to clipboard operation
hass-xiaomi-miot copied to clipboard

小米人在传感器缺少光照实体

Open FlyRenxing opened this issue 8 months ago • 0 comments

Device model / 设备型号

xiaomi.sensor_occupy.03

Component version / 插件版本

0.7.18

HA core version / HA版本

2024.5.5

Integrated mode / 集成方式

Automatic (自动模式)

The problem / 问题详情

小米人在传感器缺少光照实体。 在该设备的Xiaomi Human Presence Sensor Occupancy Sensor Status传感器中包含Occupancy sensor.illumination属性可作为实体。希望添加适配。 经测试以下配置可自定义实体:

template: 
    sensors:
      xiaomi_03_baf0_occupancy_sensor_illumination:
        friendly_name: "小米人在传感器-亮度"
        unit_of_measurement: 'lx'
        value_template: "{{ state_attr('sensor.xiaomi_03_baf0_occupancy_sensor', 'occupancy_sensor.illumination') }}"
        unique_id: "32b33778a2614be0a3290f81afdeaba4"
image

Entity attributes / 实体属性

无实体

Home Assistant Logs / 系统日志

无需日志

FlyRenxing avatar Jun 05 '24 08:06 FlyRenxing