Migrate everything into the Garadget Package. #642
This commit is contained in:
parent
3480711eda
commit
64d3054019
|
@ -6,7 +6,6 @@
|
||||||
# Switch to Access_Tokens - https://www.vcloudinfo.com/2020/05/fixing-garadget-in-home-assistant.html
|
# Switch to Access_Tokens - https://www.vcloudinfo.com/2020/05/fixing-garadget-in-home-assistant.html
|
||||||
#-------------------------------------------
|
#-------------------------------------------
|
||||||
|
|
||||||
|
|
||||||
cover:
|
cover:
|
||||||
- platform: garadget
|
- platform: garadget
|
||||||
covers:
|
covers:
|
||||||
|
@ -77,27 +76,16 @@ sensor:
|
||||||
value_template: '{{ value_json.bright }}'
|
value_template: '{{ value_json.bright }}'
|
||||||
|
|
||||||
group:
|
group:
|
||||||
garadget:
|
|
||||||
name: Garadget Sensors
|
|
||||||
entities:
|
|
||||||
- cover.large_garage
|
|
||||||
- sensor.large_garage_status
|
|
||||||
- sensor.large_garage_time_in_state
|
|
||||||
- sensor.large_garage_wifi_signal_strength
|
|
||||||
- sensor.large_garage_reflection_rate
|
|
||||||
- sensor.large_garage_brightness
|
|
||||||
- cover.small_garage
|
|
||||||
- sensor.small_garage_status
|
|
||||||
- sensor.small_garage_time_in_state
|
|
||||||
- sensor.small_garage_wifi_signal_strength
|
|
||||||
- sensor.small_garage_reflection_rate
|
|
||||||
- sensor.small_garage_brightness
|
|
||||||
garage_doors:
|
garage_doors:
|
||||||
name: Garage Doors
|
name: Garage Doors
|
||||||
entities:
|
entities:
|
||||||
- cover.large_garage
|
- cover.large_garage
|
||||||
- cover.small_garage
|
- cover.small_garage
|
||||||
|
|
||||||
|
######################################################################
|
||||||
|
## Garage Status Announcements - Only during normal hours.
|
||||||
|
######################################################################
|
||||||
|
|
||||||
automation:
|
automation:
|
||||||
- alias: 'Update Garage Brightness'
|
- alias: 'Update Garage Brightness'
|
||||||
trigger:
|
trigger:
|
||||||
|
@ -112,3 +100,91 @@ automation:
|
||||||
data:
|
data:
|
||||||
topic: "garadget/Garadget Large/command"
|
topic: "garadget/Garadget Large/command"
|
||||||
payload: "get-status"
|
payload: "get-status"
|
||||||
|
|
||||||
|
- alias: 'Garage Door State Change'
|
||||||
|
|
||||||
|
trigger:
|
||||||
|
- platform: state
|
||||||
|
entity_id:
|
||||||
|
- cover.large_garage
|
||||||
|
- cover.small_garage
|
||||||
|
from: 'open'
|
||||||
|
to: 'closed'
|
||||||
|
for: '00:02:00'
|
||||||
|
|
||||||
|
- platform: state
|
||||||
|
entity_id:
|
||||||
|
- cover.large_garage
|
||||||
|
- cover.small_garage
|
||||||
|
from: 'closed'
|
||||||
|
to: 'open'
|
||||||
|
for: '00:02:30'
|
||||||
|
|
||||||
|
action:
|
||||||
|
# - service_template: >
|
||||||
|
# {% set hour=states("sensor.time").split(':')[0] | int %}
|
||||||
|
# {% if hour >= 7 and hour <= 9 and states.input_boolean.school_mode.state == 'on'%}
|
||||||
|
# input_boolean.turn_off
|
||||||
|
# {% else %}
|
||||||
|
# input_boolean.turn_on
|
||||||
|
# {% endif %}
|
||||||
|
# entity_id: input_boolean.alert_mode
|
||||||
|
|
||||||
|
- service: script.speech_engine
|
||||||
|
data_template:
|
||||||
|
DoorClosed: "The {{ trigger.entity_id.split('.')[1]|replace('_', ' ') }} is now {{ (trigger.to_state.state)|replace('_', ' ') }}."
|
||||||
|
call_garage_check: 1
|
||||||
|
|
||||||
|
###################################
|
||||||
|
## Garadget Wind Door Checks - [Garadget](https://amzn.to/2jQLpVQ)
|
||||||
|
###################################
|
||||||
|
|
||||||
|
- alias: 'Wind Speed Garage Door Check'
|
||||||
|
trigger:
|
||||||
|
- platform: numeric_state
|
||||||
|
entity_id: sensor.dark_sky_wind_speed
|
||||||
|
above: 20
|
||||||
|
|
||||||
|
condition:
|
||||||
|
- condition: or
|
||||||
|
conditions:
|
||||||
|
- condition: template
|
||||||
|
value_template: "{{ states('cover.large_garage') == 'opened' }}"
|
||||||
|
- condition: template
|
||||||
|
value_template: "{{ states('cover.small_garage') == 'opened'}}"
|
||||||
|
|
||||||
|
action:
|
||||||
|
- service: input_boolean.turn_on
|
||||||
|
entity_id: input_boolean.alert_mode
|
||||||
|
|
||||||
|
- service: script.notify_engine
|
||||||
|
data_template:
|
||||||
|
title: 'Check/Close Garage Doors - High Speed Wind Alert:'
|
||||||
|
value1: "Small: {{ states('cover.small_garage')}}"
|
||||||
|
value2: "Large: {{ states('cover.large_garage')}}"
|
||||||
|
apns_id: 'information'
|
||||||
|
who: 'parents'
|
||||||
|
|
||||||
|
- service: script.speech_engine
|
||||||
|
data_template:
|
||||||
|
value1: >
|
||||||
|
"The winds are picking up outside. The wind speed is {{ states('sensor.dark_sky_wind_speed')|round}} miles per hour. For safety, please close the garage doors.
|
||||||
|
{% if is_state('cover.large_garage', 'open') -%}
|
||||||
|
The Large Garage Door is open
|
||||||
|
{% endif -%}
|
||||||
|
{% if is_state('cover.small_garage', 'open') -%}
|
||||||
|
{% if is_state('cover.large_garage', 'open') -%}and
|
||||||
|
{%- endif %} The small Garage Door is open.
|
||||||
|
{% endif %}"
|
||||||
|
|
||||||
|
- service: script.tweet_engine_image
|
||||||
|
data_template:
|
||||||
|
tweet: >
|
||||||
|
{{ [
|
||||||
|
"Wind speed is {{ states('sensor.dark_sky_wind_speed')|round}} miles per hour. For safety, I'm going to close the @garadget doors.",
|
||||||
|
"Getting pretty windy! {{ states('sensor.dark_sky_wind_speed')|round}}MPH. Time to ask @Garadget to close the garage doors."
|
||||||
|
] | random + "(http://amzn.to/2jQLpVQ)"}}
|
||||||
|
image: >-
|
||||||
|
{{ [
|
||||||
|
"/config/www/custom_ui/floorplan/images/branding/windy.png"
|
||||||
|
] | random }}
|
||||||
|
|
Loading…
Reference in New Issue