Hi, I have a problem with the shutter switches when integrating them with home assistant, it works with tuya application works perfect, the manual switch also, but the problem is that in home assistant when I give it to down, the switch gets the down icon and quickly changes to up (0.3s approx). I want it to work well, or reversing the direction of the motor from HA, or try not to make this change of direction, as the switches perceive the signal well, but quickly changes it to the other side. These switches are WIFI, I have a very basic level of HA programming, and so I would like someone to help me, so I have to say that I have 6 of the brand, and they all go the same (inverted). I searched in other forums, and they give a code of Z-WAVE JS but I have no idea what that is, if someone can pass me a code and tell me step by step where I have to put it. Thank you very much.
Hi Iker Popescu,
This is a common request. The only current fix appears to be to create a template sensor to flip the response that you can feed back to your automations.
I’ve seen this request 2x in the last 3 days. There is a feature request and a WTH about it as well. Search them out and vote for them.
Hi, thanks for the reply, I’ve been looking around and decided to make a system to create new inverted entities, so the program can continue using everything and it works perfectly. Thank you very much.
Here is the code (configuration.yaml)
cover:
- platform: template
covers:
persiana_habitacion_2_cortina_invertida:
friendly_name: "Persiana Habitación 2 Cortina (Invertida)"
open_cover:
service: cover.close_cover
target:
entity_id: cover.persiana_habitacion_2_cortina
close_cover:
service: cover.open_cover
target:
entity_id: cover.persiana_habitacion_2_cortina
stop_cover:
service: cover.stop_cover
target:
entity_id: cover.persiana_habitacion_2_cortina
position_template: "{{ 100 - state_attr('cover.persiana_habitacion_2_cortina', 'current_position') }}"
set_cover_position:
service: cover.set_cover_position
target:
entity_id: cover.persiana_habitacion_2_cortina
data_template:
position: "{{ 100 - position }}"
persiana_habitacion_1_invertida:
friendly_name: "Persiana Habitación 1 (Invertida)"
open_cover:
service: cover.close_cover
target:
entity_id: cover.persiana_habitacion_1
close_cover:
service: cover.open_cover
target:
entity_id: cover.persiana_habitacion_1
stop_cover:
service: cover.stop_cover
target:
entity_id: cover.persiana_habitacion_1
position_template: "{{ 100 - state_attr('cover.persiana_habitacion_1', 'current_position') }}"
set_cover_position:
service: cover.set_cover_position
target:
entity_id: cover.persiana_habitacion_1
data_template:
position: "{{ 100 - position }}"
persiana_habitacion_3_cortina_invertida:
friendly_name: "Persiana Habitación 3 Cortina (Invertida)"
open_cover:
service: cover.close_cover
target:
entity_id: cover.persiana_habitacion_3_cortina
close_cover:
service: cover.open_cover
target:
entity_id: cover.persiana_habitacion_3_cortina
stop_cover:
service: cover.stop_cover
target:
entity_id: cover.persiana_habitacion_3_cortina
position_template: "{{ 100 - state_attr('cover.persiana_habitacion_3_cortina', 'current_position') }}"
set_cover_position:
service: cover.set_cover_position
target:
entity_id: cover.persiana_habitacion_3_cortina
data_template:
position: "{{ 100 - position }}"
persiana_arriba_1_cortina_invertida:
friendly_name: "Persiana Arriba 1 Cortina (Invertida)"
open_cover:
service: cover.close_cover
target:
entity_id: cover.persiana_arriba_1_cortina
close_cover:
service: cover.open_cover
target:
entity_id: cover.persiana_arriba_1_cortina
stop_cover:
service: cover.stop_cover
target:
entity_id: cover.persiana_arriba_1_cortina
position_template: "{{ 100 - state_attr('cover.persiana_arriba_1_cortina', 'current_position') }}"
set_cover_position:
service: cover.set_cover_position
target:
entity_id: cover.persiana_arriba_1_cortina
data_template:
position: "{{ 100 - position }}"
persiana_arriba_2_cortina_invertida:
friendly_name: "Persiana Arriba 2 Cortina (Invertida)"
open_cover:
service: cover.close_cover
target:
entity_id: cover.persiana_arriba_2_cortina
close_cover:
service: cover.open_cover
target:
entity_id: cover.persiana_arriba_2_cortina
stop_cover:
service: cover.stop_cover
target:
entity_id: cover.persiana_arriba_2_cortina
position_template: "{{ 100 - state_attr('cover.persiana_arriba_2_cortina', 'current_position') }}"
set_cover_position:
service: cover.set_cover_position
target:
entity_id: cover.persiana_arriba_2_cortina
data_template:
position: "{{ 100 - position }}"
persiana_bano_cortina_invertida:
friendly_name: "Persiana Baño Cortina (Invertida)"
open_cover:
service: cover.close_cover
target:
entity_id: cover.persiana_bano_cortina
close_cover:
service: cover.open_cover
target:
entity_id: cover.persiana_bano_cortina
stop_cover:
service: cover.stop_cover
target:
entity_id: cover.persiana_bano_cortina
position_template: "{{ 100 - state_attr('cover.persiana_bano_cortina', 'current_position') }}"
set_cover_position:
service: cover.set_cover_position
target:
entity_id: cover.persiana_bano_cortina
data_template:
position: "{{ 100 - position }}"