How to configure covers (Z2MQTT) open/close state?

Hi all,

I am currently migrating from ZHA to Zigbee2MQTT so I am going through the painful process of resetting / readding all my devices.

I have a roller blind (this one) that I managed to add to Z2MQTT but I cannot figure out how to control it and I am going insane …

My roller blind:

  • is longer than the window, so I need to somehow ‘tell’ HA that 57% is the closed state
  • can roll over (so if it continues beyond the 0% when opening, which it does, it just rolls over indefinitely )

I can open / close them by clicking on “stop” at the exact time, but obviously I do not want to be doing that … Can someone ELI5 to me how is this supposed to work? :slight_smile:

(the ZHA integration was opening / closing them based on whatever the border/limit settings are on the remote)

This is what I currently see in the state, but again, I had to stop the “close” by manually pressing stop :frowning:

I feel like I am missing something major here, as this is the only cover I own and because I never had to configure anything for it before, I don’t really have a good grasp about how is this supposed to work …

{
    "battery": 100,
    "border": "remove_top_bottom",
    "click_control": "down",
    "linkquality": 150,
    "position": 0,
    "reverse_direction": "back",
    "state": "CLOSE",
    "motor_fault": null
}

Something like this:

automation:
  - id: maker_space_blind_close_override
    alias: "Maker Space Blind - Override Close Position"
    description: "When close is called, go to position 57 instead of 0"
    
    trigger:
      - platform: state
        entity_id: cover.maker_space_blind
        to: 'closing'
      - platform: event
        event_type: call_service
        event_data:
          domain: cover
          service: close_cover
          service_data:
            entity_id: cover.maker_space_blind
    
    condition:
      - condition: state
        entity_id: cover.maker_space_blind
        state: 'closing'
    
    action:
      - delay:
          milliseconds: 100
      - service: cover.set_cover_position
        target:
          entity_id: cover.maker_space_blind
        data:
          position: 57

If Z2M is ignoring the limits set by the remote you need to open an issue.