I was just doing something similar. The code below works for me with the caveat that for my use-case the active/inactive status would ideally not be reversed. I really wish that all of the logic for covers was in the back end rather than some of it living the front end.
cover:
- platform: template
covers:
cover_screen_reversed:
friendly_name: "Screen Reversed"
position_template: "{{ 100 - state_attr('cover.screen', 'current_position') | int(100) }}"
value_template: >-
{% if is_state('cover.screen', 'closing') %}
opening
{% elif is_state('cover.screen', 'opening') %}
closing
{% else %}
none
{% endif %}
open_cover:
service: cover.close_cover
data: {}
target:
entity_id: cover.screen
close_cover:
service: cover.open_cover
data: {}
target:
entity_id: cover.screen
stop_cover:
service: cover.stop_cover
data: {}
target:
entity_id: cover.screen
set_cover_position:
service: cover.set_cover_position
data:
position: "{{100-position}}"
entity_id: cover.screen
icon_template: >-
{% if is_state('cover.screen', 'closed') %}
mdi:projector-screen-variant-off-outline
{% elif is_state('cover.screen', 'closing') %}
mdi:arrow-up-box
{% elif is_state('cover.screen', 'opening') %}
mdi:arrow-down-box
{% else %}
mdi:projector-screen-variant-outline
{% endif %}
Hope that it makes sense to post this here - the forum is warning me that this thread is now closed but your post looks relatively recent.