Knx cover entitiy

Hi,

when I create a cover entity for my covers, the behave not as expected. I use MDT aktors and in terms of position they are default configured as follows:

0% means they are fully opened.
100% means they are fully closed.

When I configure the cover entity and don’t toggle the invert button, the UI shows the following when they are fully closed:


Somehow the state is correct, however the position is not shown correct. The position address defnitly has 100% value instead of 0%, so it is inverted by the knx enitity.
When I setup the invert button here, the persentage is shown correctly, but the state is then shown wrongly:

This gives the following UI:

Any idea how to set them up they way they are treated by MDT by default (and in my opinion as it is natural)?

Hi :wave:!
Please have a look at the documentation: https://www.home-assistant.io/integrations/knx/#cover

Unlike most KNX devices, Home Assistant defines 0% as closed and 100% as fully open in regards to covers.

And there is no way to implement a setting in the knx entity to get rid of this strange behavior?

This is a definition of Home Assistants entity model. So, no.

See WHY THE HECK can't we freely configure a Cover to interpret its percentage value as "percentage open" or "percentage closed"?

and Cover entities that are 0% = open and 100% = closed

I have tried to handle this via a separate inverted cover template like this:

  cover:
    - name: "Jalousie Esszimmer Süd Position"
      unique_id: esszimmer_jalousie_sud_position_inverted
      device_class: blind

      position: >
         {{ 100 - state_attr('cover.esszimmer_jalousie_sud_position', 'current_position') | int(0) }}

      set_cover_position:
        action: cover.set_cover_position
        target:
          entity_id: cover.esszimmer_jalousie_sud_position
        data:
          position: "{{ 100 - position }}"

      open_cover:
        action: cover.open_cover
        target:
          entity_id: cover.esszimmer_jalousie_sud_position

      close_cover:
        action: cover.close_cover
        target:
          entity_id: cover.esszimmer_jalousie_sud_position

      stop_cover:
        action: cover.stop_cover
        target:
          entity_id: cover.esszimmer_jalousie_sud_position

      icon: >
        {% if is_state('cover.esszimmer_jalousie_sud_position', 'closed') %}
          mdi:window-shutter
        {% else %}
          mdi:window-shutter-open
        {% endif %}

I use the cover/slider type of a bubble card and when activating the Show entity state it always says the wrong state. In my case 0-98% means open and 99-100% means closed. I tried to override the state via:

    state: >
      {% set p = 100 - state_attr('cover.esszimmer_jalousie_sud_lamellen', 'current_position') | int(0) %}
      {% if p >= 99 %}
        closed
      {% else %}
        open
      {% endif %}

but this doesn’t work. Does anybody know how to override the state object?