mirror of
https://github.com/CCOSTAN/Home-AssistantConfig.git
synced 2025-08-20 12:10:28 +00:00
You can find the entire repo here.
This commit is contained in:
36
config/packages/README.md
Executable file
36
config/packages/README.md
Executable file
@@ -0,0 +1,36 @@
|
||||
# [](https://travis-ci.org/CCOSTAN/Home-AssistantConfig) Home-Assistant Config by [@ccostan](http://www.twitter.com/ccostan)
|
||||
[Home Assistant](https://home-assistant.io/) configuration files (YAMLs)
|
||||
|
||||
Be sure to :star: my repo so you can keep up to date on the daily progress!
|
||||
|
||||
This section is for the packages. (It's being slowly built out)
|
||||
|
||||
**Twitter Account**
|
||||
-You can see my home in action by following it's Twitter account [@BearStoneHA](https://twitter.com/BearStoneHA)
|
||||
-Home Assistant live tweets activities in the house on it's own dedicated Social Media Account.
|
||||
|
||||
**Alarm System**
|
||||
You can find out about how I swapped out my ADT for 3 NodeMCUs [here](http://www.vmwareinfo.com/2017/06/building-my-home-alarm-system-hardware.html).
|
||||
|
||||
**Landscape Lighting**
|
||||
For the ladnscape lights, I have 2 12v transformers in the backyard. One powers the front landscape lights and the other the backyard landscaping lights.
|
||||
I have put 2 [GE ZWave Outdoor Power Module](http://amzn.to/2q17R4S) conneted to the transformers and controlled by my [Wink Hub](http://amzn.to/2orGEWo). They are set to turn on landscape lighting at sunset and turn off at random times before sunrise.
|
||||

|
||||
|
||||
**Nest Protects**
|
||||
You can find my [Nest protects](http://amzn.to/2poqKhu) write up [here](http://www.vmwareinfo.com/2017/06/psa-check-out-your-smoke-detectors-once.html).
|
||||
 and thermostats [here](http://www.vmwareinfo.com/2018/02/smart-home-basics-thermostats.html)
|
||||
|
||||
<td>
|
||||
<tr>
|
||||
<a href="https://www.amazon.com/Nest-Protect-Carbon-Monoxide-Generation/dp/B00XV1RD0K/ref=as_li_ss_il?s=hi&ie=UTF8&qid=1519154145&sr=1-4&keywords=nest+protect&linkCode=li1&tag=vmw0a-20&linkId=7002d3f6bb9c7680a653a1658a89d453" target="_blank"><img border="0" src="https://ws-na.amazon-adsystem.com/widgets/q?_encoding=UTF8&ASIN=B00XV1RD0K&Format=_SL110_&ID=AsinImage&MarketPlace=US&ServiceVersion=20070822&WS=1&tag=vmw0a-20" ></a><img src="https://ir-na.amazon-adsystem.com/e/ir?t=vmw0a-20&l=li1&o=1&a=B00XV1RD0K" width="1" height="1" border="0" alt="" style="border:none !important; margin:0px !important;" /></tr></td>
|
||||
|
||||
**Neato Vacuum**
|
||||
I can control my [Neato Vacuum](http://amzn.to/2kqnnqu) with Home Assistant.
|
||||

|
||||
|
||||
#Still have questions on my Config?
|
||||
Follow me on twitter : [@CCostan](https://twitter.com/ccostan)
|
||||
Follow the Smart Home on twitter : [@BearStoneHA](https://twitter.com/BearStoneHA)
|
||||
|
||||
You can also vist my [Blog](http://www.vmwareinfo.com/search/label/iot) for all of my [Home Automation Posts](http://www.vmwareinfo.com/search/label/iot).
|
314
config/packages/alarm.yaml
Executable file
314
config/packages/alarm.yaml
Executable file
@@ -0,0 +1,314 @@
|
||||
#-------------------------------------------
|
||||
# ALarm Related Packages
|
||||
# @CCOSTAN
|
||||
# Original Repo : https://github.com/CCOSTAN/Home-AssistantConfig
|
||||
#-------------------------------------------
|
||||
homeassistant:
|
||||
customize_glob:
|
||||
"device_tracker.nodemcu*":
|
||||
icon: mdi:chip
|
||||
|
||||
hidden: False
|
||||
"binary_sensor.mcu?_gpio*":
|
||||
icon: mdi:security-home
|
||||
|
||||
hidden: False
|
||||
|
||||
customize:
|
||||
binary_sensor.MCU1_GPIO4:
|
||||
friendly_name: 'Paige Window'
|
||||
binary_sensor.MCU1_GPIO5:
|
||||
friendly_name: 'Front Door'
|
||||
binary_sensor.MCU1_GPIO10:
|
||||
friendly_name: 'Dining Room Windows'
|
||||
binary_sensor.MCU1_GPIO12:
|
||||
friendly_name: 'Interior Garage Door'
|
||||
binary_sensor.MCU1_GPIO13:
|
||||
friendly_name: 'Front Den Windows'
|
||||
binary_sensor.MCU1_GPIO14:
|
||||
friendly_name: 'Office Window'
|
||||
|
||||
|
||||
binary_sensor.MCU2_GPIO4:
|
||||
friendly_name: 'Dinette Windows'
|
||||
binary_sensor.MCU2_GPIO5:
|
||||
friendly_name: 'Back Door'
|
||||
binary_sensor.MCU2_GPIO9:
|
||||
friendly_name: 'Master Slider'
|
||||
binary_sensor.MCU2_GPIO10:
|
||||
friendly_name: 'Master Bathroom Window'
|
||||
binary_sensor.MCU2_GPIO12:
|
||||
friendly_name: 'Main Slider'
|
||||
binary_sensor.MCU2_GPIO13:
|
||||
friendly_name: 'Upstairs Bedroom Window'
|
||||
binary_sensor.MCU2_GPIO14:
|
||||
friendly_name: 'Justin Window'
|
||||
|
||||
binary_sensor.MCU3_GPIO4:
|
||||
friendly_name: 'Stacey Bedroom Window'
|
||||
binary_sensor.MCU3_GPIO5:
|
||||
friendly_name: 'Carlo Bedroom Window'
|
||||
binary_sensor.MCU3_GPIO10:
|
||||
friendly_name: 'Master Bedroom Window'
|
||||
binary_sensor.MCU3_GPIO14:
|
||||
friendly_name: 'Upstairs Windows'
|
||||
binary_sensor.MCU3_Light:
|
||||
friendly_name: 'Panel Door'
|
||||
|
||||
group.entry_points:
|
||||
friendly_name: Alarm Entry Points
|
||||
homebridge_hidden: true
|
||||
group.interior_door:
|
||||
friendly_name: Interior doors
|
||||
homebridge_hidden: true
|
||||
#-------------------------------------------
|
||||
binary_sensor:
|
||||
- platform: mqtt
|
||||
state_topic: "NodeMCU1/GPIO4/Status"
|
||||
name: "MCU1_GPIO4"
|
||||
payload_on: 1
|
||||
payload_off: 0
|
||||
device_class: opening
|
||||
- platform: mqtt
|
||||
state_topic: "NodeMCU1/GPIO5/Status"
|
||||
name: "MCU1_GPIO5"
|
||||
payload_on: 1
|
||||
payload_off: 0
|
||||
device_class: opening
|
||||
- platform: mqtt
|
||||
state_topic: "NodeMCU1/GPIO10/Status"
|
||||
name: "MCU1_GPIO10"
|
||||
payload_on: 1
|
||||
payload_off: 0
|
||||
device_class: opening
|
||||
- platform: mqtt
|
||||
state_topic: "NodeMCU1/GPIO12/Status"
|
||||
name: "MCU1_GPIO12"
|
||||
payload_on: 1
|
||||
payload_off: 0
|
||||
device_class: opening
|
||||
- platform: mqtt
|
||||
state_topic: "NodeMCU1/GPIO13/Status"
|
||||
name: "MCU1_GPIO13"
|
||||
payload_on: 1
|
||||
payload_off: 0
|
||||
device_class: opening
|
||||
- platform: mqtt
|
||||
state_topic: "NodeMCU1/GPIO14/Status"
|
||||
name: "MCU1_GPIO14"
|
||||
payload_on: 1
|
||||
payload_off: 0
|
||||
device_class: opening
|
||||
|
||||
- platform: mqtt
|
||||
state_topic: "NodeMCU2/GPIO4/Status"
|
||||
name: "MCU2_GPIO4"
|
||||
payload_on: 1
|
||||
payload_off: 0
|
||||
device_class: opening
|
||||
- platform: mqtt
|
||||
state_topic: "NodeMCU2/GPIO5/Status"
|
||||
name: "MCU2_GPIO5"
|
||||
payload_on: 1
|
||||
payload_off: 0
|
||||
device_class: opening
|
||||
- platform: mqtt
|
||||
state_topic: "NodeMCU2/GPIO9/Status"
|
||||
name: "MCU2_GPIO9"
|
||||
payload_on: 1
|
||||
payload_off: 0
|
||||
device_class: opening
|
||||
- platform: mqtt
|
||||
state_topic: "NodeMCU2/GPIO10/Status"
|
||||
name: "MCU2_GPIO10"
|
||||
payload_on: 1
|
||||
payload_off: 0
|
||||
device_class: opening
|
||||
- platform: mqtt
|
||||
state_topic: "NodeMCU2/GPIO12/Status"
|
||||
name: "MCU2_GPIO12"
|
||||
payload_on: 1
|
||||
payload_off: 0
|
||||
device_class: opening
|
||||
- platform: mqtt
|
||||
state_topic: "NodeMCU2/GPIO13/Status"
|
||||
name: "MCU2_GPIO13"
|
||||
payload_on: 1
|
||||
payload_off: 0
|
||||
device_class: opening
|
||||
- platform: mqtt
|
||||
state_topic: "NodeMCU2/GPIO14/Status"
|
||||
name: "MCU2_GPIO14"
|
||||
payload_on: 1
|
||||
payload_off: 0
|
||||
device_class: opening
|
||||
|
||||
- platform: mqtt
|
||||
state_topic: "NodeMCU3/GPIO4/Status"
|
||||
name: "MCU3_GPIO4"
|
||||
payload_on: 1
|
||||
payload_off: 0
|
||||
device_class: opening
|
||||
- platform: mqtt
|
||||
state_topic: "NodeMCU3/GPIO5/Status"
|
||||
name: "MCU3_GPIO5"
|
||||
payload_on: 1
|
||||
payload_off: 0
|
||||
device_class: opening
|
||||
- platform: mqtt
|
||||
state_topic: "NodeMCU3/GPIO10/Status"
|
||||
name: "MCU3_GPIO10"
|
||||
payload_on: 1
|
||||
payload_off: 0
|
||||
device_class: opening
|
||||
- platform: mqtt
|
||||
state_topic: "NodeMCU3/GPIO14/Status"
|
||||
name: "MCU3_GPIO14"
|
||||
payload_on: 1
|
||||
payload_off: 0
|
||||
device_class: opening
|
||||
- platform: mqtt
|
||||
state_topic: "NodeMCU3/Light/Status"
|
||||
name: "MCU3_Light"
|
||||
payload_on: 1
|
||||
payload_off: 0
|
||||
device_class: opening
|
||||
|
||||
# input_boolean:
|
||||
# elephant:
|
||||
# name: Elephant
|
||||
# initial: off
|
||||
#-------------------------------------------
|
||||
group:
|
||||
entry_points:
|
||||
entities:
|
||||
- binary_sensor.MCU1_GPIO4
|
||||
- binary_sensor.MCU1_GPIO5
|
||||
- binary_sensor.MCU1_GPIO10
|
||||
- binary_sensor.MCU1_GPIO12
|
||||
- binary_sensor.MCU1_GPIO13
|
||||
- binary_sensor.MCU1_GPIO14
|
||||
- binary_sensor.MCU2_GPIO4
|
||||
- binary_sensor.MCU2_GPIO5
|
||||
- binary_sensor.MCU2_GPIO9
|
||||
- binary_sensor.MCU2_GPIO10
|
||||
- binary_sensor.MCU2_GPIO12
|
||||
- binary_sensor.MCU2_GPIO13
|
||||
- binary_sensor.MCU2_GPIO14
|
||||
- binary_sensor.MCU2_GPIO15
|
||||
- binary_sensor.MCU3_GPIO4
|
||||
- binary_sensor.MCU3_GPIO5
|
||||
- binary_sensor.MCU3_GPIO10
|
||||
- binary_sensor.MCU3_GPIO14
|
||||
# interior_door: - Moved out to Doors Group.
|
||||
# entities:
|
||||
# - binary_sensor.kitchen_door_opened
|
||||
# - binary_sensor.MCU3_Light
|
||||
#-------------------------------------------#-------------------------------------------
|
||||
automation:
|
||||
- alias: 'Turn off HVAC in window/door is opened'
|
||||
trigger:
|
||||
- platform: state
|
||||
entity_id:
|
||||
- binary_sensor.MCU1_GPIO4
|
||||
- binary_sensor.MCU1_GPIO5
|
||||
- binary_sensor.MCU1_GPIO10
|
||||
- binary_sensor.MCU1_GPIO12
|
||||
- binary_sensor.MCU1_GPIO13
|
||||
- binary_sensor.MCU1_GPIO14
|
||||
- binary_sensor.MCU2_GPIO4
|
||||
- binary_sensor.MCU2_GPIO5
|
||||
- binary_sensor.MCU2_GPIO9
|
||||
- binary_sensor.MCU2_GPIO10
|
||||
- binary_sensor.MCU2_GPIO12
|
||||
- binary_sensor.MCU2_GPIO13
|
||||
- binary_sensor.MCU2_GPIO14
|
||||
- binary_sensor.MCU3_GPIO4
|
||||
- binary_sensor.MCU3_GPIO5
|
||||
- binary_sensor.MCU3_GPIO10
|
||||
- binary_sensor.MCU3_GPIO14
|
||||
to: 'on'
|
||||
from: 'off'
|
||||
for:
|
||||
minutes: 5
|
||||
|
||||
condition:
|
||||
- condition: template
|
||||
value_template: "{{ states('climate.downstairs') != 'off' }}"
|
||||
|
||||
action:
|
||||
- service: climate.set_operation_mode
|
||||
data:
|
||||
entity_id: climate.downstairs
|
||||
operation_mode: 'off'
|
||||
- service: script.speech_engine
|
||||
data_template:
|
||||
value1: "The {{ trigger.to_state.attributes.friendly_name }} has been opened for about 5 minutes. I will shut down the Air Conditioner so you can enjoy the fresh air."
|
||||
call_outside_weather: 1
|
||||
call_inside_weather: 1
|
||||
#-------------------------------------------#-------------------------------------------
|
||||
- alias: 'Turn HVAC back on when all doors/windows are closed.'
|
||||
trigger:
|
||||
- platform: state
|
||||
entity_id:
|
||||
- group.entry_points
|
||||
to: 'off'
|
||||
from: 'on'
|
||||
for:
|
||||
minutes: 5
|
||||
|
||||
condition:
|
||||
- condition: template
|
||||
value_template: "{{ states('climate.downstairs') == 'off' }}"
|
||||
|
||||
action:
|
||||
- service: climate.set_operation_mode
|
||||
data:
|
||||
entity_id: climate.downstairs
|
||||
operation_mode: 'auto'
|
||||
|
||||
#-------------------------------------------#-------------------------------------------
|
||||
- alias: 'Alarm lights in Living room'
|
||||
trigger:
|
||||
- platform: state
|
||||
entity_id:
|
||||
- group.entry_points
|
||||
- platform: state
|
||||
entity_id: group.all_covers
|
||||
|
||||
condition:
|
||||
condition: and
|
||||
conditions:
|
||||
- condition: state
|
||||
entity_id: sun.sun
|
||||
state: 'below_horizon'
|
||||
- condition: state
|
||||
entity_id: group.bed
|
||||
state: 'off'
|
||||
|
||||
action:
|
||||
- service: light.turn_on
|
||||
entity_id:
|
||||
- group.living_room_accents
|
||||
data_template:
|
||||
color_name: >
|
||||
{% if states.group.entry_points.state == 'on' or states.group.all_covers.state != 'closed' -%}
|
||||
red
|
||||
{% else %}
|
||||
gold
|
||||
{% endif %}
|
||||
|
||||
#-------------------------------------------#---
|
||||
- alias: "Panel Door opened"
|
||||
hide_entity: True
|
||||
trigger:
|
||||
- platform: state
|
||||
entity_id:
|
||||
- binary_sensor.MCU3_Light
|
||||
to: 'off'
|
||||
from: 'on'
|
||||
|
||||
action:
|
||||
- service: script.notify_engine
|
||||
data_template:
|
||||
value1: 'Someone has opened up the Alarm Panel Door!'
|
138
config/packages/alarm_clock.yaml
Executable file
138
config/packages/alarm_clock.yaml
Executable file
@@ -0,0 +1,138 @@
|
||||
#-------------------------------------------
|
||||
# Fire Tablet Alarm Panel -
|
||||
# http://www.vmwareinfo.com/2017/07/visualizing-smart-home-using-home.html
|
||||
#-------------------------------------------
|
||||
#
|
||||
homeassistant:
|
||||
customize_glob:
|
||||
"input_boolean.clock_snooze":
|
||||
|
||||
hidden: False
|
||||
|
||||
media_player:
|
||||
- platform: floorplan_speaker
|
||||
name: Alarm Clock
|
||||
|
||||
#---Sensors for Fire Tablet-----------------------------
|
||||
|
||||
binary_sensor:
|
||||
- platform: mqtt
|
||||
state_topic: floorplan/clock_motion
|
||||
name: Clock Motion
|
||||
device_class: motion
|
||||
retain: true
|
||||
|
||||
hidden: False
|
||||
|
||||
- platform: mqtt
|
||||
state_topic: floorplan/clock_plugged
|
||||
name: Clock Plugged
|
||||
retain: true
|
||||
|
||||
hidden: False
|
||||
|
||||
light:
|
||||
- platform: mqtt_json
|
||||
name: Clock Screensaver
|
||||
state_topic: floorplan/clock_screensaver
|
||||
command_topic: floorplan/clock_screensaver/set
|
||||
brightness: true
|
||||
|
||||
sensor:
|
||||
- platform: mqtt
|
||||
state_topic: "clock/stacey_alarm_time"
|
||||
name: clock_stacey_alarm_time
|
||||
retain: true
|
||||
|
||||
hidden: true
|
||||
|
||||
input_boolean:
|
||||
clock_snooze:
|
||||
name: Clock Snooze
|
||||
initial: off
|
||||
|
||||
automation:
|
||||
- alias: 'Snooze Button off in 10 minutes'
|
||||
trigger:
|
||||
- platform: state
|
||||
entity_id:
|
||||
- input_boolean.clock_snooze
|
||||
to: 'on'
|
||||
from: 'off'
|
||||
action:
|
||||
- delay:
|
||||
minutes: 10
|
||||
- service: input_boolean.turn_off
|
||||
entity_id: input_boolean.clock_snooze
|
||||
|
||||
#Turn on the clock - turn off the screensaver so we can see it.
|
||||
- alias: Turn off Screensaver so we can see the time
|
||||
trigger:
|
||||
- platform: state
|
||||
entity_id:
|
||||
- binary_sensor.sleepnumber_carlo_carlo_is_in_bed
|
||||
- binary_sensor.sleepnumber_carlo_stacey_is_in_bed
|
||||
- light.bedroom_screensaver
|
||||
to: 'off'
|
||||
|
||||
action:
|
||||
- service: light.turn_off
|
||||
entity_id: light.clock_screensaver
|
||||
- wait_template: "{{ is_state(trigger.entity_id, 'on') }}"
|
||||
- service: light.turn_on
|
||||
entity_id: light.clock_screensaver
|
||||
|
||||
#-----Turn on the Music--------------------------------------
|
||||
- alias: 'Play Radio when Snooze button is turned off.'
|
||||
|
||||
trigger:
|
||||
- platform: state
|
||||
entity_id:
|
||||
- input_boolean.clock_snooze
|
||||
to: 'off'
|
||||
from: 'on'
|
||||
- platform: template
|
||||
value_template: '{{states.sensor.time.state == states.sensor.clock_stacey_alarm_time.state}}'
|
||||
condition:
|
||||
- condition: state
|
||||
entity_id: input_boolean.school_mode
|
||||
state: 'on'
|
||||
- condition: time
|
||||
weekday:
|
||||
- mon
|
||||
- tue
|
||||
- wed
|
||||
- thu
|
||||
- fri
|
||||
- condition: state
|
||||
entity_id: group.family
|
||||
state: 'home'
|
||||
action:
|
||||
- service: media_player.volume_set
|
||||
data_template:
|
||||
entity_id:
|
||||
- media_player.alarm_clock
|
||||
volume_level: 0.3
|
||||
- service: media_player.play_media
|
||||
data_template:
|
||||
entity_id:
|
||||
- media_player.alarm_clock
|
||||
#media_content_id: "http://listen.181fm.com/181-kickincountry_128k.mp3"
|
||||
media_content_id: "http://listen.djcmedia.com:80/americascountryhigh"
|
||||
media_content_type: audio/mp4
|
||||
- service: light.turn_off
|
||||
entity_id: light.clock_screensaver
|
||||
|
||||
#-----Turn off the Music--------------------------------------
|
||||
- alias: 'Turn off the Radio when the snooze is turned on.'
|
||||
|
||||
trigger:
|
||||
- platform: state
|
||||
entity_id:
|
||||
- input_boolean.clock_snooze
|
||||
to: 'on'
|
||||
from: 'off'
|
||||
|
||||
action:
|
||||
- service: media_player.media_stop
|
||||
entity_id: media_player.alarm_clock
|
57
config/packages/battery_levels.yaml
Executable file
57
config/packages/battery_levels.yaml
Executable file
@@ -0,0 +1,57 @@
|
||||
#-------------------------------------------
|
||||
# Fire Tablet Alarm Panel -
|
||||
# http://www.vmwareinfo.com/2017/07/visualizing-smart-home-using-home.html
|
||||
#-------------------------------------------
|
||||
#
|
||||
# homeassistant:
|
||||
# customize_glob:
|
||||
# "sensor.*_alarm_panel*":
|
||||
#
|
||||
# hidden: False
|
||||
# "binary_sensor.*_alarm_panel*":
|
||||
#
|
||||
# hidden: False
|
||||
|
||||
sensor:
|
||||
- platform: template
|
||||
sensors:
|
||||
low_battery:
|
||||
friendly_name: 'Low Battery'
|
||||
value_template: >
|
||||
{%- set threshold = 15 -%}
|
||||
{%- set domains = ['light', 'switch', 'sensor', 'zwave', 'lock', 'binary_sensor'] -%}
|
||||
{%- for domain in domains -%}
|
||||
{%- for item in states[domain] if ((item.attributes.battery_level is defined and item.attributes['battery_level'] | int < threshold) or ("battery" in item.name | lower and ((item.state | int < threshold and item.state|int != 0) or item.state | lower == "low" or item.state | lower == "unknown"))) -%}
|
||||
{{ item.attributes.friendly_name }} (
|
||||
{%- if item.attributes.battery_level is defined -%}
|
||||
{{ item.attributes.battery_level}}
|
||||
{%- else -%}
|
||||
{{item.state}}
|
||||
{%- endif -%}%)
|
||||
{%- if not loop.last -%}
|
||||
{{', '}}
|
||||
{%- endif -%}
|
||||
{%- endfor -%}
|
||||
{%- endfor -%}
|
||||
|
||||
automation:
|
||||
- alias: 'Battery Alert'
|
||||
initial_state: 'on'
|
||||
trigger:
|
||||
- platform: time
|
||||
at: '10:00:00'
|
||||
- platform: time
|
||||
at: '18:00:00'
|
||||
condition:
|
||||
condition: template
|
||||
value_template: "{% if states('sensor.low_battery') %}true{% endif %}"
|
||||
action:
|
||||
- service: persistent_notification.create
|
||||
data_template:
|
||||
title: Low Battery
|
||||
message: "{{ states('sensor.low_battery') }}"
|
||||
notification_id: low-battery-alert
|
||||
- service: script.notify_engine
|
||||
data_template:
|
||||
value1: "Low battery levels: {{ states('sensor.low_battery') }}"
|
||||
who: 'carlo'
|
90
config/packages/epson_printer.yaml
Executable file
90
config/packages/epson_printer.yaml
Executable file
@@ -0,0 +1,90 @@
|
||||
#-------------------------------------------
|
||||
# @CCOSTAN
|
||||
# Original Repo : https://github.com/CCOSTAN/Home-AssistantConfig
|
||||
# inspired by https://community.home-assistant.io/t/epson-wf-3540-ink-level-monitoring/21813
|
||||
#-------------------------------------------
|
||||
homeassistant:
|
||||
customize_glob:
|
||||
"sensor.epson_ink_level_*":
|
||||
icon: mdi:cup-water
|
||||
|
||||
hidden: False
|
||||
homebridge_hidden: True
|
||||
#-------------------------------------------
|
||||
sensor:
|
||||
- platform: command_line
|
||||
name: Epson Ink Level Black
|
||||
command: /usr/bin/curl -X GET http://192.168.10.105/PRESENTATION/HTML/TOP/PRTINFO.HTML | awk -F"'" '/Ink_K.PNG/ && $6+0 == $6 { printf "%.0f\n", $6 / 50 * 100; exit }'
|
||||
unit_of_measurement: '%'
|
||||
scan_interval: 14400
|
||||
|
||||
- platform: command_line
|
||||
name: Epson Ink Level Magenta
|
||||
command: /usr/bin/curl -X GET http://192.168.10.105/PRESENTATION/HTML/TOP/PRTINFO.HTML | awk -F"'" '/Ink_M.PNG/ && $6+0 == $6 { printf "%.0f\n", $6 / 50 * 100 }'
|
||||
unit_of_measurement: '%'
|
||||
scan_interval: 14400
|
||||
|
||||
- platform: command_line
|
||||
name: Epson Ink Level Yellow
|
||||
command: /usr/bin/curl -X GET http://192.168.10.105/PRESENTATION/HTML/TOP/PRTINFO.HTML | awk -F"'" '/Ink_Y.PNG/ && $6+0 == $6 { printf "%.0f\n", $6 / 50 * 100 }'
|
||||
unit_of_measurement: '%'
|
||||
scan_interval: 14400
|
||||
|
||||
- platform: command_line
|
||||
name: Epson Ink Level Cyan
|
||||
command: /usr/bin/curl -X GET http://192.168.10.105/PRESENTATION/HTML/TOP/PRTINFO.HTML | awk -F"'" '/Ink_C.PNG/ && $6+0 == $6 { printf "%.0f\n", $6 / 50 * 100 }'
|
||||
unit_of_measurement: '%'
|
||||
scan_interval: 14400
|
||||
|
||||
- platform: command_line
|
||||
name: Epson Ink Level Photo Black
|
||||
command: /usr/bin/curl -X GET http://192.168.10.105/PRESENTATION/HTML/TOP/PRTINFO.HTML | awk -F"'" '/Ink_K.PNG/ {i++}i==2 && $6+0 == $6 { printf "%.0f\n", $6 / 50 * 100; exit }'
|
||||
unit_of_measurement: '%'
|
||||
scan_interval: 14400
|
||||
#-------------------------------------------
|
||||
group:
|
||||
epson_printer:
|
||||
name: Epson Printer Info
|
||||
control: hidden
|
||||
entities:
|
||||
- sensor.epson_ink_level_black
|
||||
- sensor.epson_ink_level_cyan
|
||||
- sensor.epson_ink_level_magenta
|
||||
- sensor.epson_ink_level_yellow
|
||||
- sensor.epson_ink_level_photo_black
|
||||
#-------------------------------------------
|
||||
##############################################################################
|
||||
### Automations - Detect when things are not right. Like any Good Watchdog.
|
||||
##############################################################################
|
||||
|
||||
automation:
|
||||
- alias: 'Printer Ink Alert'
|
||||
initial_state: 'on'
|
||||
trigger:
|
||||
- platform: numeric_state
|
||||
entity_id:
|
||||
- sensor.epson_ink_level_black
|
||||
- sensor.epson_ink_level_magenta
|
||||
- sensor.epson_ink_level_photo_black
|
||||
- sensor.epson_ink_level_yellow
|
||||
- sensor.epson_ink_level_cyan
|
||||
below: 25
|
||||
condition:
|
||||
condition: time
|
||||
weekday:
|
||||
- wed
|
||||
action:
|
||||
- service: persistent_notification.create
|
||||
data_template:
|
||||
title: Low Ink
|
||||
message: "{{ trigger.to_state.attributes.friendly_name }} is at {{ trigger.to_state.state }} "
|
||||
notification_id: low-battery-alert
|
||||
- service: script.notify_engine
|
||||
data_template:
|
||||
value1: "{{ trigger.to_state.attributes.friendly_name }} is at {{ trigger.to_state.state }} "
|
||||
who: 'carlo'
|
||||
- service: script.tweet_engine
|
||||
data:
|
||||
tweet: 'Looks like my {{ trigger.to_state.attributes.friendly_name }} is LOW. @CCostan - Get me some more (http://amzn.to/2AnpFwD)'
|
||||
|
||||
#-------------------------------------------
|
36
config/packages/finance.yaml
Executable file
36
config/packages/finance.yaml
Executable file
@@ -0,0 +1,36 @@
|
||||
#-------------------------------------------
|
||||
# @CCOSTAN
|
||||
# Original Repo : https://github.com/CCOSTAN/Home-AssistantConfig
|
||||
# Neato Support for D7 Connected Botvac - control my [Neato Vacuum](http://amzn.to/2kqnnqu) with Home Assistant.
|
||||
#-------------------------------------------
|
||||
# homeassistant:
|
||||
# customize_glob:
|
||||
# "*.*_sleep_hours":
|
||||
# unit_of_measurement: hours
|
||||
# icon: mdi:sleep
|
||||
#
|
||||
# hidden: False
|
||||
#-------------------------------------------
|
||||
sensor:
|
||||
- platform: alpha_vantage
|
||||
api_key: !secret vantage_api
|
||||
symbols:
|
||||
- name: Tesla
|
||||
currency: USD
|
||||
symbol: TSLA
|
||||
foreign_exchange:
|
||||
- from: BTC
|
||||
to: USD
|
||||
name: Bitcoin
|
||||
#-------------------------------------------
|
||||
group:
|
||||
finance:
|
||||
entities:
|
||||
- sensor.tesla
|
||||
- sensor.bitcoin
|
||||
|
||||
##############################################################################
|
||||
### Automations - Detect when things are not right. Like any Good Watchdog.
|
||||
##############################################################################
|
||||
#automation:
|
||||
#Tweets pushed out to twitter.
|
15
config/packages/fire_tablet.yaml
Executable file
15
config/packages/fire_tablet.yaml
Executable file
@@ -0,0 +1,15 @@
|
||||
#-------------------------------------------
|
||||
# Global Fire Tablet settings -
|
||||
# http://www.vmwareinfo.com/2017/07/visualizing-smart-home-using-home.html
|
||||
#-------------------------------------------
|
||||
# We block the auto adjust brightness routines for the tablets.
|
||||
# Use ALARM and Floorplan for the security system.
|
||||
|
||||
group:
|
||||
firetablets:
|
||||
entities:
|
||||
- binary_sensor.bedroom_motion
|
||||
- binary_sensor.bedroom_plugged
|
||||
- binary_sensor.clock_motion
|
||||
- binary_sensor.clock_plugged
|
||||
- switch.bedroom_restart
|
70
config/packages/fitbit.yaml
Executable file
70
config/packages/fitbit.yaml
Executable file
@@ -0,0 +1,70 @@
|
||||
#-------------------------------------------
|
||||
# @CCOSTAN
|
||||
# Original Repo : https://github.com/CCOSTAN/Home-AssistantConfig
|
||||
# Neato Support for D7 Connected Botvac - control my [Neato Vacuum](http://amzn.to/2kqnnqu) with Home Assistant.
|
||||
#-------------------------------------------
|
||||
# homeassistant:
|
||||
# customize_glob:
|
||||
# "*.*_sleep_hours":
|
||||
# unit_of_measurement: hours
|
||||
# icon: mdi:sleep
|
||||
#
|
||||
# hidden: False
|
||||
#-------------------------------------------
|
||||
sensor:
|
||||
- platform: fitbit
|
||||
clock_format: 12H
|
||||
monitored_resources:
|
||||
- "body/weight"
|
||||
- "activities/steps"
|
||||
- "devices/battery"
|
||||
#-------------------------------------------
|
||||
group:
|
||||
fitbit:
|
||||
entities:
|
||||
- sensor.steps
|
||||
- sensor.weight
|
||||
- sensor.one_battery
|
||||
##############################################################################
|
||||
### Automations - Detect when things are not right. Like any Good Watchdog.
|
||||
##############################################################################
|
||||
automation:
|
||||
- alias: 'Missing Fitbit Alert'
|
||||
initial_state: 'on'
|
||||
trigger:
|
||||
- platform: time
|
||||
at: '11:00:00'
|
||||
condition:
|
||||
condition: template
|
||||
value_template: >
|
||||
{%- if states.sensor.steps.state.replace(",", "")|int < 1000 -%}
|
||||
true
|
||||
{%- endif -%}
|
||||
action:
|
||||
- service: script.notify_engine
|
||||
data_template:
|
||||
value1: "Your current fitbit steps are {{ states('sensor.steps') }} - You probably do not have it."
|
||||
who: 'carlo'
|
||||
|
||||
- alias: 'Fitbit 10k'
|
||||
initial_state: 'on'
|
||||
trigger:
|
||||
- platform: state
|
||||
entity_id:
|
||||
- binary_sensor.sleepnumber_carlo_carlo_is_in_bed
|
||||
to: 'on'
|
||||
condition:
|
||||
- condition: template
|
||||
value_template: >
|
||||
{%- if states.sensor.steps.state.replace(",", "")|int > 10000 -%}
|
||||
true
|
||||
{%- endif -%}
|
||||
action:
|
||||
- service: script.tweet_engine
|
||||
data_template:
|
||||
tweet: >
|
||||
{{ [
|
||||
"Somebody just hit {{ states('sensor.steps') }} steps on the #Fitbit!",
|
||||
"Keep on moving. Somebody just hit {{ states('sensor.steps') }} #Fitbit steps.",
|
||||
"#Fitness Tracking at home BY the home. Somebody just hit {{ states('sensor.steps') }} #Fitbit steps"
|
||||
] | random + " Battery Level:{{ states('sensor.one_battery') }} #Self #Data"}}
|
48
config/packages/floorplan.yaml
Executable file
48
config/packages/floorplan.yaml
Executable file
@@ -0,0 +1,48 @@
|
||||
#-------------------------------------------
|
||||
# Fire Tablet Alarm Panel -
|
||||
# http://www.vmwareinfo.com/2017/07/visualizing-smart-home-using-home.html
|
||||
#-------------------------------------------
|
||||
#
|
||||
homeassistant:
|
||||
customize_glob:
|
||||
"sensor.*_alarm_panel*":
|
||||
hidden: False
|
||||
"binary_sensor.*_alarm_panel*":
|
||||
hidden: False
|
||||
|
||||
media_player:
|
||||
- platform: floorplan_speaker
|
||||
name: Bedroom Alarm Panel
|
||||
|
||||
switch:
|
||||
- platform: command_line
|
||||
switches:
|
||||
bedroom_restart:
|
||||
command_on: !secret bedroom_restart_on
|
||||
friendly_name: Restart Bedroom Panel
|
||||
# This restart switch is called from the Self_heal nightly Automation.
|
||||
|
||||
#---Sensors for Fire Tablet-----------------------------
|
||||
|
||||
light:
|
||||
|
||||
- platform: mqtt_json
|
||||
name: Bedroom Screensaver
|
||||
state_topic: floorplan/bedroom_screensaver
|
||||
command_topic: floorplan/bedroom_screensaver/set
|
||||
brightness: true
|
||||
|
||||
binary_sensor:
|
||||
|
||||
- platform: mqtt
|
||||
state_topic: floorplan/bedroom_motion
|
||||
name: Bedroom Motion
|
||||
device_class: motion
|
||||
retain: true
|
||||
hidden: False
|
||||
|
||||
- platform: mqtt
|
||||
state_topic: floorplan/bedroom_plugged
|
||||
name: Bedroom Plugged
|
||||
retain: true
|
||||
hidden: False
|
95
config/packages/garadget.yaml
Executable file
95
config/packages/garadget.yaml
Executable file
@@ -0,0 +1,95 @@
|
||||
#-------------------------------------------
|
||||
# # @CCOSTAN
|
||||
# Original Repo : https://github.com/CCOSTAN/Home-AssistantConfig
|
||||
## Garadget_Stuff - [Garadget](http://amzn.to/2jQLpVQ) - Garage Door opener/sensor
|
||||
#-------------------------------------------
|
||||
|
||||
cover:
|
||||
platform: garadget
|
||||
covers:
|
||||
!secret large_garage_id:
|
||||
username: !secret garadget_username
|
||||
password: !secret garadget_password
|
||||
name: Large Garage
|
||||
!secret small_garage_id:
|
||||
username: !secret garadget_username
|
||||
password: !secret garadget_password
|
||||
name: Small Garage
|
||||
|
||||
sensor:
|
||||
- platform: template
|
||||
sensors:
|
||||
small_garage_status:
|
||||
friendly_name: 'State of the door'
|
||||
value_template: '{{ states.cover.small_garage.state }}'
|
||||
small_garage_time_in_state:
|
||||
friendly_name: 'Time Since Change'
|
||||
value_template: '{{ states.cover.small_garage.attributes["time_in_state"] }}'
|
||||
small_garage_wifi_signal_strength:
|
||||
friendly_name: 'WiFi strength'
|
||||
value_template: '{{ states.cover.small_garage.attributes["wifi_signal_strength"] }}'
|
||||
unit_of_measurement: 'dB'
|
||||
small_garage_reflection_rate:
|
||||
friendly_name: 'Reflection Rate'
|
||||
value_template: '{{ states.cover.small_garage.attributes["sensor_reflection_rate"] }}'
|
||||
|
||||
- platform: mqtt
|
||||
name: 'Small Garage Brightness'
|
||||
state_topic: 'garadget/Garadget Small/status'
|
||||
unit_of_measurement: '%'
|
||||
value_template: '{{ value_json.bright }}'
|
||||
|
||||
- platform: template
|
||||
sensors:
|
||||
large_garage_status:
|
||||
friendly_name: 'State of the door'
|
||||
value_template: '{{ states.cover.large_garage.state }}'
|
||||
large_garage_time_in_state:
|
||||
friendly_name: 'Time Since Change'
|
||||
value_template: '{{ states.cover.large_garage.attributes["time_in_state"] }}'
|
||||
large_garage_wifi_signal_strength:
|
||||
friendly_name: 'WiFi strength'
|
||||
value_template: '{{ states.cover.large_garage.attributes["wifi_signal_strength"] }}'
|
||||
unit_of_measurement: 'dB'
|
||||
large_garage_reflection_rate:
|
||||
friendly_name: 'Reflection Rate'
|
||||
value_template: '{{ states.cover.large_garage.attributes["sensor_reflection_rate"] }}'
|
||||
|
||||
- platform: mqtt
|
||||
name: 'Large Garage Brightness'
|
||||
state_topic: 'garadget/Garadget Large/status'
|
||||
unit_of_measurement: '%'
|
||||
value_template: '{{ value_json.bright }}'
|
||||
|
||||
group:
|
||||
garage_doors:
|
||||
name: Garage doors
|
||||
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
|
||||
|
||||
automation:
|
||||
- alias: 'Update Garage Brightness'
|
||||
trigger:
|
||||
- platform: time
|
||||
minutes: '/5'
|
||||
seconds: 00
|
||||
action:
|
||||
- service: mqtt.publish
|
||||
data:
|
||||
topic: "garadget/Garadget Small/command"
|
||||
payload: "get-status"
|
||||
- service: mqtt.publish
|
||||
data:
|
||||
topic: "garadget/Garadget Large/command"
|
||||
payload: "get-status"
|
115
config/packages/hasspodcast.yaml
Executable file
115
config/packages/hasspodcast.yaml
Executable file
@@ -0,0 +1,115 @@
|
||||
#-------------------------------------------
|
||||
# RSS Podcast Alerting function Packages
|
||||
# @CCOSTAN
|
||||
# Original Repo : https://github.com/CCOSTAN/Home-AssistantConfig
|
||||
#-------------------------------------------
|
||||
|
||||
#-------------------------------------------
|
||||
feedreader:
|
||||
urls:
|
||||
- https://hasspodcast.io/feed/podcast
|
||||
- http://feeds.feedburner.com/IPMer?format=xml
|
||||
#-------------------------------------------
|
||||
|
||||
automation:
|
||||
- alias: Send notification of RSS feed title when updated
|
||||
trigger:
|
||||
platform: event
|
||||
event_type: feedreader
|
||||
|
||||
action:
|
||||
- service: script.notify_engine
|
||||
data_template:
|
||||
value1: 'There is a new HA Podcast available for {{trigger.event.data.title}}.'
|
||||
value2: 'https://hasspodcast.io/'
|
||||
who: 'carlo'
|
||||
|
||||
- service: notify.html5
|
||||
data_template:
|
||||
title: "New HA Podcast available"
|
||||
message: "New HA Podcast - {{ as_timestamp(now()) | timestamp_custom('%I:%M:%S %p %d%b%Y', true) }} {{trigger.event.data.title}}"
|
||||
data:
|
||||
url: "https://hasspodcast.io/"
|
||||
|
||||
- service: persistent_notification.create
|
||||
data_template:
|
||||
title: "{{trigger.event.data.title}}"
|
||||
message: "New Podcast available - {{ as_timestamp(now()) | timestamp_custom('%I:%M:%S %p %d%b%Y', true) }}"
|
||||
notification_id: "update_available"
|
||||
|
||||
- service: script.tweet_engine
|
||||
data_template:
|
||||
tweet: >
|
||||
{{ [
|
||||
"There is a new HA Podcast available! @DanGeek, @rohank9, @philhawthorne & Crew rock it out (#HomeAutomation Style!)!",
|
||||
"Mine and @DanGeek Favorite Podcast just came out!",
|
||||
"Listen to @rohank9 and the HA Podcast crew on thier new #HomeAutomation episode!",
|
||||
"Mine & @CCostan Favorite Podcast just came out! Thanks @DanGeek!"
|
||||
] | random + "(https://hasspodcast.io/)"}}
|
||||
|
||||
- service: script.notify_engine
|
||||
data_template:
|
||||
value1: 'Check the MQTT Dump'
|
||||
value2: '/dump/{{ trigger.platform }}'
|
||||
who: 'carlo'
|
||||
- service: mqtt.publish
|
||||
data_template:
|
||||
topic: '/dump/{{ trigger.platform }}'
|
||||
retain: false
|
||||
payload: >-
|
||||
{%- macro dumpState(statePrefix, stateObj) -%}
|
||||
{{statePrefix ~ ": "}} {{- stateObj.state }}{{- "\n" -}}
|
||||
{{statePrefix ~ ".entity_id: "}} {{- stateObj.entity_id }}{{- "\n" -}}
|
||||
{{statePrefix ~ ".domain: "}} {{- stateObj.domain }}{{- "\n" -}}
|
||||
{{statePrefix ~ ".object_id: "}} {{- stateObj.object_id }}{{- "\n" -}}
|
||||
{{statePrefix ~ ".name: "}} {{- stateObj.name }}{{- "\n" -}}
|
||||
{{statePrefix ~ ".last_updated: "}} {{- stateObj.last_updated }}{{- "\n" -}}
|
||||
{{statePrefix ~ ".last_changed: "}} {{- stateObj.last_changed }}{{- "\n" -}}
|
||||
{%- for attrib in stateObj.attributes | sort() %}
|
||||
{%- if attrib is defined -%}
|
||||
{{- statePrefix ~ ".attributes." ~ attrib ~ ": " -}} {{- stateObj.attributes[attrib] -}}
|
||||
{{- "\n" -}}
|
||||
{%- endif -%}
|
||||
{%- endfor -%}
|
||||
{%- endmacro -%}
|
||||
|
||||
{% set p = trigger.platform %}
|
||||
{{"trigger.platform: "}} {{ p }}{{- "\n" -}}
|
||||
|
||||
{%- if p == "mqtt" -%}
|
||||
{{"trigger.topic: "}} {{ trigger.topic }}{{- "\n" -}}
|
||||
{{"trigger.payload: "}} {{ trigger.payload }}{{- "\n" -}}
|
||||
{{"trigger.payload_json: "}} {{ trigger.payload_json }}{{- "\n" -}}
|
||||
{{"trigger.qos: "}} {{ trigger.qos }}{{- "\n" -}}
|
||||
{%- endif -%}
|
||||
|
||||
{%- if p == "event" or p == "sun" or p == "zone" -%}
|
||||
{{"trigger.event: "}} {{ trigger.event }}{{- "\n" -}}
|
||||
{%- endif -%}
|
||||
|
||||
{%- if p == "numeric_state" -%}
|
||||
{{"trigger.above: "}} {{ trigger.above }}{{- "\n" -}}
|
||||
{{"trigger.below: "}} {{trigger.below }}{{- "\n" -}}
|
||||
{%- endif -%}
|
||||
|
||||
{%- if p == "state" -%}
|
||||
{{"trigger.for: "}} {{ trigger.for }}{{- "\n" -}}
|
||||
{%- endif -%}
|
||||
|
||||
{%- if p == "time" -%}
|
||||
{{"trigger.now: "}} {{ trigger.now }}{{- "\n" -}}
|
||||
{%- endif -%}
|
||||
|
||||
{%- if p == "zone" -%}
|
||||
{{"trigger.zone: "}} {{ trigger.zone }}{{- "\n" -}}
|
||||
{%- endif -%}
|
||||
|
||||
{%- if p == "state" or p == "numeric_state" or p == "template" or p == "zone" -%}
|
||||
{{"trigger.entity_id: "}} {{ trigger.entity_id }}{{- "\n" -}}{{- "\n" -}}
|
||||
{{"trigger.from_state: "}} {{- "\n" -}}
|
||||
-------------------{{- "\n" -}}
|
||||
{{ dumpState("trigger.from_state", trigger.from_state) }} {{- "\n" -}}
|
||||
trigger.to_state:{{- "\n" -}}
|
||||
-----------------{{- "\n" -}}
|
||||
{{ dumpState("trigger.to_state", trigger.to_state) }}
|
||||
{%- endif -%}
|
91
config/packages/holiday.yaml
Executable file
91
config/packages/holiday.yaml
Executable file
@@ -0,0 +1,91 @@
|
||||
###############################################################################
|
||||
# @author : Mahasri Kalavala
|
||||
# @date : 10/28/2017
|
||||
# @package : Holidays
|
||||
# @description : Retrieves the holiday
|
||||
###############################################################################
|
||||
## Modified for my own fun stuff!
|
||||
|
||||
homeassistant:
|
||||
customize:
|
||||
|
||||
sensor.holiday:
|
||||
hidden: true
|
||||
icon: mdi:beach
|
||||
friendly_name: US Holiday
|
||||
sensor.flag:
|
||||
hidden: true
|
||||
icon: mdi:flag
|
||||
friendly_name: Flag Day
|
||||
|
||||
###############################################################################
|
||||
# Sensor updates once every 4 hours (14400 seconds) & runs 6 times in 24 hours
|
||||
#
|
||||
# First it checks for holiday in static section, if that doesn't exist,
|
||||
# it checks in the dynamic section. If neither exists, the value will be empty
|
||||
###############################################################################
|
||||
sensor:
|
||||
- platform: rest
|
||||
resource: https://raw.githubusercontent.com/CCOSTAN/Home-AssistantConfig/master/json_data/holidays.json
|
||||
name: Holiday
|
||||
scan_interval: 14400
|
||||
value_template: >
|
||||
{% set today = now().month ~ '/' ~ now().day %}
|
||||
{% set holiday = value_json.MAJOR_US.static[ today ] %}
|
||||
{% if holiday | trim == "" %}
|
||||
{% set today = now().month ~ '/' ~ now().day ~ '/' ~ now().year %}
|
||||
{% set holiday = value_json.MAJOR_US.dynamic[ today ] %}
|
||||
{% endif %}
|
||||
{{ holiday }}
|
||||
|
||||
- platform: rest
|
||||
resource: http://www.webcal.fi/cal.php?id=335&format=json&start_year=current_year&end_year=2017&tz=America%2FNew_York
|
||||
name: Flag
|
||||
scan_interval: 14400
|
||||
value_template: >-
|
||||
{% set is_flag_day = False %}
|
||||
{%- for day_val in value_json -%}
|
||||
{% set now_string = now().strftime('%Y-%m-%d') %}
|
||||
{%- if day_val.date == now_string and day_val.flag_day == 1-%}
|
||||
{% set is_flag_day = True %}
|
||||
{%- endif -%}
|
||||
{% endfor %}
|
||||
{{is_flag_day}}
|
||||
|
||||
###############################################################################
|
||||
# Automation that notifies of a Holiday "state" change
|
||||
###############################################################################
|
||||
automation:
|
||||
- alias: Notify Holiday State Change
|
||||
hide_entity: false
|
||||
initial_state: true
|
||||
trigger:
|
||||
- platform: state
|
||||
entity_id:
|
||||
- sensor.holiday
|
||||
condition:
|
||||
- condition: template
|
||||
value_template: "{{ states('sensor.holiday') != 'unknown' }}"
|
||||
- condition: template
|
||||
value_template: "{{ states.sensor.holiday.state | trim != '' }}"
|
||||
action:
|
||||
- service: persistent_notification.create
|
||||
data:
|
||||
message: 'Today is {{ states.sensor.holiday.state }}.'
|
||||
title: '{{ states.sensor.holiday.state }}'
|
||||
|
||||
- delay: '{{ (range(4, 8)|random|int) }}:{{ (range(1, 50)|random|int) }}:00'
|
||||
- service: script.tweet_engine
|
||||
data_template:
|
||||
tweet: >
|
||||
{{ [
|
||||
"Today is {{ states.sensor.holiday.state }}. Time to adjust the outside light colors!",
|
||||
"Today is {{ states.sensor.holiday.state }}.",
|
||||
"Is today {{ states.sensor.holiday.state }}?",
|
||||
"Just checked with Alexa & today is {{ states.sensor.holiday.state }}."
|
||||
] | random + [
|
||||
" #DayOff",
|
||||
"(http://www.vmwareinfo.com/2017/07/my-smart-home-look-at-parts-that-make.html)",
|
||||
"(http://www.vmwareinfo.com/2017/08/diy-outdoor-smart-home-led-strips.html)",
|
||||
"#{{ states.sensor.holiday.state }}"
|
||||
] | random }}
|
122
config/packages/ios.yaml
Executable file
122
config/packages/ios.yaml
Executable file
@@ -0,0 +1,122 @@
|
||||
#-------------------------------------------
|
||||
# Realtime Debugging Related Packages
|
||||
# @CCOSTAN
|
||||
# Original Repo : https://github.com/CCOSTAN/Home-AssistantConfig
|
||||
#-------------------------------------------
|
||||
# homeassistant:
|
||||
# customize_glob:
|
||||
# "sensor.carlo_6*":
|
||||
#
|
||||
# "sensor.staceys_iphone_*":
|
||||
|
||||
notify:
|
||||
- platform: ios
|
||||
- name: ios_family
|
||||
platform: group
|
||||
services:
|
||||
- service: ios_staceys_iphone
|
||||
- service: ios_carlo_6s
|
||||
- name: ios_parents
|
||||
platform: group
|
||||
services:
|
||||
- service: ios_staceys_iphone
|
||||
- service: ios_carlo_6s
|
||||
|
||||
group:
|
||||
Phones:
|
||||
entities:
|
||||
- sensor.carlo_6s_battery_level
|
||||
- sensor.carlo_6s_battery_state
|
||||
- sensor.staceys_iphone_battery_level
|
||||
- sensor.staceys_iphone_battery_state
|
||||
|
||||
ios:
|
||||
push:
|
||||
categories:
|
||||
- name: Medicine
|
||||
identifier: 'tablet'
|
||||
actions:
|
||||
- identifier: 'TABLET_TAKEN'
|
||||
title: 'Tablet Taken'
|
||||
activationMode: 'background'
|
||||
authenticationRequired: no
|
||||
destructive: yes
|
||||
|
||||
- identifier: 'NOT_HOME'
|
||||
title: 'I am not Home'
|
||||
activationMode: 'background'
|
||||
authenticationRequired: no
|
||||
destructive: no
|
||||
|
||||
## - Reminders to take my medicine
|
||||
input_boolean:
|
||||
medicine:
|
||||
name: Medicine Reminder
|
||||
initial: off
|
||||
icon: mdi:tablet
|
||||
|
||||
automation:
|
||||
- alias: Tablet Already taken
|
||||
trigger:
|
||||
platform: event
|
||||
event_type: ios.notification_action_fired
|
||||
event_data:
|
||||
actionName: TABLET_TAKEN
|
||||
action:
|
||||
- service: notify.ios_carlo_6s
|
||||
data:
|
||||
message: "Great job!"
|
||||
- service: input_boolean.turn_on
|
||||
entity_id: input_boolean.medicine
|
||||
|
||||
- alias: Remind Me Later
|
||||
trigger:
|
||||
platform: event
|
||||
event_type: ios.notification_action_fired
|
||||
event_data:
|
||||
actionName: NOT_HOME
|
||||
action:
|
||||
- service: notify.ios_carlo_6s
|
||||
data:
|
||||
message: "Ok. I will remind you when you get home."
|
||||
- wait_template: >-
|
||||
{{ states.device_tracker.carlo.state == 'home' }}
|
||||
- service: notify.ios_carlo_6s
|
||||
data:
|
||||
message: "Now that your home, please take your medicine!"
|
||||
|
||||
- alias: Medicine Reminder
|
||||
initial_state: true
|
||||
trigger:
|
||||
- platform: time
|
||||
minutes: '45'
|
||||
seconds: '00'
|
||||
- platform: time
|
||||
at: '21:30:00'
|
||||
- platform: state
|
||||
entity_id: device_tracker.carlo
|
||||
to: 'home'
|
||||
|
||||
condition:
|
||||
- condition: time
|
||||
after: '21:30:00'
|
||||
- condition: state
|
||||
entity_id: device_tracker.carlo
|
||||
state: 'home'
|
||||
- condition: state
|
||||
entity_id: input_boolean.medicine
|
||||
state: 'off'
|
||||
|
||||
action:
|
||||
- service: notify.ios_carlo_6s
|
||||
data:
|
||||
title: "Medicine Alert!"
|
||||
message: "Please take your Medicine!"
|
||||
data:
|
||||
push:
|
||||
category: "tablet"
|
||||
action_data:
|
||||
entity_id: light.test
|
||||
my_custom_data: foo_bar
|
||||
|
||||
## Reminders to take my Medicine! - End.
|
81
config/packages/juicenet.yaml
Executable file
81
config/packages/juicenet.yaml
Executable file
@@ -0,0 +1,81 @@
|
||||
#-------------------------------------------
|
||||
# @CCOSTAN
|
||||
# Original Repo : https://github.com/CCOSTAN/Home-AssistantConfig
|
||||
# Neato Support for D7 Connected Botvac - control my [Neato Vacuum](http://amzn.to/2kqnnqu) with Home Assistant.
|
||||
#-------------------------------------------
|
||||
homeassistant:
|
||||
customize_glob:
|
||||
"*.carlojuice*":
|
||||
|
||||
homebridge_hidden: True
|
||||
hidden: False
|
||||
#-------------------------------------------
|
||||
juicenet:
|
||||
access_token: !secret juicenet_access_token
|
||||
|
||||
group:
|
||||
juicenet:
|
||||
name: JuiceBox Charger
|
||||
control: hidden
|
||||
entities:
|
||||
- sensor.carlojuice_amps
|
||||
- sensor.carlojuice_charge_time
|
||||
- sensor.carlojuice_charging_status
|
||||
- sensor.carlojuice_energy_added
|
||||
- sensor.carlojuice_temperature
|
||||
- sensor.carlojuice_voltage
|
||||
- sensor.carlojuice_watts
|
||||
|
||||
#############################################################################
|
||||
### Automations - Alerts related to the JuiceBox (http://amzn.to/2AZVQ37)
|
||||
##############################################################################
|
||||
automation:
|
||||
- alias: 'Car Charging Alerts'
|
||||
initial_state: 'on'
|
||||
trigger:
|
||||
- platform: state
|
||||
entity_id: sensor.carlojuice_charging_status
|
||||
|
||||
action:
|
||||
- service: script.notify_engine
|
||||
data_template:
|
||||
value1: "The Garage charger is now in {{ states('sensor.carlojuice_charging_status') }} mode."
|
||||
who: 'parents'
|
||||
|
||||
- alias: 'JuiceBox AMP Alert!'
|
||||
initial_state: 'on'
|
||||
trigger:
|
||||
- platform: numeric_state
|
||||
entity_id: sensor.carlojuice_amps
|
||||
above: 24
|
||||
for:
|
||||
minutes: 2
|
||||
action:
|
||||
- service: input_boolean.turn_on
|
||||
entity_id: input_boolean.alert_mode
|
||||
|
||||
- service: script.notify_engine
|
||||
data_template:
|
||||
value1: "The Juice Box Charger is pulling {{ states('sensor.carlojuice_amps') }} AMPs. This is above the safety mark of 30. Please unplug charger immediately."
|
||||
who: 'parents'
|
||||
|
||||
- service: script.speech_engine
|
||||
data_template:
|
||||
value1: "The Juice Box Charger is pulling {{ states('sensor.carlojuice_amps') }} AMPs. This is above the safety mark of 30. Please unplug charger immediately."
|
||||
|
||||
- alias: 'JuiceBox Tweet Stat!'
|
||||
initial_state: 'on'
|
||||
trigger:
|
||||
- platform: state
|
||||
entity_id: sensor.carlojuice_charging_status
|
||||
from: 'charging'
|
||||
action:
|
||||
- delay: '0{{ range(0,4) | random | int }}:00:00'
|
||||
- service: script.tweet_engine
|
||||
data_template:
|
||||
tweet: >
|
||||
{{ [
|
||||
"The #Chevy Bolt Charged for {{(states.sensor.carlojuice_charge_time.state | int /60) | round() }} minutes and Juiced up {{states.sensor.carlojuice_energy_added.state |int /1000}} KwHs.",
|
||||
"The last charging session was {{(states.sensor.carlojuice_charge_time.state | int /60) | round() }} minutes. Added {{states.sensor.carlojuice_energy_added.state |int /1000}} KwHs ",
|
||||
"The Juice Box Pro added {{states.sensor.carlojuice_energy_added.state |int /1000}} KwHs to the #Chevy #BoltEV in {{(states.sensor.carlojuice_charge_time.state | int /60) | round() }} minutes."
|
||||
] | random + " (http://amzn.to/2zlQIUI) #Electric #Solar"}}
|
55
config/packages/landscape_lighting.yaml
Executable file
55
config/packages/landscape_lighting.yaml
Executable file
@@ -0,0 +1,55 @@
|
||||
#-------------------------------------------
|
||||
# Landscape Lighting Packages
|
||||
# @CCOSTAN
|
||||
# Original Repo : https://github.com/CCOSTAN/Home-AssistantConfig
|
||||
#-------------------------------------------
|
||||
homeassistant:
|
||||
customize:
|
||||
switch.back_landscaping:
|
||||
friendly_name: 'Back Landscaping'
|
||||
icon: mdi:flower
|
||||
|
||||
hidden: False
|
||||
switch.front_landscaping:
|
||||
friendly_name: 'Front Landscaping'
|
||||
icon: mdi:flower
|
||||
|
||||
hidden: False
|
||||
group.landscaping:
|
||||
friendly_name: 'Landscaping Lights'
|
||||
|
||||
hidden: False
|
||||
#-------------------------------------------
|
||||
group:
|
||||
landscaping:
|
||||
entities:
|
||||
- switch.front_landscaping
|
||||
- switch.back_landscaping
|
||||
#-------------------------------------------
|
||||
# Automation : Added to Sunset_ON
|
||||
# Automation : Added to Sunset_OFF
|
||||
# Automation : Added to Away. (Switches off Back Landscaping)
|
||||
# Automation : Added to Late Night Helper Outside (Switches Back lights on)
|
||||
automation:
|
||||
- alias: 'Back Landscape lights off'
|
||||
trigger:
|
||||
- platform: state
|
||||
entity_id:
|
||||
- binary_sensor.sleepnumber_carlo_carlo_is_in_bed
|
||||
- binary_sensor.sleepnumber_carlo_stacey_is_in_bed
|
||||
to: 'on'
|
||||
|
||||
condition:
|
||||
- condition: state
|
||||
entity_id: sun.sun
|
||||
state: 'below_horizon'
|
||||
- condition: state
|
||||
entity_id: binary_sensor.sleepnumber_carlo_carlo_is_in_bed
|
||||
state: 'on'
|
||||
- condition: state
|
||||
entity_id: binary_sensor.sleepnumber_carlo_stacey_is_in_bed
|
||||
state: 'on'
|
||||
|
||||
action:
|
||||
- service: switch.turn_off
|
||||
entity_id: switch.back_landscaping
|
19
config/packages/light_sensor.yaml.old
Executable file
19
config/packages/light_sensor.yaml.old
Executable file
@@ -0,0 +1,19 @@
|
||||
#-------------------------------------------
|
||||
# Bruh Light Sensor Related Packages
|
||||
#-------------------------------------------
|
||||
#------LightSensor Node---http://amzn.to/2oUgj5i
|
||||
homeassistant:
|
||||
customize:
|
||||
sensor.sn1_ldr:
|
||||
icon: mdi:sensor
|
||||
friendly_name: Light Sensor
|
||||
#emulated_hue_hidden: False
|
||||
hidden: False
|
||||
#---Sensor for Light-----------------------------
|
||||
sensor:
|
||||
- platform: mqtt
|
||||
state_topic: "home/sensornode1"
|
||||
name: "SN1 LDR"
|
||||
##This sensor is not calibrated to actual LUX. Rather, this a map of the input voltage ranging from 0 - 1023.
|
||||
unit_of_measurement: "LUX"
|
||||
value_template: '{{ value_json.ldr }}'
|
46
config/packages/logger.yaml
Executable file
46
config/packages/logger.yaml
Executable file
@@ -0,0 +1,46 @@
|
||||
#-------------------------------------------
|
||||
# Realtime Debugging Related Packages
|
||||
# @CCOSTAN
|
||||
# Original Repo : https://github.com/CCOSTAN/Home-AssistantConfig
|
||||
#-------------------------------------------
|
||||
homeassistant:
|
||||
customize_glob:
|
||||
"input_select.log_*":
|
||||
icon: mdi:bug
|
||||
|
||||
hidden: False
|
||||
|
||||
#-------------------------------------------
|
||||
input_select:
|
||||
log_level:
|
||||
name: Log Level
|
||||
options:
|
||||
- critical
|
||||
- fatal
|
||||
- error
|
||||
- warning
|
||||
- warn
|
||||
- info
|
||||
- debug
|
||||
- notset
|
||||
initial: warn
|
||||
|
||||
###################################
|
||||
## Dynamically set the log levels without having to restart HASS or edit configuration.yaml
|
||||
#- Thanks @VDRainer
|
||||
###################################
|
||||
automation:
|
||||
- alias: Log Level
|
||||
trigger:
|
||||
platform: state
|
||||
entity_id:
|
||||
- input_select.log_level
|
||||
# - input_select.log_component
|
||||
action:
|
||||
- service: logger.set_level
|
||||
data_template:
|
||||
homeassistant.components: "{{ states.input_select.log_level.state }}"
|
||||
|
||||
- service: script.tweet_engine
|
||||
data_template:
|
||||
tweet: "My logging level has just been set to {{ states.input_select.log_level.state }}"
|
62
config/packages/minecraft.yaml
Executable file
62
config/packages/minecraft.yaml
Executable file
@@ -0,0 +1,62 @@
|
||||
#-------------------------------------------
|
||||
# @CCOSTAN
|
||||
# Original Repo : https://github.com/CCOSTAN/Home-AssistantConfig
|
||||
# Neato Support for D7 Connected Botvac - control my [Neato Vacuum](http://amzn.to/2kqnnqu) with Home Assistant.
|
||||
#-------------------------------------------
|
||||
# homeassistant:
|
||||
# customize_glob:
|
||||
# "*.*_sleep_hours":
|
||||
# unit_of_measurement: hours
|
||||
# icon: mdi:sleep
|
||||
#
|
||||
# hidden: False
|
||||
#-------------------------------------------
|
||||
sensor:
|
||||
platform: minecraft
|
||||
name: Bear Stone
|
||||
server: !secret minecraft
|
||||
#-------------------------------------------
|
||||
group:
|
||||
Minecraft:
|
||||
entities:
|
||||
- sensor.bear_stone
|
||||
|
||||
##############################################################################
|
||||
### Automations - Detect when things are not right. Like any Good Watchdog.
|
||||
##############################################################################
|
||||
#automation:
|
||||
#Tweets pushed out to twitter.
|
||||
automation:
|
||||
- alias: Someone on the MC server!
|
||||
trigger:
|
||||
- platform: state
|
||||
entity_id: sensor.bear_stone
|
||||
|
||||
action:
|
||||
- service: light.turn_on
|
||||
entity_id: light.justin_go
|
||||
data_template:
|
||||
color_name: >
|
||||
{% if states.sensor.bear_stone.state|int == 1 %}
|
||||
gold
|
||||
{% elif states.sensor.bear_stone.state|int == 2 %}
|
||||
green
|
||||
{% elif states.sensor.bear_stone.state|int == 3 %}
|
||||
blue
|
||||
{% else %}
|
||||
red
|
||||
{% endif %}
|
||||
|
||||
- service_template: >
|
||||
{% if states.sensor.bear_stone.state|int > 0 %}
|
||||
light.turn_on
|
||||
{% else %}
|
||||
light.turn_off
|
||||
{% endif %}
|
||||
entity_id: light.justin_go
|
||||
|
||||
- service: light.turn_on
|
||||
entity_id:
|
||||
- light.justin_go
|
||||
data:
|
||||
flash: short
|
32
config/packages/mychevy.yaml.disabled
Executable file
32
config/packages/mychevy.yaml.disabled
Executable file
@@ -0,0 +1,32 @@
|
||||
#-------------------------------------------
|
||||
# @CCOSTAN
|
||||
# Original Repo : https://github.com/CCOSTAN/Home-AssistantConfig
|
||||
###################################
|
||||
## [Chevy Bolt](http://amzn.to/2DRP83a)
|
||||
###################################
|
||||
|
||||
# homeassistant:
|
||||
# customize_glob:
|
||||
# "sensor.skybell_*":
|
||||
# icon: mdi:camera-front
|
||||
#
|
||||
# hidden: False
|
||||
# homebridge_hidden: True
|
||||
|
||||
group:
|
||||
bolt:
|
||||
name: Chevy Bolt EV
|
||||
control: hidden
|
||||
entities:
|
||||
- device_tracker.Carlo_Bolt
|
||||
- binary_sensor.mychevy_plugged_in
|
||||
- sensor.mychevy_charge_mode
|
||||
- sensor.mychevy_charging
|
||||
- sensor.mychevy_evcharge
|
||||
- sensor.mychevy_mileage
|
||||
- sensor.mychevy_range
|
||||
- sensor.mychevy_status
|
||||
|
||||
mychevy:
|
||||
username: !secret mychevy_email
|
||||
password: !secret mychevy_password
|
48
config/packages/neato.yaml.disabled
Executable file
48
config/packages/neato.yaml.disabled
Executable file
@@ -0,0 +1,48 @@
|
||||
#-------------------------------------------
|
||||
# @CCOSTAN
|
||||
# Original Repo : https://github.com/CCOSTAN/Home-AssistantConfig
|
||||
# Neato Support for D7 Connected Botvac - control my [Neato Vacuum](http://amzn.to/2kqnnqu) with Home Assistant.
|
||||
#-------------------------------------------
|
||||
# homeassistant:
|
||||
# customize_glob:
|
||||
# "*.*_sleep_hours":
|
||||
# unit_of_measurement: hours
|
||||
# icon: mdi:sleep
|
||||
#
|
||||
# hidden: False
|
||||
#-------------------------------------------
|
||||
neato:
|
||||
username: !secret neato_username
|
||||
password: !secret neato_password
|
||||
#-------------------------------------------
|
||||
group:
|
||||
Neato:
|
||||
entities:
|
||||
- camera.carloneato_cleaning_map
|
||||
- switch.carloneato_schedule
|
||||
- vacuum.carloneato
|
||||
##############################################################################
|
||||
### Automations - Detect when things are not right. Like any Good Watchdog.
|
||||
##############################################################################
|
||||
automation:
|
||||
- alias: 'Vacuum -Tweet'
|
||||
trigger:
|
||||
- platform: state
|
||||
entity_id: vacuum.carloneato
|
||||
to: 'off'
|
||||
from: 'on'
|
||||
|
||||
condition:
|
||||
- condition: template
|
||||
value_template: "{{ states.vacuum.carloneato.attributes.battery_level |int < 20 }}"
|
||||
|
||||
action:
|
||||
- service: script.tweet_engine
|
||||
data_template:
|
||||
tweet: >
|
||||
{{ [
|
||||
"#Neato returning to base. Vacuumed up a TON. (http://amzn.to/2CKHZya)",
|
||||
"Everyday I have the Neato Botvac go out and clean the house on its own.",
|
||||
"Since we have a cat that sheds all day, we have @Neato go out daily to clean.",
|
||||
"Time to recharge the @Neato Vacuum."
|
||||
] | random + " Battery Level:{{states.vacuum.carloneato.attributes.battery_level }} #Robots"}}
|
141
config/packages/nest_protects.yaml
Executable file
141
config/packages/nest_protects.yaml
Executable file
@@ -0,0 +1,141 @@
|
||||
######################################################################################################
|
||||
# Nest Protect Package
|
||||
# @CCOSTAN
|
||||
# Original Repo : https://github.com/CCOSTAN/Home-AssistantConfig
|
||||
# - Write up- http://www.vmwareinfo.com/2017/06/psa-check-out-your-smoke-detectors-once.html
|
||||
######################################################################################################
|
||||
#-----------------------------------
|
||||
homeassistant:
|
||||
customize:
|
||||
|
||||
binary_sensor.hallway_nest_protect_kids_hallway_online:
|
||||
friendly_name: Kids Hallway Protect
|
||||
icon: mdi:nest-protect
|
||||
|
||||
binary_sensor.justins_room_nest_protect_online:
|
||||
friendly_name: Justins Room Protect
|
||||
icon: mdi:nest-protect
|
||||
|
||||
binary_sensor.kitchen_nest_protect_online:
|
||||
friendly_name: Kitchen Protect
|
||||
icon: mdi:nest-protect
|
||||
|
||||
binary_sensor.master_bedroom_nest_protect_online:
|
||||
friendly_name: Master Bedroom Protect
|
||||
icon: mdi:nest-protect
|
||||
|
||||
binary_sensor.master_hallway_nest_protect_online:
|
||||
friendly_name: Master Hallway Protect
|
||||
icon: mdi:nest-protect
|
||||
|
||||
binary_sensor.paiges_room_nest_protect_paiges_room_online:
|
||||
friendly_name: Paiges Room Protect
|
||||
icon: mdi:nest-protect
|
||||
|
||||
binary_sensor.upstairs_bedroom_nest_protect_online:
|
||||
friendly_name: Upstairs Bedroom Protect
|
||||
icon: mdi:nest-protect
|
||||
|
||||
binary_sensor.upstairs_living_room_nest_protect_online:
|
||||
friendly_name: Upstairs Living Room Protect
|
||||
icon: mdi:nest-protect
|
||||
|
||||
binary_sensor.office_nest_protect_online:
|
||||
friendly_name: Office Protect
|
||||
icon: mdi:nest-protect
|
||||
|
||||
group.protects:
|
||||
homebridge_hidden: true
|
||||
#-------------------------------------------
|
||||
|
||||
#-------------------------------------------
|
||||
group:
|
||||
protects:
|
||||
name: Nest Protects
|
||||
entities:
|
||||
- binary_sensor.upstairs_living_room_nest_protect_online
|
||||
- binary_sensor.hallway_nest_protect_kids_hallway_online
|
||||
- binary_sensor.justins_room_nest_protect_online
|
||||
- binary_sensor.kitchen_nest_protect_online
|
||||
- binary_sensor.master_bedroom_nest_protect_online
|
||||
- binary_sensor.master_hallway_nest_protect_online
|
||||
- binary_sensor.paiges_room_nest_protect_paiges_room_online
|
||||
- binary_sensor.upstairs_bedroom_nest_protect_online
|
||||
- binary_sensor.office_nest_protect_online
|
||||
|
||||
#-------------------------------------------
|
||||
automation:
|
||||
- alias: Nest protect emergency
|
||||
hide_entity: true
|
||||
trigger:
|
||||
platform: state
|
||||
entity_id:
|
||||
- sensor.hallway_nest_protect_kids_hallway_smoke_status
|
||||
- sensor.hallway_nest_protect_kids_hallway_co_status
|
||||
- sensor.justins_room_nest_protect_smoke_status
|
||||
- sensor.justins_room_nest_protect_co_status
|
||||
- sensor.kitchen_nest_protect_smoke_status
|
||||
- sensor.kitchen_nest_protect_co_status
|
||||
- sensor.master_bedroom_nest_protect_smoke_status
|
||||
- sensor.master_bedroom_nest_protect_co_status
|
||||
- sensor.master_hallway_nest_protect_smoke_status
|
||||
- sensor.master_hallway_nest_protect_co_status
|
||||
- sensor.office_nest_protect_smoke_status
|
||||
- sensor.office_nest_protect_co_status
|
||||
- sensor.paiges_room_nest_protect_paiges_room_smoke_status
|
||||
- sensor.paiges_room_nest_protect_paiges_room_co_status
|
||||
- sensor.upstairs_bedroom_nest_protect_smoke_status
|
||||
- sensor.upstairs_bedroom_nest_protect_co_status
|
||||
- sensor.upstairs_living_room_nest_protect_smoke_status
|
||||
- sensor.upstairs_living_room_nest_protect_co_status
|
||||
to: 'Emergency'
|
||||
|
||||
condition:
|
||||
- condition: state
|
||||
entity_id: group.family
|
||||
state: 'home'
|
||||
|
||||
action:
|
||||
- service: script.emergency
|
||||
data_template:
|
||||
call_garage_open: 1
|
||||
- service: script.notify_engine
|
||||
data_template:
|
||||
value1: "An emergency has been detected on {{ trigger.to_state.attributes.friendly_name }} Please investigate IMMEDIATELY."
|
||||
|
||||
- service: script.tweet_engine
|
||||
data_template:
|
||||
tweet: "An emergency has been detected on {{ trigger.to_state.attributes.friendly_name }} @CCostan (http://www.vmwareinfo.com/2017/06/psa-check-out-your-smoke-detectors-once.html)"
|
||||
|
||||
- alias: Nest Protect Offline Notify
|
||||
hide_entity: true
|
||||
trigger:
|
||||
platform: state
|
||||
entity_id:
|
||||
- binary_sensor.upstairs_living_room_nest_protect_online
|
||||
- binary_sensor.hallway_nest_protect_kids_hallway_online
|
||||
- binary_sensor.justins_room_nest_protect_online
|
||||
- binary_sensor.kitchen_nest_protect_online
|
||||
- binary_sensor.master_bedroom_nest_protect_online
|
||||
- binary_sensor.master_hallway_nest_protect_online
|
||||
- binary_sensor.paiges_room_nest_protect_paiges_room_online
|
||||
- binary_sensor.upstairs_bedroom_nest_protect_online
|
||||
- binary_sensor.office_nest_protect_online
|
||||
from: 'on'
|
||||
|
||||
action:
|
||||
- service: input_boolean.turn_on
|
||||
entity_id: input_boolean.alert_mode
|
||||
|
||||
- service: script.speech_engine
|
||||
data_template:
|
||||
value1: "The {{ trigger.to_state.attributes.friendly_name }} is now {{ (trigger.to_state.state)|replace('_', ' ') }}. Please check immediately."
|
||||
|
||||
- service: script.notify_engine
|
||||
data_template:
|
||||
value1: "The {{ trigger.to_state.attributes.friendly_name }} is now {{ (trigger.to_state.state)|replace('_', ' ') }}. Please check immediately."
|
||||
who: "parents"
|
||||
|
||||
- service: script.tweet_engine
|
||||
data:
|
||||
tweet: "Oh NO! {{ trigger.to_state.attributes.friendly_name }} is now in {{ (trigger.to_state.state)|replace('_', ' ') }} mode. @Nest. (http://www.vmwareinfo.com/2017/06/psa-check-out-your-smoke-detectors-once.html) #Safety"
|
177
config/packages/network.yaml
Executable file
177
config/packages/network.yaml
Executable file
@@ -0,0 +1,177 @@
|
||||
#-------------------------------------------
|
||||
# Network Related Packages
|
||||
# @CCOSTAN
|
||||
# Original Repo : https://github.com/CCOSTAN/Home-AssistantConfig
|
||||
#-------------------------------------------
|
||||
|
||||
#-------------------------------------------
|
||||
sensor:
|
||||
- platform: template
|
||||
sensors:
|
||||
network:
|
||||
friendly_name: 'Network Monitor'
|
||||
value_template: >
|
||||
{%- set domains = ['device_tracker'] -%}
|
||||
{%- for domain in domains -%}
|
||||
{%- for item in states[domain]
|
||||
if (item.attributes.source_type is defined and item.state != 'home' and item.attributes.friendly_name not in
|
||||
[
|
||||
'Chromecast Audio 2',
|
||||
'Carlo',
|
||||
'Entry Alarm Panel',
|
||||
'Dash Button',
|
||||
'Master Bedroom Roku',
|
||||
'Juicebox',
|
||||
'Brother Printer',
|
||||
'Stacey',
|
||||
'Wii',
|
||||
'Withings Scale'
|
||||
])
|
||||
and(as_timestamp(now()) - as_timestamp(item.last_changed)) > 600 -%}
|
||||
{{ item.attributes.friendly_name }}
|
||||
{%- if not loop.last -%}
|
||||
{{'
|
||||
'}}
|
||||
{%- endif -%}
|
||||
{%- endfor -%}
|
||||
{%- endfor -%}
|
||||
|
||||
- platform: template
|
||||
sensors:
|
||||
network_detail:
|
||||
friendly_name: 'Network Monitor Detail'
|
||||
value_template: >
|
||||
{%- set domains = ['device_tracker'] -%}
|
||||
{%- for domain in domains -%}
|
||||
{%- for item in states[domain]
|
||||
if (item.attributes.source_type is defined and item.state != 'home' and item.attributes.friendly_name not in
|
||||
[
|
||||
'Carlo_Bolt_EV',
|
||||
'Chromecast Audio 2',
|
||||
'JuiceBox',
|
||||
'Carlo',
|
||||
'Entry Alarm Panel',
|
||||
'Dash Button',
|
||||
'Ipmdemounit',
|
||||
'Living Room Roku',
|
||||
'Master Bedroom Roku',
|
||||
'Brother Printer',
|
||||
'Stacey',
|
||||
'Wii',
|
||||
'Withings Scale'
|
||||
])
|
||||
and(as_timestamp(now()) - as_timestamp(item.last_changed)) > 600 -%}
|
||||
{{ item.attributes.friendly_name }} - {{((as_timestamp(now()) - as_timestamp(item.last_changed))/60) | round() }} minutes
|
||||
{%- if not loop.last -%}
|
||||
{{'
|
||||
'}}
|
||||
{%- endif -%}
|
||||
{%- endfor -%}
|
||||
{%- endfor -%}
|
||||
|
||||
group:
|
||||
network:
|
||||
entities:
|
||||
- sensor.ha_installed_version
|
||||
- sensor.ha_uptime
|
||||
- sensor.since_last_boot_templated
|
||||
- sensor.disk_use_percent_
|
||||
- sensor.database_sensor
|
||||
- sensor.speedtest_download
|
||||
- sensor.speedtest_upload
|
||||
- binary_sensor.carlowink
|
||||
- sensor.network
|
||||
- sensor.network_detail
|
||||
|
||||
# # Create full group with Loop!:
|
||||
# {% for state in states.device_tracker-%}
|
||||
# - {{ state.entity_id | lower }}
|
||||
# {{ ' '}}
|
||||
# {%- endfor -%}.
|
||||
|
||||
network_detail:
|
||||
entities:
|
||||
- device_tracker.alexa_echo
|
||||
- device_tracker.amazon_dot_2
|
||||
- device_tracker.amazon_fire_stick
|
||||
- device_tracker.amazon_tap
|
||||
- device_tracker.bedroom_alarm_panel
|
||||
- device_tracker.brother_printer
|
||||
- device_tracker.camera1
|
||||
- device_tracker.camera2
|
||||
- device_tracker.camera3
|
||||
- device_tracker.camera4
|
||||
- device_tracker.carlo
|
||||
- device_tracker.carlo_bolt
|
||||
- device_tracker.carlo_laptop
|
||||
- device_tracker.carlo_nvr
|
||||
- device_tracker.carlobhmain
|
||||
- device_tracker.carlopihole
|
||||
- device_tracker.chromecast_audio_1
|
||||
- device_tracker.chromecast_audio_2
|
||||
- device_tracker.circle
|
||||
- device_tracker.entry_alarm_panel
|
||||
- device_tracker.garage_ap
|
||||
- device_tracker.gatorade_dash
|
||||
- device_tracker.hue_hub_1
|
||||
- device_tracker.hue_hub_2
|
||||
- device_tracker.ipmdemounit
|
||||
- device_tracker.juicebox
|
||||
- device_tracker.justin_dot
|
||||
- device_tracker.large_garage
|
||||
- device_tracker.living_room_amp_outlet
|
||||
- device_tracker.living_room_roku
|
||||
- device_tracker.living_room_ultra
|
||||
- device_tracker.master_bedroom_roku
|
||||
- device_tracker.nest_downstairs
|
||||
- device_tracker.nest_upstairs
|
||||
- device_tracker.nodemcu1
|
||||
- device_tracker.nodemcu2
|
||||
- device_tracker.nodemcu3
|
||||
- device_tracker.nodemcu4
|
||||
- device_tracker.noon_switch
|
||||
- device_tracker.rachio
|
||||
- device_tracker.rgb_led_garage_large
|
||||
- device_tracker.rgb_led_garage_small
|
||||
- device_tracker.rgb_led_outdoor_den
|
||||
- device_tracker.rm_pro
|
||||
- device_tracker.samsungtv
|
||||
- device_tracker.skybell
|
||||
- device_tracker.sleep_number_bed
|
||||
- device_tracker.small_garage
|
||||
- device_tracker.smart_water_meter
|
||||
- device_tracker.stacey
|
||||
- device_tracker.study_ap
|
||||
- device_tracker.tablotv
|
||||
- device_tracker.unifi_ap_office
|
||||
- device_tracker.wii
|
||||
- device_tracker.withings_scale
|
||||
#-------------------------------------------------------------------------------------
|
||||
automation:
|
||||
- alias: 'Device Status'
|
||||
hide_entity: True
|
||||
trigger:
|
||||
- platform: state
|
||||
entity_id:
|
||||
- sensor.network
|
||||
- binary_sensor.carlowink
|
||||
|
||||
condition:
|
||||
- condition: template
|
||||
value_template: >
|
||||
{% if not is_state('sensor.network_detail', ' ') %}
|
||||
false
|
||||
{% else %}
|
||||
true
|
||||
{% endif %}
|
||||
|
||||
action:
|
||||
- service: script.notify_engine
|
||||
data_template:
|
||||
value1: 'Offline Devices:'
|
||||
value3: "{{ states.sensor.network_detail.state }}"
|
||||
who: 'carlo'
|
||||
|
||||
# - service: script.speech_engine
|
||||
# data_template:
|
||||
# value1: "The following Devices are in an Offline state {{ trigger.to_state.state }}"
|
79
config/packages/office_motion.yaml
Executable file
79
config/packages/office_motion.yaml
Executable file
@@ -0,0 +1,79 @@
|
||||
#-------------------------------------------
|
||||
# Motion Sensor in the office.
|
||||
# Find more recipes @ https://github.com/CCOSTAN/Home-AssistantConfig
|
||||
#-------------------------------------------
|
||||
#------LightSensor Node---http://amzn.to/2oUgj5i
|
||||
homeassistant:
|
||||
customize:
|
||||
binary_sensor.office_motion:
|
||||
friendly_name: Office Motion Sensor
|
||||
|
||||
hidden: False
|
||||
#---Sensor for Light-----------------------------
|
||||
binary_sensor:
|
||||
- platform: mqtt
|
||||
state_topic: "NodeMCU4/Motion/Motion"
|
||||
name: "Office_Motion"
|
||||
payload_on: 1
|
||||
payload_off: 0
|
||||
device_class: motion
|
||||
|
||||
# This boolean gets reset every night in the sunset automation.
|
||||
# Gets turned on by dash button automation primarily.
|
||||
input_boolean:
|
||||
daylight_override:
|
||||
name: Daylight Override
|
||||
initial: off
|
||||
|
||||
automation:
|
||||
- alias: 'Motion in the Office - Turn on Light'
|
||||
trigger:
|
||||
- platform: state
|
||||
entity_id:
|
||||
- binary_sensor.office_motion
|
||||
to: 'on'
|
||||
from: 'off'
|
||||
|
||||
condition:
|
||||
- condition: state
|
||||
entity_id: binary_sensor.sleepnumber_carlo_carlo_is_in_bed
|
||||
state: 'off'
|
||||
- condition: state
|
||||
entity_id: group.family
|
||||
state: 'home'
|
||||
- condition: state
|
||||
entity_id: light.office_lamp
|
||||
state: 'off'
|
||||
- condition: or
|
||||
conditions:
|
||||
- condition: time
|
||||
after: '18:00:00'
|
||||
- condition: state
|
||||
entity_id: sun.sun
|
||||
state: 'below_horizon'
|
||||
- condition: state
|
||||
entity_id: input_boolean.daylight_override
|
||||
state: 'on'
|
||||
|
||||
action:
|
||||
- service: light.turn_on
|
||||
entity_id: light.office_lamp
|
||||
|
||||
- alias: 'Motion in the Office - Turn off Light'
|
||||
trigger:
|
||||
- platform: state
|
||||
entity_id:
|
||||
- binary_sensor.office_motion
|
||||
to: 'off'
|
||||
from: 'on'
|
||||
for:
|
||||
minutes: 2
|
||||
|
||||
condition:
|
||||
- condition: state
|
||||
entity_id: light.office_lamp
|
||||
state: 'on'
|
||||
|
||||
action:
|
||||
- service: light.turn_off
|
||||
entity_id: light.office_lamp
|
124
config/packages/pihole.yaml
Executable file
124
config/packages/pihole.yaml
Executable file
@@ -0,0 +1,124 @@
|
||||
#-------------------------------------------
|
||||
# PiHole ad Blocking Related Packages
|
||||
#-------------------------------------------
|
||||
homeassistant:
|
||||
customize:
|
||||
|
||||
sensor.pihole_ads_percentage_today:
|
||||
friendly_name: Percentage of Ad Traffic Blocked
|
||||
unit_of_measurement: '%'
|
||||
icon: mdi:ticket-percent
|
||||
|
||||
sensor.pihole_domains_being_blocked:
|
||||
friendly_name: Total Domains Blocking
|
||||
icon: mdi:do-not-disturb
|
||||
|
||||
sensor.pihole_dns_unique_clients:
|
||||
friendly_name: Unique Clients
|
||||
icon: mdi:desktop-classic
|
||||
|
||||
sensor.pihole_ads_blocked_today:
|
||||
friendly_name: Ads Blocked Today
|
||||
icon: mdi:do-not-disturb
|
||||
|
||||
sensor.pihole_dns_queries_today:
|
||||
friendly_name: DNS Queries Today
|
||||
icon: mdi:note-text
|
||||
|
||||
sensor.carlopihole:
|
||||
friendly_name: Pi Hole Server
|
||||
icon: mdi:filter-variant
|
||||
|
||||
group.pihole:
|
||||
homebridge_hidden: true
|
||||
#-------------------------------------------
|
||||
sensor:
|
||||
- platform: pi_hole
|
||||
host: 192.168.10.11
|
||||
monitored_conditions:
|
||||
- dns_queries_today
|
||||
- ads_blocked_today
|
||||
- ads_percentage_today
|
||||
- unique_clients
|
||||
|
||||
######Custom Version sensor
|
||||
# - platform: command_line
|
||||
# command: "pihole -v -p -c"
|
||||
# name: 'pihole_version_current'
|
||||
# value_template: '{{ value[28:] }}'
|
||||
# scan_interval: 86400
|
||||
#
|
||||
# - platform: command_line
|
||||
# command: "pihole -v -p -l"
|
||||
# name: 'pihole_version_latest'
|
||||
# value_template: '{{ value[27:] }}'
|
||||
# scan_interval: 86400
|
||||
|
||||
- platform: template
|
||||
sensors:
|
||||
carlopihole:
|
||||
friendly_name: 'Carlo-PiHole'
|
||||
value_template: "{{ 'Online' if is_state('device_tracker.carlopihole', 'home') else 'Offline' }}"
|
||||
|
||||
# pi_hole_version:
|
||||
# value_template: "{%- if states.sensor.pihole_version_current.state == states.sensor.pihole_version_latest.state -%}{{states.sensor.pihole_version_current.state}} {% else %}{{states.sensor.pihole_version_latest.state}} Available{% endif%}"
|
||||
# icon_template: >-
|
||||
# {% if states.sensor.pihole_version_current.state == states.sensor.pihole_version_latest.state %}
|
||||
# mdi:checkbox-marked
|
||||
# {% else %}
|
||||
# mdi:checkbox-blank-outline
|
||||
# {% endif %}
|
||||
|
||||
# Pi-Hole switch
|
||||
switch:
|
||||
- platform: command_line
|
||||
switches:
|
||||
pihole_temp_disable:
|
||||
command_on: "curl -X GET 'http://192.168.10.11/admin/api.php?enable&auth='"
|
||||
command_off: "curl -X GET 'http://192.168.10.11/admin/api.php?disable=3600&auth='"
|
||||
# command_state: "curl -X GET 'http://192.168.10.11/admin/api.php?status'| grep enabled"
|
||||
# value_template: "{{ value_json.status == 'enabled' }}
|
||||
|
||||
#-------------------------------------------
|
||||
group:
|
||||
pihole:
|
||||
entities:
|
||||
- sensor.carlopihole
|
||||
- sensor.pi_hole_version
|
||||
- sensor.pihole_dns_unique_clients
|
||||
- sensor.pihole_dns_queries_today
|
||||
- sensor.pihole_ads_blocked_today
|
||||
- sensor.pihole_ads_percentage_today
|
||||
- sensor.pihole_ads_percentage_blocked_today
|
||||
- switch.pihole_temp_disable
|
||||
#-------------------------------------------
|
||||
|
||||
|
||||
automation:
|
||||
- alias: PiHole Daily stats Tweet!
|
||||
trigger:
|
||||
platform: time
|
||||
at: '23:50:00'
|
||||
action:
|
||||
- delay: '00:{{ (range(1, 9)|random|int) }}:00'
|
||||
- service: script.tweet_engine
|
||||
data_template:
|
||||
tweet: >
|
||||
{{ [
|
||||
"I blocked {{states.sensor.pihole_ads_blocked_today.state}} ads. That is {{states.sensor.pihole_ads_percentage_blocked_today.state}}% of my internet traffic.",
|
||||
"Today was a good day! Why, you ask? Because I blocked {{states.sensor.pihole_ads_blocked_today.state}} ads via Pi-Hole!",
|
||||
] | random + " #PiHole #Security Status:({{states.sensor.carlopihole.state}})"}}
|
||||
|
||||
- alias: PiHole Daily Client Tweet!
|
||||
trigger:
|
||||
platform: time
|
||||
at: '04:30:00'
|
||||
action:
|
||||
- delay: '{{ (range(1, 6)|random|int) }}:{{ (range(1, 50)|random|int) }}:00'
|
||||
- service: script.tweet_engine
|
||||
data_template:
|
||||
tweet: >
|
||||
{{ [
|
||||
"There are currently {{states.sensor.pihole_dns_unique_clients.state}} clients on my network.",
|
||||
"As reported by #Ubiquity Routers, There are {{states.sensor.pihole_dns_unique_clients.state}} clients on my network.",
|
||||
] | random + "#Security http://amzn.to/2D2AfXS"}}
|
58
config/packages/processmonitor.yaml
Executable file
58
config/packages/processmonitor.yaml
Executable file
@@ -0,0 +1,58 @@
|
||||
#-------------------------------------------
|
||||
# @CCOSTAN
|
||||
# Original Repo : https://github.com/CCOSTAN/Home-AssistantConfig
|
||||
#-------------------------------------------
|
||||
# homeassistant:
|
||||
# customize:
|
||||
# sensor.process_mosquitto:
|
||||
# friendly_name: 'Mosquitto'
|
||||
#
|
||||
# hidden: False
|
||||
|
||||
#-------------------------------------------
|
||||
sensor:
|
||||
- platform: systemmonitor
|
||||
resources:
|
||||
# - type: last_boot
|
||||
- type: since_last_boot
|
||||
- type: disk_use_percent
|
||||
arg: /
|
||||
- platform: database
|
||||
#-------------------------------------------
|
||||
##############################################################################
|
||||
### Automations - Detect when things are not right. Like any Good Watchdog.
|
||||
##############################################################################
|
||||
|
||||
automation:
|
||||
|
||||
- alias: "Self Heal Disk Use Alarm"
|
||||
trigger:
|
||||
- platform: numeric_state
|
||||
entity_id: sensor.disk_use_percent_
|
||||
above: 80
|
||||
action:
|
||||
- service: script.notify_engine
|
||||
data_template:
|
||||
value1: 'Hard Drive Monitor:'
|
||||
value2: "Your harddrive is running out of Space! /dev/root:{{ states.sensor.disk_use_percent_.state }}%!"
|
||||
value3: 'Attempting to clean'
|
||||
who: 'carlo'
|
||||
- service: tts.clear_cache
|
||||
|
||||
- alias: "Disk Use Alarm"
|
||||
trigger:
|
||||
- platform: numeric_state
|
||||
entity_id: sensor.disk_use_percent_
|
||||
above: 90
|
||||
action:
|
||||
- service: script.notify_engine
|
||||
data_template:
|
||||
value1: 'Hard Drive Monitor:'
|
||||
value2: "Your harddrive is running out of Space! /dev/root:{{ states.sensor.disk_use_percent_.state }}%!"
|
||||
who: 'carlo'
|
||||
|
||||
- service: persistent_notification.create
|
||||
data:
|
||||
title: "Hard Drive Monitor:"
|
||||
message: "Your harddrive is running out of Space! /dev/root:{{ states.sensor.disk_use_percent_.state }}%!"
|
||||
notification_id: "Critical Alert"
|
69
config/packages/radio.yaml
Executable file
69
config/packages/radio.yaml
Executable file
@@ -0,0 +1,69 @@
|
||||
#-------------------------------------------
|
||||
# Radio Related Packages
|
||||
# @CCOSTAN
|
||||
# Original Repo : https://github.com/CCOSTAN/Home-AssistantConfig
|
||||
#-------------------------------------------
|
||||
#------Whole House Radio Enabled via Emulated Hue----------------------------
|
||||
homeassistant:
|
||||
customize:
|
||||
input_boolean.house_station:
|
||||
icon: mdi:radio
|
||||
friendly_name: House Station
|
||||
|
||||
hidden: False
|
||||
#---Use this Boolean to trigger via GUI or Alexa------------------------------
|
||||
input_boolean:
|
||||
house_station:
|
||||
name: House Station
|
||||
initial: off
|
||||
|
||||
#Moved to the Alarm Clock Package.
|
||||
|
||||
# #-----Turn on the Music--------------------------------------
|
||||
# automation:
|
||||
# - alias: 'Play Americas Country on ChromeCast Audio'
|
||||
#
|
||||
# trigger:
|
||||
# - platform: state
|
||||
# entity_id:
|
||||
# - input_boolean.house_station
|
||||
# to: 'on'
|
||||
# from: 'off'
|
||||
#
|
||||
# action:
|
||||
# - service: media_player.turn_off
|
||||
# entity_id: media_player.living_room_tv
|
||||
#
|
||||
# - service: media_player.turn_on
|
||||
# entity_id: media_player.livingroomCC
|
||||
#
|
||||
# - service: media_player.volume_set
|
||||
# entity_id:
|
||||
# - media_player.livingroomCC
|
||||
# data_template:
|
||||
# volume_level: 0.2
|
||||
#
|
||||
# - service: media_player.play_media
|
||||
# data_template:
|
||||
# entity_id:
|
||||
# - media_player.LivingRoomCC
|
||||
# media_content_id: "http://listen.181fm.com/181-kickincountry_128k.mp3"
|
||||
# #media_content_id: "http://listen.djcmedia.com:80/americascountryhigh"
|
||||
# media_content_type: audio/mp4
|
||||
#
|
||||
# #-----Turn off the Music--------------------------------------
|
||||
# - alias: 'Turn off the Radio'
|
||||
#
|
||||
# trigger:
|
||||
# - platform: state
|
||||
# entity_id:
|
||||
# - input_boolean.house_station
|
||||
# to: 'off'
|
||||
# from: 'on'
|
||||
#
|
||||
# action:
|
||||
# - service: media_player.turn_off
|
||||
# entity_id: media_player.livingroomCC
|
||||
#
|
||||
# - service: input_boolean.turn_off
|
||||
# entity_id: input_boolean.house_station
|
123
config/packages/skybellhd.yaml
Executable file
123
config/packages/skybellhd.yaml
Executable file
@@ -0,0 +1,123 @@
|
||||
#-------------------------------------------
|
||||
# @CCOSTAN
|
||||
# Original Repo : https://github.com/CCOSTAN/Home-AssistantConfig
|
||||
###################################
|
||||
## [SkyBell HD](http://amzn.to/2dcexIB)
|
||||
###################################
|
||||
|
||||
homeassistant:
|
||||
customize_glob:
|
||||
"sensor.skybell_*":
|
||||
icon: mdi:camera-front
|
||||
|
||||
hidden: False
|
||||
homebridge_hidden: True
|
||||
|
||||
group:
|
||||
skybell:
|
||||
name: Skybell HD Front Door
|
||||
control: hidden
|
||||
entities:
|
||||
- binary_sensor.skybell_stone_door_button
|
||||
- binary_sensor.skybell_stone_door_motion
|
||||
- camera.stone_door
|
||||
- sensor.skybell_stone_door_chime_level
|
||||
- sensor.skybell_stone_door_motion_sensor
|
||||
- switch.skybell_stone_door_do_not_disturb
|
||||
- switch.skybell_stone_door_motion_sensor
|
||||
|
||||
skybell:
|
||||
username: !secret skybell_username
|
||||
password: !secret skybell_password
|
||||
|
||||
camera:
|
||||
- platform: skybell
|
||||
|
||||
binary_sensor:
|
||||
- platform: skybell
|
||||
monitored_conditions:
|
||||
- button
|
||||
- motion
|
||||
|
||||
light:
|
||||
- platform: skybell # Part of the Outdoor Front Lights Group
|
||||
|
||||
sensor:
|
||||
- platform: skybell
|
||||
monitored_conditions:
|
||||
- chime_level
|
||||
|
||||
switch:
|
||||
- platform: skybell
|
||||
monitored_conditions:
|
||||
- do_not_disturb
|
||||
- motion_sensor
|
||||
|
||||
###################################
|
||||
## Automations
|
||||
###################################
|
||||
## Doorbell Press
|
||||
automation:
|
||||
- alias: 'Log SkyBell Pressed Activity'
|
||||
hide_entity: True
|
||||
trigger:
|
||||
- platform: state
|
||||
entity_id:
|
||||
- binary_sensor.skybell_stone_door_button
|
||||
to: 'on'
|
||||
# - platform: event
|
||||
# event_type: skybell_pressed
|
||||
|
||||
condition:
|
||||
- condition: template
|
||||
value_template: >
|
||||
{%- if states.binary_sensor.skybell_stone_door_button.attributes.last_triggered -%}
|
||||
{{ (as_timestamp(now()) - as_timestamp(states.binary_sensor.skybell_stone_door_button.attributes.last_triggered)) > 200 }}
|
||||
{%- else -%}
|
||||
true
|
||||
{%- endif -%}
|
||||
|
||||
action:
|
||||
- service: script.skybell_pressed
|
||||
- service: script.tweet_engine
|
||||
data_template:
|
||||
tweet: >
|
||||
{{ [
|
||||
"Oh, that tickled. Someone just pressed the @MySkyBell.",
|
||||
"Ouch! That hurt. Who touched the SkyBell Doorbell?",
|
||||
"Someone just poked me in the @MySkybell!",
|
||||
"I see you! You are at the @MySkyBell and you just pressed it.",
|
||||
"Someone answer my door. Someone just pressed the doorbell."
|
||||
] | random + [
|
||||
" #Security",
|
||||
" (http://amzn.to/2dcexIB)",
|
||||
" (http://www.vmwareinfo.com/2017/07/my-smart-home-look-at-parts-that-make.html)",
|
||||
" #HomeAutomation"
|
||||
] | random }}
|
||||
|
||||
# Motion Sensing
|
||||
- alias: 'Log SkyBell Motion detection'
|
||||
hide_entity: True
|
||||
trigger:
|
||||
- platform: event
|
||||
event_type: skybell_motion
|
||||
|
||||
action:
|
||||
- service: script.front_house_motion
|
||||
|
||||
# Turn SkyBell Light and Neato Schedule back on if it's turned off. Like any Good Watchdog.
|
||||
|
||||
- alias: Automated Mismatch WatchDog!
|
||||
hide_entity: True
|
||||
trigger:
|
||||
- platform: state
|
||||
entity_id:
|
||||
- light.stone_door
|
||||
- switch.carloneato_schedule
|
||||
to: 'off'
|
||||
|
||||
#Turn it back on!
|
||||
action:
|
||||
- service: homeassistant.turn_on
|
||||
data_template:
|
||||
entity_id: "{{ trigger.entity_id }}"
|
54
config/packages/sleepiq.yaml
Executable file
54
config/packages/sleepiq.yaml
Executable file
@@ -0,0 +1,54 @@
|
||||
#-------------------------------------------
|
||||
# @CCOSTAN
|
||||
# Original Repo : https://github.com/CCOSTAN/Home-AssistantConfig
|
||||
#-------------------------------------------
|
||||
homeassistant:
|
||||
customize_glob:
|
||||
"sensor.*_sleep_hours":
|
||||
unit_of_measurement: hours
|
||||
icon: mdi:sleep
|
||||
|
||||
hidden: False
|
||||
# customize:
|
||||
# sensor.Carlo_sleep_hours:
|
||||
# friendly_name: 'Carlo Slept last night'
|
||||
# sensor.Stacey_sleep_hours:
|
||||
# friendly_name: 'Stacey Slept last night'
|
||||
|
||||
#-------------------------------------------
|
||||
sleepiq:
|
||||
username: !secret sleepiq_username
|
||||
password: !secret sleepiq_password
|
||||
#-------------------------------------------
|
||||
# sensor:
|
||||
# - platform: history_stats
|
||||
# name: Carlo_sleep_hours
|
||||
# entity_id: binary_sensor.sleepnumber_carlo_carlo_is_in_bed
|
||||
# state: 'on'
|
||||
# type: time
|
||||
# end: '{{ now() }}'
|
||||
# duration:
|
||||
# hours: 24
|
||||
#
|
||||
# - platform: history_stats
|
||||
# name: Stacey_sleep_hours
|
||||
# entity_id: binary_sensor.sleepnumber_carlo_stacey_is_in_bed
|
||||
# state: 'on'
|
||||
# type: time
|
||||
# end: '{{ now() }}'
|
||||
# duration:
|
||||
# hours: 24
|
||||
|
||||
group:
|
||||
bed:
|
||||
entities:
|
||||
- binary_sensor.sleepnumber_carlo_carlo_is_in_bed
|
||||
- sensor.sleepnumber_carlo_carlo_sleepnumber
|
||||
# - sensor.Carlo_sleep_hours
|
||||
- binary_sensor.sleepnumber_carlo_stacey_is_in_bed
|
||||
- sensor.sleepnumber_carlo_stacey_sleepnumber
|
||||
# - sensor.Stacey_sleep_hours
|
||||
|
||||
##############################################################################
|
||||
### Automations - Detect when things are not right. Like any Good Watchdog.
|
||||
##############################################################################
|
120
config/packages/space.yaml
Executable file
120
config/packages/space.yaml
Executable file
@@ -0,0 +1,120 @@
|
||||
#-------------------------------------------
|
||||
# Space Related Packages
|
||||
# @CCOSTAN
|
||||
# Original Repo : https://github.com/CCOSTAN/Home-AssistantConfig
|
||||
#-------------------------------------------
|
||||
#------ISS----------------------------------
|
||||
homeassistant:
|
||||
customize:
|
||||
binary_sensor.iss:
|
||||
icon: mdi:satellite-variant
|
||||
friendly_name: ISS Visibility
|
||||
|
||||
hidden: False
|
||||
homebridge_hidden: true
|
||||
sensor.launch_window:
|
||||
hidden: False
|
||||
icon: mdi:rocket
|
||||
friendly_name: Rocket Launch Window
|
||||
#-------------------------------------------
|
||||
binary_sensor:
|
||||
- platform: iss
|
||||
show_on_map: False
|
||||
#-------------------------------------------
|
||||
|
||||
sensor:
|
||||
|
||||
- platform: moon
|
||||
|
||||
- platform: rest
|
||||
scan_interval: 3600
|
||||
resource: https://launchlibrary.net/1.2.2/launch/next/10
|
||||
# resource: https://raw.githubusercontent.com/cribbstechnologies/ha_config/master/www/test_launch.json
|
||||
name: launch window
|
||||
# if the current timestamp is in the launch window
|
||||
# this sensor will return the UTC timestamp of the launch
|
||||
value_template: >-
|
||||
{%- for launch in value_json.launches %}
|
||||
{% if launch.location.id == 16 or launch.location.id == 17 %}
|
||||
{% if strptime(launch.isostart, '%Y%m%dT%H%M%SZ').strftime('%Y-%m-%d') == now().strftime('%Y-%m-%d') %}
|
||||
{% set utc_offset_string = now().strftime('%z') %}
|
||||
{% set utc_offset_direction = utc_offset_string[:1] %}
|
||||
{% set utc_offset_hours = now().strftime('%z')[-4:] %}
|
||||
{% set utc_offset_seconds = (utc_offset_hours| int /100) * 60 * 60 %}
|
||||
{% if utc_offset_direction == '-' %}
|
||||
{{ launch.wsstamp - utc_offset_seconds}}
|
||||
{% else %}
|
||||
{{ launch.wsstamp + utc_offset_seconds}}
|
||||
{% endif %}
|
||||
{% endif %}
|
||||
{% endif %}
|
||||
{% endfor %}
|
||||
|
||||
automation:
|
||||
- alias: Launch Window Approaching
|
||||
trigger:
|
||||
- platform: state
|
||||
entity_id: sensor.launch_window
|
||||
condition:
|
||||
condition: and
|
||||
conditions:
|
||||
- condition: template
|
||||
value_template: "{{states('sensor.launch_window') != 'unknown'}}"
|
||||
- condition: template
|
||||
value_template: "{{as_timestamp(now()) < (states('sensor.launch_window') | float)}}"
|
||||
|
||||
action:
|
||||
- service: script.notify_engine
|
||||
data_template:
|
||||
value1: 'There will be a rocket Launch today - I will notify you later when the launch window starts'
|
||||
- wait_template: >-
|
||||
{{as_timestamp(now()) >= (states('sensor.launch_window') | float)}}
|
||||
- service: script.notify_engine
|
||||
data_template:
|
||||
value1: 'Go Outside! There is a Rocket Launch!'
|
||||
|
||||
- service: script.tweet_engine
|
||||
data_template:
|
||||
tweet: 'There is a Rocket launch happening right now! I can see it if I look closely. @BrianCribbs #SpaceX #Space'
|
||||
|
||||
# This automation was also moved to a macro in the speech_engine.
|
||||
# It's a random fact now.
|
||||
|
||||
- alias: 'ISS is above Me -Tweet'
|
||||
|
||||
trigger:
|
||||
- platform: state
|
||||
entity_id:
|
||||
- binary_sensor.iss
|
||||
to: 'on'
|
||||
from: 'off'
|
||||
|
||||
action:
|
||||
- service: script.tweet_engine
|
||||
data_template:
|
||||
tweet: >
|
||||
{{ [
|
||||
"The ISS is above me right now!",
|
||||
"The International Space Station flys by once a day & that time is NOW! (For me)",
|
||||
"I can look up RIGHT NOW and see the International Space Station.",
|
||||
"The #ISS just flew by and there is 1 Starman driving a #Tesla and {{states.binary_sensor.iss.attributes.number_of_people_in_space}} people in",
|
||||
"The #ISS just flew by and there are {{states.binary_sensor.iss.attributes.number_of_people_in_space}} people in",
|
||||
"The International Space Station Rocks! And it's above me RIGHT NOW!"
|
||||
] | random + " #Space"}}
|
||||
|
||||
- alias: 'Full Moon -Tweet'
|
||||
trigger:
|
||||
- platform: state
|
||||
entity_id: sensor.moon
|
||||
to: 'Full Moon'
|
||||
action:
|
||||
- delay: '{{ (range(1, 6)|random|int) }}:{{ (range(1, 50)|random|int) }}:00'
|
||||
- service: script.tweet_engine
|
||||
data_template:
|
||||
tweet: >
|
||||
{{ [
|
||||
"There is a Full Moon out tonight!",
|
||||
"Wish my solar panels picked up Moon rays. Full Moon out tonight.",
|
||||
"Turn down the lights, there is a Full Moon out tonight.",
|
||||
"Get out your telescopes, it'll be a Full Moon out tonight!"
|
||||
] | random + "#Space"}}
|
17
config/packages/synology.yaml
Executable file
17
config/packages/synology.yaml
Executable file
@@ -0,0 +1,17 @@
|
||||
#-------------------------------------------
|
||||
# @CCOSTAN
|
||||
# Original Repo : https://github.com/CCOSTAN/Home-AssistantConfig
|
||||
#-------------------------------------------
|
||||
# homeassistant:
|
||||
# customize_glob:
|
||||
# "sensor.carlo_6*":
|
||||
#
|
||||
# "sensor.staceys_iphone_*":
|
||||
|
||||
camera:
|
||||
- platform: synology
|
||||
url: !secret synology_url
|
||||
username: !secret synology_username
|
||||
password: !secret synology_password
|
||||
timeout: 15
|
||||
verify_ssl: False
|
60
config/packages/time_date_sensors.yaml
Executable file
60
config/packages/time_date_sensors.yaml
Executable file
@@ -0,0 +1,60 @@
|
||||
#-------------------------------------------
|
||||
# Clean data for the Floorplan UI.
|
||||
#-------------------------------------------
|
||||
homeassistant:
|
||||
customize_glob:
|
||||
"sensor.floorplan_*":
|
||||
|
||||
hidden: True
|
||||
homebridge_hidden: True
|
||||
"sensor.clock_*":
|
||||
|
||||
hidden: True
|
||||
homebridge_hidden: True
|
||||
#---Sensor for Time and Date.-----------------------------
|
||||
sensor:
|
||||
- platform: template
|
||||
scan_interval: 30000
|
||||
sensors:
|
||||
floorplan_date:
|
||||
friendly_name: 'Date'
|
||||
value_template: >-
|
||||
{{now().strftime("%A")}}, {{now().strftime("%B")}} {{now().strftime("%d")}}
|
||||
|
||||
- platform: template
|
||||
sensors:
|
||||
floorplan_time:
|
||||
friendly_name: 'Time'
|
||||
value_template: >-
|
||||
{{now().strftime("%-I")}}:{{now().strftime("%M")}} {{now().strftime("%p")}}
|
||||
|
||||
- platform: template
|
||||
sensors:
|
||||
clock_time:
|
||||
friendly_name: 'Clock Time'
|
||||
value_template: >-
|
||||
{{now().strftime("%-I")}}:{{now().strftime("%M")}}
|
||||
|
||||
- platform: template
|
||||
scan_interval: 30000
|
||||
sensors:
|
||||
clock_am_pm:
|
||||
friendly_name: 'AM/PM'
|
||||
value_template: >-
|
||||
{{now().strftime("%p")}}
|
||||
|
||||
- platform: template
|
||||
scan_interval: 30000
|
||||
sensors:
|
||||
clock_day:
|
||||
friendly_name: 'Day'
|
||||
value_template: >-
|
||||
{{now().strftime("%A")}}
|
||||
|
||||
- platform: template
|
||||
scan_interval: 30000
|
||||
sensors:
|
||||
clock_date:
|
||||
friendly_name: 'Clock Date'
|
||||
value_template: >-
|
||||
{{now().strftime("%B")}} {{now().strftime("%d")}} {{now().year}}
|
49
config/packages/triggers/last_message.yaml
Executable file
49
config/packages/triggers/last_message.yaml
Executable file
@@ -0,0 +1,49 @@
|
||||
#-------------------------------------------
|
||||
# @CCOSTAN
|
||||
# Original Repo : https://github.com/CCOSTAN/Home-AssistantConfig
|
||||
#-------------------------------------------
|
||||
homeassistant:
|
||||
customize:
|
||||
input_boolean.lastmsg:
|
||||
friendly_name: 'Repeat Message'
|
||||
icon: mdi:repeat-once
|
||||
|
||||
hidden: False
|
||||
#-------------------------------------------
|
||||
input_boolean:
|
||||
lastmsg:
|
||||
name: Last Message
|
||||
initial: off
|
||||
#-------------------------------------------
|
||||
sensor:
|
||||
- platform: mqtt
|
||||
state_topic: "polly/lastmsg"
|
||||
name: "Last Message"
|
||||
##############################################################################
|
||||
### Automations -
|
||||
##############################################################################
|
||||
|
||||
automation:
|
||||
- alias: 'Repeat Last Message'
|
||||
|
||||
trigger:
|
||||
- platform: state
|
||||
entity_id: input_boolean.lastmsg
|
||||
to: 'on'
|
||||
|
||||
action:
|
||||
- service: tts.amazon_polly_say
|
||||
entity_id:
|
||||
- media_player.livingroomCC
|
||||
- media_player.entry_alarm_panel
|
||||
- media_player.bedroom_alarm_panel
|
||||
data_template:
|
||||
message: >
|
||||
<speak>
|
||||
{{states.sensor.last_message.state}}
|
||||
</speak>
|
||||
cache: true
|
||||
|
||||
- service: input_boolean.turn_off
|
||||
entity_id:
|
||||
- input_boolean.lastmsg
|
23
config/packages/triggers/mqtt_screens.yaml.disabled
Executable file
23
config/packages/triggers/mqtt_screens.yaml.disabled
Executable file
@@ -0,0 +1,23 @@
|
||||
#-------------------------------------------
|
||||
# @CCOSTAN
|
||||
# Original Repo : https://github.com/CCOSTAN/Home-AssistantConfig
|
||||
# More information : https://github.com/SmilyOrg/screenmqtt
|
||||
#-------------------------------------------
|
||||
homeassistant:
|
||||
customize:
|
||||
switch.computer_screens:
|
||||
friendly_name: 'Computer Screens'
|
||||
icon: mdi:monitor-multiple
|
||||
emulated_hue_hidden: False
|
||||
hidden: False
|
||||
homebridge_hidden: False
|
||||
|
||||
#-------------------------------------------
|
||||
switch:
|
||||
- platform: mqtt
|
||||
name: computer_screens
|
||||
state_topic: 'carlo-ultra/monitor/all/power/state'
|
||||
command_topic: 'carlo-ultra/monitor/all/power/command'
|
||||
|
||||
#-------------------------------------------
|
||||
#group - Added to group.interior_switches
|
66
config/packages/triggers/self_destruct.yaml
Executable file
66
config/packages/triggers/self_destruct.yaml
Executable file
@@ -0,0 +1,66 @@
|
||||
#-------------------------------------------
|
||||
# @CCOSTAN
|
||||
# Original Repo : https://github.com/CCOSTAN/Home-AssistantConfig
|
||||
#-------------------------------------------
|
||||
homeassistant:
|
||||
customize:
|
||||
input_boolean.self_destruct:
|
||||
friendly_name: 'Self Destruct'
|
||||
icon: mdi:skull
|
||||
|
||||
hidden: False
|
||||
#-------------------------------------------
|
||||
input_boolean:
|
||||
self_destruct:
|
||||
name: Self Destruct
|
||||
initial: off
|
||||
|
||||
#-------------------------------------------
|
||||
##############################################################################
|
||||
### Pretend to blow up the house..
|
||||
##############################################################################
|
||||
|
||||
automation:
|
||||
- alias: 'Self Destruct sequence'
|
||||
trigger:
|
||||
- platform: state
|
||||
entity_id: input_boolean.self_destruct
|
||||
to: 'on'
|
||||
|
||||
action:
|
||||
- service: media_player.turn_on
|
||||
entity_id: media_player.livingroomCC
|
||||
|
||||
- service: switch.turn_on
|
||||
entity_id: switch.living_room_amp
|
||||
- delay: '00:00:05'
|
||||
|
||||
- service: media_player.volume_set
|
||||
entity_id:
|
||||
- media_player.livingroomCC
|
||||
data:
|
||||
volume_level: 0.22
|
||||
|
||||
- service: media_player.play_media
|
||||
entity_id:
|
||||
- media_player.livingroomCC
|
||||
- media_player.entry_alarm_panel
|
||||
- media_player.bedroom_alarm_panel
|
||||
data_template:
|
||||
media_content_id: >
|
||||
"https://raw.githubusercontent.com/CCOSTAN/Home-AssistantConfig/master/sounds/speechcons/self_destruct.mp3"
|
||||
media_content_type: audio/mp4
|
||||
- service: light.turn_on
|
||||
entity_id:
|
||||
- group.all_lights
|
||||
data:
|
||||
flash: long
|
||||
- service: switch.turn_off
|
||||
entity_id:
|
||||
- group.all_switches
|
||||
- service: light.turn_off
|
||||
entity_id:
|
||||
- group.all_lights
|
||||
- service: input_boolean.turn_off
|
||||
entity_id:
|
||||
- input_boolean.self_destruct
|
49
config/packages/triggers/sleepy_dog.yaml
Executable file
49
config/packages/triggers/sleepy_dog.yaml
Executable file
@@ -0,0 +1,49 @@
|
||||
#-------------------------------------------
|
||||
# @CCOSTAN
|
||||
# Original Repo : https://github.com/CCOSTAN/Home-AssistantConfig
|
||||
#-------------------------------------------
|
||||
homeassistant:
|
||||
customize:
|
||||
input_boolean.sleepy_dog:
|
||||
friendly_name: 'Sleepy Dog'
|
||||
icon: mdi:bell-sleep
|
||||
|
||||
hidden: False
|
||||
#-------------------------------------------
|
||||
input_boolean:
|
||||
sleepy_dog:
|
||||
name: Sleep Dog
|
||||
initial: off
|
||||
|
||||
#-------------------------------------------
|
||||
##############################################################################
|
||||
### Automations - Detect when things are not right. Like any Good Watchdog.
|
||||
##############################################################################
|
||||
|
||||
automation:
|
||||
- alias: 'Snooze the Dog for 30 minutes'
|
||||
trigger:
|
||||
- platform: state
|
||||
entity_id: input_boolean.sleepy_dog
|
||||
to: 'on'
|
||||
|
||||
action:
|
||||
# Disable automation for 30 minutes
|
||||
- service: automation.turn_off
|
||||
entity_id: automation.guard_dog
|
||||
- service: input_boolean.turn_off
|
||||
entity_id: input_boolean.sleepy_dog
|
||||
- service: script.speech_engine
|
||||
data_template:
|
||||
call_no_announcement: 1
|
||||
value1: >
|
||||
{{ [
|
||||
"The dogs have been put away for the next 30 minutes.",
|
||||
"I will let sleeping dogs lie for the next 30 minutes.",
|
||||
"You will not be bothered by the sound of dogs barking for at least 30 minutes.",
|
||||
"Sleepy Dog activated. Molly is our only watch cat for the next 30 minutes."
|
||||
] |random }}
|
||||
- delay:
|
||||
minutes: 30
|
||||
- service: automation.turn_on
|
||||
entity_id: automation.guard_dog
|
187
config/packages/twitter.yaml
Executable file
187
config/packages/twitter.yaml
Executable file
@@ -0,0 +1,187 @@
|
||||
#-------------------------------------------
|
||||
# This is the configuration account for @BearStoneHA - My Home's automated twitter account.
|
||||
# @CCOSTAN
|
||||
# Original Repo : https://github.com/CCOSTAN/Home-AssistantConfig
|
||||
#-------------------------------------------
|
||||
# homeassistant:
|
||||
# customize_glob:
|
||||
# "input_select.log_*":
|
||||
# icon: mdi:bug
|
||||
#
|
||||
# hidden: False
|
||||
|
||||
#Random number - https://www.random.org/integers/?num=1&min=1&max=10&col=1&base=10&format=plain&rnd=new
|
||||
|
||||
notify:
|
||||
- name: BearStoneHA
|
||||
platform: twitter
|
||||
consumer_key: !secret twitter_consumer_key
|
||||
consumer_secret: !secret twitter_consumer_secret
|
||||
access_token: !secret twitter_access_token
|
||||
access_token_secret: !secret twitter_access_token_secret
|
||||
|
||||
### Building out some Historical stats for tweeting. #####################
|
||||
sensor:
|
||||
|
||||
- platform: history_stats
|
||||
name: Doorbell Presses
|
||||
entity_id: binary_sensor.skybell_stone_door_button
|
||||
state: 'on'
|
||||
type: count
|
||||
end: '{{ now() }}'
|
||||
duration:
|
||||
hours: 24
|
||||
|
||||
- platform: history_stats
|
||||
name: Speech time
|
||||
entity_id: media_player.livingroomCC
|
||||
state: 'playing'
|
||||
type: time
|
||||
end: '{{ now() }}'
|
||||
duration:
|
||||
hours: 24
|
||||
|
||||
- platform: history_stats
|
||||
name: Landscaping Light time
|
||||
entity_id: group.landscaping
|
||||
state: 'on'
|
||||
type: time
|
||||
end: '{{ now() }}'
|
||||
duration:
|
||||
hours: 24
|
||||
|
||||
# - platform: rest
|
||||
# name: July 4th Countdown
|
||||
# resource: http://api.wolframalpha.com/v1/result?appid=JIUY8U-4V8KY45VT1&i=How%20many%20days%20until%204th%20July%202018
|
||||
# value_template: "{{ (value|replace(' days', '')) | int }}"
|
||||
# unit_of_measurement: Days
|
||||
# scan_interval: 43200```
|
||||
|
||||
group:
|
||||
tweet_stats:
|
||||
entities:
|
||||
- sensor.doorbell_presses
|
||||
- sensor.landscaping_light_time
|
||||
- sensor.hvac_time
|
||||
- sensor.speech_time
|
||||
|
||||
#############################################################
|
||||
|
||||
automation:
|
||||
- alias: 'New Twitter follower!'
|
||||
hide_entity: True
|
||||
trigger:
|
||||
- platform: event
|
||||
event_type: new_follower
|
||||
|
||||
condition:
|
||||
- condition: state
|
||||
entity_id: group.bed
|
||||
state: 'off'
|
||||
action:
|
||||
- service: media_player.play_media
|
||||
data_template:
|
||||
entity_id:
|
||||
- media_player.livingroomCC
|
||||
- media_player.bedroom_alarm_panel
|
||||
media_content_id: "https://raw.githubusercontent.com/CCOSTAN/Home-AssistantConfig/master/sounds/twitter-chirp.mp3"
|
||||
media_content_type: audio/mp4
|
||||
|
||||
- service: script.tweet_engine
|
||||
data_template:
|
||||
tweet: >-
|
||||
{% set handle = trigger.event.data.value1 %}
|
||||
{% set location = trigger.event.data.location %}
|
||||
{% set phrases = [
|
||||
"Thanks for the Follow " ~ handle ~ "! Chirp the Bird from " ~ location ~ "!!",
|
||||
"Hey " ~ handle ~ "! Thanks for the Follow from " ~ location ~ " !",
|
||||
"Sending a #Chirp to " ~ handle ~ " in " ~ location ~ "!",
|
||||
"New follower " ~ handle ~ " from " ~ location ~ ", I just sounded a chirp in the house.",
|
||||
"Boom! The " ~ location ~ " follow from " ~ handle ~ " makes me sound a chirp in the house.",
|
||||
"Wanna know who is super cool? "~ handle ~" IS!!! Thanks for making me CHIRP!",
|
||||
"If the AMP (http://amzn.to/2j18dlT) is on & I get a new follower like " ~ handle ~ ", I sound a chirp!"
|
||||
] %}
|
||||
{% set hashtags = [
|
||||
"#ThanksForTheFollow",
|
||||
"#FollowBack",
|
||||
"#ChirpTheHouse",
|
||||
"#FollowMe",
|
||||
"#MakingitChirp",
|
||||
"(http://www.vmwareinfo.com/2017/12/giving-house-twitter-account.html)",
|
||||
"(http://www.vmwareinfo.com/2017/11/building-digital-cuckoo-clock-with-home.html)"
|
||||
] %}
|
||||
{{ phrases|random ~ " " ~ hashtags|random }}
|
||||
|
||||
- alias: 'Closed Github Issue'
|
||||
hide_entity: True
|
||||
trigger:
|
||||
- platform: event
|
||||
event_type: closed_github
|
||||
|
||||
action:
|
||||
- service: script.tweet_engine
|
||||
data_template:
|
||||
tweet: >-
|
||||
{% set repo = trigger.event.data.repo %}
|
||||
{% set issue = trigger.event.data.issue %}
|
||||
{% set issueurl = trigger.event.data.issueurl %}
|
||||
{% set phrases = [
|
||||
"New Code Alert: " ~ issue ~ "(" ~ issueurl ~ "). Repo: (https://github.com/CCOSTAN/Home-AssistantConfig/commits/master) "
|
||||
] %}
|
||||
{% set hashtags = [
|
||||
"#Github",
|
||||
"#HomeAutomation",
|
||||
"#SmartHomeCode"
|
||||
] %}
|
||||
{{ phrases|random ~ " " ~ hashtags|random }}
|
||||
|
||||
|
||||
- alias: 'Random House stats'
|
||||
hide_entity: True
|
||||
trigger:
|
||||
- platform: time
|
||||
hours: '/3'
|
||||
minutes: 01
|
||||
seconds: 00
|
||||
condition:
|
||||
- condition: template
|
||||
value_template: >
|
||||
{%- if states.automation.random_house_stats.attributes.last_triggered -%}
|
||||
{{ (as_timestamp(now()) - as_timestamp(states.automation.random_house_stats.attributes.last_triggered)) > 10000 }}
|
||||
{%- else -%}
|
||||
true
|
||||
{%- endif -%}
|
||||
action:
|
||||
- delay: '0{{ range(0,2) | random | int }}:{{ range(10,59) | random | int }}:00'
|
||||
- service: script.tweet_engine
|
||||
data_template:
|
||||
tweet: >
|
||||
{{ [
|
||||
"The number of Doorbell presses yesterday was {{states.sensor.doorbell_presses.state}}",
|
||||
"The #Landscaping lights where on for about {{states.sensor.landscaping_light_time.attributes.value}} yesterday.",
|
||||
"I have spoken for about {{states.sensor.speech_time.attributes.value}}inutes in the last 24 hours.",
|
||||
"When you add it all up, I have spoken for about {{states.sensor.speech_time.attributes.value}}inutes in the last 24 hours!",
|
||||
"So far, I have prevented {{states.sensor.pihole_ads_blocked_today.state}} ads from hitting the network via Pi-hole! http://www.pi-hole.net",
|
||||
"Pi-hole (http://www.pi-hole.net) has serviced {{states.sensor.pihole_dns_queries_today.state}} DNS requests today! #PiZero",
|
||||
"{{states.sensor.doorbell_presses.state}} people came to the door today and pressed the bell.",
|
||||
"The #Docker Host has been running for {{states.sensor.since_last_boot_templated.state}} (http://www.vmwareinfo.com/2018/02/journey-to-docker.html)",
|
||||
"The #Docker Host for Home Assistant is using {{states.sensor.disk_use_percent_.state}}% of the hard drive currently. (http://www.vmwareinfo.com/2018/02/journey-to-docker.html)",
|
||||
"My Home Assistant Database is currently using {{states.sensor.database_sensor.state}} MBs. To get this #Stat for your HA, visit (https://github.com/robmarkcole/HASS-filesize-sensor)",
|
||||
"The {{states.media_player.living_room_ultra.attributes.friendly_name}} #Roku is playing #{{states.media_player.living_room_ultra.attributes.app_name}}.",
|
||||
"The {{states.media_player.upstairs_living_room.attributes.friendly_name}} #Roku is playing #{{states.media_player.upstairs_living_room.attributes.app_name}}. (http://amzn.to/2lYZEup)",
|
||||
"I am running Home Assistant version {{states.sensor.ha_installed_version.state}} (https://github.com/CCOSTAN/Home-AssistantConfig)",
|
||||
"{{states.sensor.doorbell_presses.state}} doorbell presses occurred in the last 24 hours.",
|
||||
"I keep the average humidity of the house at {{states.sensor.downstairs_thermostat_humidity.state}} percent. Outside is {{states.sensor.dark_sky_humidity.state}} #Nest (http://amzn.to/2BWNk5N)",
|
||||
"Outside is {{states.sensor.dark_sky_temperature.state}}. I keep the average temperature at {{states.sensor.downstairs_thermostat_temperature.state}}. #Weather (http://amzn.to/2BWNk5N)",
|
||||
"I know that it will be {{states.sensor.dark_sky_minutely_summary.state}} So I will adjust the Heating/Cooling, irrigation and lighting accordingly. #Nest #Rachio #Hue",
|
||||
"Average internet stats are Download: {{states.sensor.speedtest_download.state}} Mbit/s & Upload {{states.sensor.speedtest_upload.state}} Mbit/s.",
|
||||
"Todays Sleep Number is {{states.sensor.sleepnumber_carlo_stacey_sleepnumber.state}}. Wifi connected Bed FTW! #SleepStat (http://amzn.to/2D10BcQ)",
|
||||
"Our Sleep Number is {{states.sensor.sleepnumber_carlo_carlo_sleepnumber.state}}. Wifi connected Bed! #SleepStat (http://amzn.to/2D10BcQ)",
|
||||
"The current UV index is {{states.sensor.dark_sky_uv_index.state}} and the Moon is {{states.sensor.moon.state}}. #Space",
|
||||
"Home Assistant has been running for {{states.sensor.ha_uptime.state}}. (https://github.com/CCOSTAN/Home-AssistantConfig)",
|
||||
"My @getspectrum internet download speed is about {{states.sensor.speedtest_download.state}} Mbit/s and I am a #cordcutter. @TabloTV",
|
||||
"I am keeping track of the current #Tesla stock price. It is {{ states.sensor.tesla.state | round }} dollars. #Solar",
|
||||
"I am keeping track of the current #Bitcoin prices. It is {{ states.sensor.bitcoin.state | round }} dollars. #BTC",
|
||||
"There are {{states.sensor.bear_stone.state}} #Minecraft users online at the momemt. #KidStat",
|
||||
"Average Cloud Coverage: {{states.sensor.dark_sky_cloud_coverage.state}}%, Average Temp: {{states.sensor.dark_sky_temperature.state}}°F #Solar (http://www.vmwareinfo.com/2018/01/going-green-to-save-some-green-in-2018.html)"
|
||||
] | random + " #RandomStat"}}
|
20
config/packages/usps.yaml.disabled
Executable file
20
config/packages/usps.yaml.disabled
Executable file
@@ -0,0 +1,20 @@
|
||||
#-------------------------------------------
|
||||
# @CCOSTAN
|
||||
# Original Repo : https://github.com/CCOSTAN/Home-AssistantConfig
|
||||
#---Sensor Mail and Packages-----------------------------
|
||||
usps:
|
||||
username: !secret myusps_username
|
||||
password: !secret myusps_password
|
||||
|
||||
camera:
|
||||
- platform: usps
|
||||
scan_interval: 5
|
||||
|
||||
group:
|
||||
mail:
|
||||
name: Mailbox Information
|
||||
control: hidden
|
||||
entities:
|
||||
- sensor.usps_mail
|
||||
- sensor.usps_packages
|
||||
- camera.usps_mail
|
11
config/packages/weather_camera.yaml.disabled
Executable file
11
config/packages/weather_camera.yaml.disabled
Executable file
@@ -0,0 +1,11 @@
|
||||
#-------------------------------------------
|
||||
# Camera Related Packages
|
||||
# @CCOSTAN
|
||||
# Original Repo : https://github.com/CCOSTAN/Home-AssistantConfig
|
||||
|
||||
#---Sensor for Light-----------------------------
|
||||
camera:
|
||||
- platform: generic
|
||||
still_image_url: 'https://icons.wxug.com/data/weather-maps/radar/united-states/saint-petersburg-florida-region-current-radar.gif'
|
||||
# still_image_url: 'https://radblast.wunderground.com/cgi-bin/radar/WUNIDS_map?station=MCO&brand=wui&num=1&delay=15&type=TR0&frame=0&scale=1.000&noclutter=0&showstorms=0&mapx=400&mapy=240¢erx=400¢ery=240&transx=0&transy=0&showlabels=1&severe=0&rainsnow=0&lightning=0&smooth=0&rand=25183060&lat=0&lon=0&label=you'
|
||||
name: WU Doppler Weather
|
Reference in New Issue
Block a user