al-one / hass-xiaomi-miot

Automatic integrate all Xiaomi devices to HomeAssistant via miot-spec, support Wi-Fi, BLE, ZigBee devices. 小米米家智能家居设备接入Hass集成
https://miot-spec.com
Apache License 2.0
4.42k stars 617 forks source link

`entity_category` not applied to entity #960

Open blakadder opened 1 year ago

blakadder commented 1 year ago

Editing device_customizes.py I've tried adding an entity_category to certain entities but that field is never applied. The entity applies other attributes like unit_of_measurement or device_class

configurations tried:

    'viomi.vacuum.v18:clean_use_time': {
        'value_ratio': 0.0166667,
        'device_class': 'duration',
        'entity_category': 'diagnostic',
},
    'viomi.vacuum.v18:repeat_state': {
        'entity_category': 'config',
    },

neither entity_category config works

al-one commented 1 year ago

Fixed in master branch.

blakadder commented 1 year ago

Still does not happen for devices in device_customisations.py. I only get the battery percentage in the diagnostic group despite setting multiple entities in custom

al-one commented 1 year ago

Fixed in https://github.com/al-one/hass-xiaomi-miot/commit/582fd22519cc374401dd79f74d569e7c602e099c