pblxptr / ecoNET-300-Home-Assistant-Integration

ecoNET300 Home Assistant is a custom integration for ecoNET300 devices.
16 stars 6 forks source link

Get data from sysParams #24

Closed jontofront closed 10 months ago

jontofront commented 10 months ago

Hi @pblxptr,

Maybe you can hel me? I want add to binary_sensor LAN and wifi connection like

device_class=BinarySensorDeviceClass.CONNECTIVITY, entity_category=EntityCategory.DIAGNOSTIC,

These keys are in sysParams I try to get data in one masive sysParams and regParams but gets errors :) (I am not phyton programer) https://github.com/pblxptr/ecoNET-300-Home-Assistant-Integration/blob/2fe2061e55177aea84c248bfd3a0c6891fca17b7/custom_components/econet300/api.py#L140

    sys_params = await self._client.get_params(API_SYS_PARAMS_URI)
    reg_params = await self._fetch_reg_key(API_REG_PARAMS_URI, API_REG_PARAMS_PARAM_DATA)
    _LOGGER.warning (
            "All parameters list sys:"+ str(len(sys_params)) + ", reg:" + str(len(reg_params)) +" "
    )
    return sys_params + reg_params

maybe you can help me how I can get data from sysParams I want to add to Diagnostic: keys: lan: true or false, wifi: true or false