Skip to content

Commit aec426e

Browse files
committed
Enhance HomeKit configuration by refining entity management and improving compatibility with Alexa. Update comments for clarity on multi-bridge setup.
1 parent 1835b12 commit aec426e

File tree

1 file changed

+27
-0
lines changed

1 file changed

+27
-0
lines changed
Lines changed: 27 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,27 @@
1+
blueprint:
2+
name: Invert a binary sensor
3+
description: Creates a binary_sensor which holds the inverted value of a reference binary_sensor
4+
domain: template
5+
source_url: https://github.com/home-assistant/core/blob/dev/homeassistant/components/template/blueprints/inverted_binary_sensor.yaml
6+
input:
7+
reference_entity:
8+
name: Binary sensor to be inverted
9+
description: The binary_sensor which needs to have its value inverted
10+
selector:
11+
entity:
12+
domain: binary_sensor
13+
variables:
14+
reference_entity: !input reference_entity
15+
binary_sensor:
16+
state: >
17+
{% if states(reference_entity) == 'on' %}
18+
off
19+
{% elif states(reference_entity) == 'off' %}
20+
on
21+
{% else %}
22+
{{ states(reference_entity) }}
23+
{% endif %}
24+
# delay_on: not_used in this example
25+
# delay_off: not_used in this example
26+
# auto_off: not_used in this example
27+
availability: "{{ states(reference_entity) not in ('unknown', 'unavailable') }}"

0 commit comments

Comments
 (0)