Moved more to packages
This commit is contained in:
@@ -26,11 +26,6 @@ logger:
|
|||||||
custom_components.evnex: debug
|
custom_components.evnex: debug
|
||||||
evnex: debug
|
evnex: debug
|
||||||
|
|
||||||
# mqtt broker
|
|
||||||
#mqtt:
|
|
||||||
# broker: !secret mqtt1_broker
|
|
||||||
# port: !secret mqtt1_port
|
|
||||||
|
|
||||||
device_tracker:
|
device_tracker:
|
||||||
- platform: bluetooth_le_tracker
|
- platform: bluetooth_le_tracker
|
||||||
|
|
||||||
@@ -44,18 +39,3 @@ input_boolean:
|
|||||||
away_occupied_routine:
|
away_occupied_routine:
|
||||||
name: Automation for Lights etc when away
|
name: Automation for Lights etc when away
|
||||||
icon: mdi:shield-lock
|
icon: mdi:shield-lock
|
||||||
|
|
||||||
rest_command:
|
|
||||||
chores1_request:
|
|
||||||
url: !secret grocy_api_uri_chore6
|
|
||||||
method: PUT
|
|
||||||
headers:
|
|
||||||
accept: "*/*"
|
|
||||||
GROCY-API-KEY: !secret grocy_api_key
|
|
||||||
content_type: "application/json"
|
|
||||||
payload: '{
|
|
||||||
"name" : "{{ name }}" ,
|
|
||||||
"next_execution_assigned_to_user_id" : "{{ assigned_to }}"
|
|
||||||
}'
|
|
||||||
# payload: '{"name" : "{{ name }}" , "next_estimated_execution_time" : "{{ next_time }}", "next_execution_assigned_to_user_id" : "{{ assigned_to }}" }'
|
|
||||||
verify_ssl: false
|
|
||||||
|
@@ -33,3 +33,23 @@ automation:
|
|||||||
data_template:
|
data_template:
|
||||||
entity_id: var.covid_yesterday_total
|
entity_id: var.covid_yesterday_total
|
||||||
value: "{{ states('sensor.new_zealand_coronavirus_confirmed') | float }}"
|
value: "{{ states('sensor.new_zealand_coronavirus_confirmed') | float }}"
|
||||||
|
|
||||||
|
sensor:
|
||||||
|
- platform: statistics
|
||||||
|
entity_id: sensor.coronavirus_totals_normalised
|
||||||
|
sampling_size: 200000
|
||||||
|
state_characteristic: mean
|
||||||
|
max_age:
|
||||||
|
days: 1
|
||||||
|
name: "Coronavirus Statistics"
|
||||||
|
- platform: template
|
||||||
|
sensors:
|
||||||
|
coronavirus_totals_normalised:
|
||||||
|
friendly_name: "NZ Coronavirus Totals (Normalised)"
|
||||||
|
value_template: >
|
||||||
|
{% set new_state = states('sensor.new_zealand_coronavirus_confirmed') | float %}
|
||||||
|
{% if new_state >= states('input_number.new_zealand_coronavirus_confirmed_previous_value') | float %}
|
||||||
|
{{ new_state }}
|
||||||
|
{% else %}
|
||||||
|
{{ states('input_number.new_zealand_coronavirus_confirmed_previous_value') | float }}
|
||||||
|
{% endif %}
|
||||||
|
7
packages/google_keep.yaml
Normal file
7
packages/google_keep.yaml
Normal file
@@ -0,0 +1,7 @@
|
|||||||
|
sensor:
|
||||||
|
- platform: google_keep
|
||||||
|
username: !secret google_keep.username
|
||||||
|
password: !secret google_keep.password
|
||||||
|
labels:
|
||||||
|
- "Home Assistant"
|
||||||
|
pinned: true
|
42
packages/grocy_api.yaml
Normal file
42
packages/grocy_api.yaml
Normal file
@@ -0,0 +1,42 @@
|
|||||||
|
rest_command:
|
||||||
|
chores1_request:
|
||||||
|
url: !secret grocy_api_uri_chore6
|
||||||
|
method: PUT
|
||||||
|
headers:
|
||||||
|
accept: "*/*"
|
||||||
|
GROCY-API-KEY: !secret grocy_api_key
|
||||||
|
content_type: "application/json"
|
||||||
|
payload: '{
|
||||||
|
"name" : "{{ name }}" ,
|
||||||
|
"next_execution_assigned_to_user_id" : "{{ assigned_to }}"
|
||||||
|
}'
|
||||||
|
# payload: '{"name" : "{{ name }}" , "next_estimated_execution_time" : "{{ next_time }}", "next_execution_assigned_to_user_id" : "{{ assigned_to }}" }'
|
||||||
|
verify_ssl: false
|
||||||
|
|
||||||
|
sensor:
|
||||||
|
- platform: rest
|
||||||
|
name: Dog Motel Cleaning
|
||||||
|
resource: !secret grocy_api_uri_chore3
|
||||||
|
method: GET
|
||||||
|
value_template: "{{ (((as_timestamp(value_json.next_estimated_execution_time))-as_timestamp(now())) | int /60/1440) | round(0) }}"
|
||||||
|
json_attributes:
|
||||||
|
- last_tracked
|
||||||
|
- estimated_execution_time
|
||||||
|
headers:
|
||||||
|
Accept: application/json
|
||||||
|
Content-Type: application/json
|
||||||
|
GROCY-API-KEY: !secret grocy_api_key
|
||||||
|
unit_of_measurement: "Days"
|
||||||
|
- platform: rest
|
||||||
|
name: Red Bin Out
|
||||||
|
resource: !secret grocy_api_uri_chore2
|
||||||
|
method: GET
|
||||||
|
value_template: "{{ (((as_timestamp(value_json.next_estimated_execution_time))-as_timestamp(now())) | int /60/1440) | round(0) }}"
|
||||||
|
json_attributes:
|
||||||
|
- last_tracked
|
||||||
|
- estimated_execution_time
|
||||||
|
headers:
|
||||||
|
Accept: application/json
|
||||||
|
Content-Type: application/json
|
||||||
|
GROCY-API-KEY: !secret grocy_api_key
|
||||||
|
unit_of_measurement: "Days"
|
19
packages/internet_traffic.yaml
Normal file
19
packages/internet_traffic.yaml
Normal file
@@ -0,0 +1,19 @@
|
|||||||
|
sensor:
|
||||||
|
- platform: template
|
||||||
|
sensors:
|
||||||
|
sensor_internet_downtraffic:
|
||||||
|
friendly_name: "Internet Download Traffic"
|
||||||
|
unit_of_measurement: "kB/s"
|
||||||
|
value_template: "{{ state_attr('binary_sensor.edgeos_interface_pppoe0', 'KBytes/ps (Received)') }}"
|
||||||
|
- platform: template
|
||||||
|
sensors:
|
||||||
|
sensor_internet_uptraffic:
|
||||||
|
friendly_name: "Internet Upload Traffic"
|
||||||
|
unit_of_measurement: "kB/s"
|
||||||
|
value_template: "{{ state_attr('binary_sensor.edgeos_interface_pppoe0', 'KBytes/ps (Sent)') }}"
|
||||||
|
- platform: template
|
||||||
|
sensors:
|
||||||
|
sensor_internet_totaltraffic:
|
||||||
|
friendly_name: "Internet Total Traffic"
|
||||||
|
unit_of_measurement: "kB/s"
|
||||||
|
value_template: "{{ state_attr('binary_sensor.edgeos_interface_pppoe0', 'KBytes/ps (Received)') |float + state_attr('binary_sensor.edgeos_interface_pppoe0', 'KBytes/ps (Sent)') | float }}"
|
20
packages/low_battery_device_quantity.yaml
Normal file
20
packages/low_battery_device_quantity.yaml
Normal file
@@ -0,0 +1,20 @@
|
|||||||
|
sensor:
|
||||||
|
- platform: template
|
||||||
|
sensors:
|
||||||
|
devices_with_low_battery:
|
||||||
|
friendly_name: "Devices with low battery"
|
||||||
|
unit_of_measurement: devices
|
||||||
|
value_template: >-
|
||||||
|
{{ states.sensor
|
||||||
|
| selectattr('attributes.device_class', 'eq', 'battery')
|
||||||
|
| map(attribute='state')
|
||||||
|
| reject('in', ['unknown', 'unavailable', 'Ok'])
|
||||||
|
| map('int', -1) | select('le', 97)
|
||||||
|
| list | count
|
||||||
|
}}
|
||||||
|
icon_template: >-
|
||||||
|
{% if is_state('sensor.devices_with_low_battery', '0') %}
|
||||||
|
mdi:check-circle
|
||||||
|
{% else %}
|
||||||
|
mdi:battery-alert
|
||||||
|
{% endif %}
|
7
packages/niwa_tides.yaml
Normal file
7
packages/niwa_tides.yaml
Normal file
@@ -0,0 +1,7 @@
|
|||||||
|
sensor:
|
||||||
|
- platform: niwa_tides
|
||||||
|
api_key: !secret niwa_tides_api_key
|
||||||
|
entity_id: "local_tides"
|
||||||
|
name: Local Tides
|
||||||
|
latitude: !secret latitude
|
||||||
|
longitude: !secret longitude
|
5
packages/tautulli.yaml
Normal file
5
packages/tautulli.yaml
Normal file
@@ -0,0 +1,5 @@
|
|||||||
|
sensor:
|
||||||
|
- platform: tautulli
|
||||||
|
api_key: !secret tautulli_api_key
|
||||||
|
host: !secret tautulli_api_host
|
||||||
|
port: !secret tautulli_api_port
|
7
packages/total_power_sum_template.yaml
Normal file
7
packages/total_power_sum_template.yaml
Normal file
@@ -0,0 +1,7 @@
|
|||||||
|
sensor:
|
||||||
|
- platform: template
|
||||||
|
sensors:
|
||||||
|
electricity_power_total:
|
||||||
|
friendly_name: "Electricity Power Total"
|
||||||
|
unit_of_measurement: "W"
|
||||||
|
value_template: "{{ states('sensor.tasmo_wemosd1_7280_powermon_1_energy_power_0') |float + states('sensor.tasmo_wemosd1_7280_powermon_1_energy_power_1') | float + states('sensor.tasmo_wemosd1_7280_powermon_1_energy_power_2') | float }}"
|
@@ -1,18 +0,0 @@
|
|||||||
- platform: statistics
|
|
||||||
entity_id: sensor.coronavirus_totals_normalised
|
|
||||||
sampling_size: 200000
|
|
||||||
state_characteristic: mean
|
|
||||||
max_age:
|
|
||||||
days: 1
|
|
||||||
name: "Coronavirus Statistics"
|
|
||||||
- platform: template
|
|
||||||
sensors:
|
|
||||||
coronavirus_totals_normalised:
|
|
||||||
friendly_name: "NZ Coronavirus Totals (Normalised)"
|
|
||||||
value_template: >
|
|
||||||
{% set new_state = states('sensor.new_zealand_coronavirus_confirmed') | float %}
|
|
||||||
{% if new_state >= states('input_number.new_zealand_coronavirus_confirmed_previous_value') | float %}
|
|
||||||
{{ new_state }}
|
|
||||||
{% else %}
|
|
||||||
{{ states('input_number.new_zealand_coronavirus_confirmed_previous_value') | float }}
|
|
||||||
{% endif %}
|
|
@@ -1,6 +0,0 @@
|
|||||||
- platform: google_keep
|
|
||||||
username: !secret google_keep.username
|
|
||||||
password: !secret google_keep.password
|
|
||||||
labels:
|
|
||||||
- "Home Assistant"
|
|
||||||
pinned: true
|
|
@@ -1,26 +0,0 @@
|
|||||||
- platform: rest
|
|
||||||
name: Dog Motel Cleaning
|
|
||||||
resource: !secret grocy_api_uri_chore3
|
|
||||||
method: GET
|
|
||||||
value_template: "{{ (((as_timestamp(value_json.next_estimated_execution_time))-as_timestamp(now())) | int /60/1440) | round(0) }}"
|
|
||||||
json_attributes:
|
|
||||||
- last_tracked
|
|
||||||
- estimated_execution_time
|
|
||||||
headers:
|
|
||||||
Accept: application/json
|
|
||||||
Content-Type: application/json
|
|
||||||
GROCY-API-KEY: !secret grocy_api_key
|
|
||||||
unit_of_measurement: "Days"
|
|
||||||
- platform: rest
|
|
||||||
name: Red Bin Out
|
|
||||||
resource: !secret grocy_api_uri_chore2
|
|
||||||
method: GET
|
|
||||||
value_template: "{{ (((as_timestamp(value_json.next_estimated_execution_time))-as_timestamp(now())) | int /60/1440) | round(0) }}"
|
|
||||||
json_attributes:
|
|
||||||
- last_tracked
|
|
||||||
- estimated_execution_time
|
|
||||||
headers:
|
|
||||||
Accept: application/json
|
|
||||||
Content-Type: application/json
|
|
||||||
GROCY-API-KEY: !secret grocy_api_key
|
|
||||||
unit_of_measurement: "Days"
|
|
@@ -1,20 +0,0 @@
|
|||||||
- platform: template
|
|
||||||
sensors:
|
|
||||||
sensor_internet_downtraffic:
|
|
||||||
friendly_name: "Internet Download Traffic"
|
|
||||||
unit_of_measurement: "kB/s"
|
|
||||||
value_template: "{{ state_attr('binary_sensor.edgeos_interface_pppoe0', 'KBytes/ps (Received)') }}"
|
|
||||||
|
|
||||||
- platform: template
|
|
||||||
sensors:
|
|
||||||
sensor_internet_uptraffic:
|
|
||||||
friendly_name: "Internet Upload Traffic"
|
|
||||||
unit_of_measurement: "kB/s"
|
|
||||||
value_template: "{{ state_attr('binary_sensor.edgeos_interface_pppoe0', 'KBytes/ps (Sent)') }}"
|
|
||||||
|
|
||||||
- platform: template
|
|
||||||
sensors:
|
|
||||||
sensor_internet_totaltraffic:
|
|
||||||
friendly_name: "Internet Total Traffic"
|
|
||||||
unit_of_measurement: "kB/s"
|
|
||||||
value_template: "{{ state_attr('binary_sensor.edgeos_interface_pppoe0', 'KBytes/ps (Received)') |float + state_attr('binary_sensor.edgeos_interface_pppoe0', 'KBytes/ps (Sent)') | float }}"
|
|
@@ -1,19 +0,0 @@
|
|||||||
- platform: template
|
|
||||||
sensors:
|
|
||||||
devices_with_low_battery:
|
|
||||||
friendly_name: "Devices with low battery"
|
|
||||||
unit_of_measurement: devices
|
|
||||||
value_template: >-
|
|
||||||
{{ states.sensor
|
|
||||||
| selectattr('attributes.device_class', 'eq', 'battery')
|
|
||||||
| map(attribute='state')
|
|
||||||
| reject('in', ['unknown', 'unavailable', 'Ok'])
|
|
||||||
| map('int', -1) | select('le', 97)
|
|
||||||
| list | count
|
|
||||||
}}
|
|
||||||
icon_template: >-
|
|
||||||
{% if is_state('sensor.devices_with_low_battery', '0') %}
|
|
||||||
mdi:check-circle
|
|
||||||
{% else %}
|
|
||||||
mdi:battery-alert
|
|
||||||
{% endif %}
|
|
@@ -1,6 +0,0 @@
|
|||||||
- platform: template
|
|
||||||
sensors:
|
|
||||||
electricity_power_total:
|
|
||||||
friendly_name: "Electricity Power Total"
|
|
||||||
unit_of_measurement: "W"
|
|
||||||
value_template: "{{ states('sensor.tasmo_wemosd1_7280_powermon_1_energy_power_0') |float + states('sensor.tasmo_wemosd1_7280_powermon_1_energy_power_1') | float + states('sensor.tasmo_wemosd1_7280_powermon_1_energy_power_2') | float }}"
|
|
@@ -1,4 +0,0 @@
|
|||||||
- platform: tautulli
|
|
||||||
api_key: !secret tautulli_api_key
|
|
||||||
host: !secret tautulli_api_host
|
|
||||||
port: !secret tautulli_api_port
|
|
@@ -1,6 +0,0 @@
|
|||||||
- platform: niwa_tides
|
|
||||||
api_key: !secret niwa_tides_api_key
|
|
||||||
entity_id: "local_tides"
|
|
||||||
name: Local Tides
|
|
||||||
latitude: !secret latitude
|
|
||||||
longitude: !secret longitude
|
|
Reference in New Issue
Block a user