Cover open/close for 50%

Hello colleques! How to close/open cover for 50% (or another) with platform: endstop cover? Thanks

switch:
  - platform: gpio
    pin: GPIO6 #INT1
    id: switch1_open
    name: switch1_open
    inverted: true
    internal: true
    restore_mode: RESTORE_DEFAULT_OFF  ##ALWAYS_OFF
  - platform: gpio
    pin: GPIO5 #INT2
    id: switch1_close
    name: switch1_close
    inverted: true
    internal: true 
    restore_mode: RESTORE_DEFAULT_OFF  ##ALWAYS_OFF
  - platform: gpio
    pin: GPIO1 #INT3
    id: switch2_open
    name: switch2_open
    inverted: true
    internal: true 
    restore_mode: RESTORE_DEFAULT_OFF  ##ALWAYS_OFF
  - platform: gpio
    pin: GPIO2 #INT4
    id: switch2_close
    name: switch2_close
    inverted: true
    internal: true 
    restore_mode: RESTORE_DEFAULT_OFF  ##ALWAYS_OFF
##############
cover:
  - platform: endstop
    device_class: gate
    name: "Gatefirst"
    id: Gatefirst
    #max_duration: 60s
    #update_interval: 1s
    #has_built_in_endstop: true
    #has_built_in_endstop: true
    #infer_endstop_from_movement: true
    ###################################3
    open_action:
      - switch.turn_on: switch1_open
    open_duration: 45s
    open_endstop: open_endstop_binary_sensor1
    #open_sensor: open_movement_binary_sensor
    close_action:
      - switch.turn_on: switch1_close
    close_duration: 45s
    close_endstop: close_endstop_binary_sensor1
    #close_sensor: close_movement_binary_sensor
    stop_action:
      - switch.turn_off: switch1_open
      - switch.turn_off: switch1_close
    on_open:
      - logger.log: "Cover is Open!"
    on_closed:
      - logger.log: "Cover is Closed!"
 
# Example configuration entry
  - platform: endstop
    name: "Gatesecond"
    device_class: gate
    id: Gatesecond
    max_duration: 20s
    #update_interval: 1s
    open_action:
      - switch.turn_on: switch2_open
    open_duration: 15sec
    open_endstop: open_endstop_binary_sensor2

    close_action:
      - switch.turn_on: switch2_close
    close_duration: 15sec
    close_endstop: close_endstop_binary_sensor2

    stop_action:
      - switch.turn_off: switch2_open
      - switch.turn_off: switch2_close  
#
#################################################################################
#
#
binary_sensor:
  - platform: gpio
    pin:
      number: GPIO9
      mode: INPUT_PULLUP
      #inverted: true
    id: open_endstop_binary_sensor1
    name: open_endstop_binary_sensor1
    filters:
      - invert:
      - delayed_on: 100ms
      - delayed_off: 100ms
    #on_press:
    #- logger.log: "Sensor 1 Door closed"
  - platform: gpio
    pin:
      number: GPIO10
      mode: INPUT_PULLUP
      #inverted: true
    id: close_endstop_binary_sensor1
    name: close_endstop_binary_sensor1
    filters:
      - invert:
      - delayed_on: 100ms
      - delayed_off: 100ms
    #on_press:
    #- logger.log: "Sensor 1 Door open"
    #
  - platform: gpio
    pin:
      number: GPIO20
      mode: INPUT_PULLUP
      #inverted: true
    id: open_endstop_binary_sensor2
    name: open_endstop_binary_sensor2
    filters:
      - invert:
      - delayed_on: 100ms
      - delayed_off: 100ms
    #on_press:
    #- logger.log: "Sensor 2 Door closed"
  - platform: gpio
    pin:
      number: GPIO21
      mode: INPUT_PULLUP
      #inverted: true
    id: close_endstop_binary_sensor2
    name: close_endstop_binary_sensor2
    filters:
      - invert:
      - delayed_on: 100ms
      - delayed_off: 100ms
    #on_press:
    #- logger.log: "Sensor 2 Door open"