Refactor code structure for improved readability and maintainability

This commit is contained in:
CeeWeasel
2026-01-19 14:47:59 -05:00
parent 6550521520
commit 97a0e678c0
84 changed files with 1614 additions and 1177 deletions
+2 -2
View File
@@ -25,10 +25,10 @@ condition:
entity_id: media_player.front_room_hub entity_id: media_player.front_room_hub
state: "playing" state: "playing"
- condition: state - condition: state
entity_id: media_player.master_bedroom_clock entity_id: media_player.girls_room_clock
state: "playing" state: "playing"
- condition: state - condition: state
entity_id: media_player.girls_room_hub entity_id: media_player.bedroom_hub
state: "playing" state: "playing"
- condition: state - condition: state
entity_id: media_player.bathroom_mini entity_id: media_player.bathroom_mini
+6 -2
View File
@@ -7,12 +7,16 @@ trigger:
- platform: state - platform: state
entity_id: binary_sensor.bed_presence_c175a4_bed_occupied_either entity_id: binary_sensor.bed_presence_c175a4_bed_occupied_either
to: "on" to: "on"
# Bed in master bedroom is occupied
- platform: state
entity_id: input_boolean.master_bed_occupied
to: "on"
# Radio playing # Radio playing
- platform: state - platform: state
entity_id: media_player.master_bedroom_clock entity_id: media_player.bedroom_hub
to: "playing" to: "playing"
- platform: state - platform: state
entity_id: media_player.master_bedroom_clock entity_id: media_player.bedroom_hub
to: "idle" to: "idle"
# Light on # Light on
- platform: state - platform: state
+4
View File
@@ -13,6 +13,10 @@ trigger:
entity_id: binary_sensor.bed_presence_c175a4_bed_occupied_right entity_id: binary_sensor.bed_presence_c175a4_bed_occupied_right
to: "off" to: "off"
for: "00:05:00" for: "00:05:00"
# Bed in master bedroom is occupied
- platform: state
entity_id: input_boolean.master_bed_occupied
to: "on"
- platform: state - platform: state
entity_id: entity_id:
- binary_sensor.master_bedroom_door_contact - binary_sensor.master_bedroom_door_contact
@@ -10,6 +10,10 @@ trigger:
- platform: state - platform: state
entity_id: binary_sensor.bed_presence_c175a4_bed_occupied_right entity_id: binary_sensor.bed_presence_c175a4_bed_occupied_right
to: "on" to: "on"
# Bed in master bedroom is occupied
- platform: state
entity_id: input_boolean.master_bed_occupied
to: "on"
condition: condition:
- condition: state - condition: state
+2 -2
View File
@@ -28,7 +28,7 @@ action:
- action: media_player.volume_set - action: media_player.volume_set
data: data:
#entity_id: media_player.ma_home_assistant_voice_097b44_media_player #entity_id: media_player.ma_home_assistant_voice_097b44_media_player
entity_id: media_player.ma_master_bedroom_clock entity_id: media_player.ma_bedroom_hub
volume_level: 0.90 volume_level: 0.90
- action: input_select.select_option - action: input_select.select_option
@@ -40,7 +40,7 @@ action:
- action: music_assistant.play_media - action: music_assistant.play_media
target: target:
#entity_id: media_player.ma_home_assistant_voice_097b44_media_player #entity_id: media_player.ma_home_assistant_voice_097b44_media_player
entity_id: media_player.ma_master_bedroom_clock entity_id: media_player.ma_bedroom_hub
data: data:
media_type: playlist media_type: playlist
#media_id: library://playlist/7 #media_id: library://playlist/7
+2 -2
View File
@@ -8,10 +8,10 @@ trigger:
to: "on" to: "on"
# Radio playing # Radio playing
- platform: state - platform: state
entity_id: media_player.master_bedroom_clock entity_id: media_player.bedroom_hub
to: "playing" to: "playing"
- platform: state - platform: state
entity_id: media_player.master_bedroom_clock entity_id: media_player.bedroom_hub
to: "idle" to: "idle"
# Light on # Light on
- platform: state - platform: state
+2 -2
View File
@@ -29,8 +29,8 @@ action:
- media_player.bathroom_mini - media_player.bathroom_mini
- media_player.front_room_hub - media_player.front_room_hub
- media_player.kitchen - media_player.kitchen
- media_player.girls_room_hub - media_player.girls_room_clock
- media_player.master_bedroom_clock - media_player.bedroom_hub
volume_level: 0.7 volume_level: 0.7
- delay: "00:00:03" - delay: "00:00:03"
- action: tts.speak - action: tts.speak
@@ -2,7 +2,7 @@ alias: Continue Girls Room Noise
id: automation_continue_girls_room_noise id: automation_continue_girls_room_noise
trigger: trigger:
- platform: state - platform: state
entity_id: media_player.girls_room_hub entity_id: media_player.girls_room_clock
from: "playing" from: "playing"
condition: condition:
- condition: state - condition: state
+7 -7
View File
@@ -35,11 +35,11 @@ condition:
attribute: source attribute: source
state: "YouTube" state: "YouTube"
- condition: state - condition: state
entity_id: media_player.master_bedroom_clock entity_id: media_player.bedroom_hub
attribute: source attribute: source
state: "PBS Kids" state: "PBS Kids"
- condition: state - condition: state
entity_id: media_player.master_bedroom_clock entity_id: media_player.bedroom_hub
attribute: source attribute: source
state: "YouTube" state: "YouTube"
@@ -94,23 +94,23 @@ action:
- choose: - choose:
- conditions: - conditions:
- condition: state - condition: state
entity_id: media_player.master_bedroom_clock entity_id: media_player.bedroom_hub
state: "playing" state: "playing"
- condition: or - condition: or
conditions: conditions:
- condition: state - condition: state
entity_id: media_player.master_bedroom_clock entity_id: media_player.bedroom_hub
attribute: source attribute: source
state: "YouTube" state: "YouTube"
- condition: state - condition: state
entity_id: media_player.master_bedroom_clock entity_id: media_player.bedroom_hub
attribute: source attribute: source
state: "PBS Kids" state: "PBS Kids"
sequence: sequence:
- action: media_player.select_source - action: media_player.select_source
data: data:
entity_id: media_player.master_bedroom_clock entity_id: media_player.bedroom_hub
source: Home source: Home
- action: media_player.turn_off - action: media_player.turn_off
data: data:
entity_id: media_player.master_bedroom_clock entity_id: media_player.bedroom_hub
@@ -1,33 +0,0 @@
alias: "Computer Area Occupied"
id: automation_computer_area_occupied
mode: restart
trigger:
- platform: state
entity_id:
- binary_sensor.computer_area_occupied
to: "on"
condition:
# Computer area was not already occupied or computer area light is off while not set to manual or off
- condition: or
conditions:
- condition: state
entity_id: input_boolean.computer_area_occupied
state: "off"
- condition: and
conditions:
- condition: state
entity_id: light.computer_area_hue
state: "off"
- condition: not
conditions:
- condition: state
entity_id: input_select.computer_area_mode
state: "Off"
- condition: state
entity_id: input_select.computer_area_mode
state: "Manual"
action:
- action: input_boolean.turn_on
entity_id: input_boolean.computer_area_occupied
@@ -12,7 +12,7 @@ action:
target: target:
entity_id: tts.google_translate_en_com entity_id: tts.google_translate_en_com
data: data:
media_player_entity_id: media_player.front_room_hub, media_player.bathroom_mini, media_player.kitchen, media_player.master_bedroom_clock media_player_entity_id: media_player.front_room_hub, media_player.bathroom_mini, media_player.kitchen, media_player.bedroom_hub
message: Attention! A water leak has been detected on the furnace room floor! message: Attention! A water leak has been detected on the furnace room floor!
- action: notify.mobile_app_pixel_7 - action: notify.mobile_app_pixel_7
@@ -31,27 +31,27 @@ action:
condition: and condition: and
conditions: conditions:
- condition: state - condition: state
entity_id: media_player.ma_girls_room_hub entity_id: media_player.ma_girls_room_clock
state: "playing" state: "playing"
- action: media_player.volume_set - action: media_player.volume_set
data: data:
volume_level: 0.4 volume_level: 0.4
target: target:
entity_id: media_player.ma_girls_room_hub entity_id: media_player.ma_girls_room_clock
#- action: script.goodnight_kids_youtube_music #- action: script.goodnight_kids_youtube_music
- action: media_player.shuffle_set - action: media_player.shuffle_set
data: data:
shuffle: false shuffle: false
target: target:
entity_id: media_player.ma_girls_room_hub entity_id: media_player.ma_girls_room_clock
- action: media_player.repeat_set - action: media_player.repeat_set
data: data:
repeat: all repeat: all
target: target:
entity_id: media_player.ma_girls_room_hub entity_id: media_player.ma_girls_room_clock
- action: music_assistant.play_media - action: music_assistant.play_media
data: data:
@@ -59,4 +59,4 @@ action:
media_type: playlist media_type: playlist
enqueue: replace enqueue: replace
target: target:
entity_id: media_player.ma_girls_room_hub entity_id: media_player.ma_girls_room_clock
@@ -89,7 +89,7 @@ action:
sequence: sequence:
- action: light.turn_on - action: light.turn_on
target: target:
entity_id: light.girls_room_fan_light_switch_light entity_id: light.girls_room_hue
- alias: "If the room is set to auto, the lights are on, and the automatic profile is set to Nightlight, change to the Automatic Light Profile scene with a short transition" - alias: "If the room is set to auto, the lights are on, and the automatic profile is set to Nightlight, change to the Automatic Light Profile scene with a short transition"
conditions: conditions:
@@ -99,7 +99,7 @@ action:
state: Auto state: Auto
- alias: "Lights are on" - alias: "Lights are on"
condition: state condition: state
entity_id: light.girls_room_fan_light_switch_light entity_id: light.girls_room_hue
state: "on" state: "on"
- alias: "Automatic light profile set to Nightlight" - alias: "Automatic light profile set to Nightlight"
condition: state condition: state
@@ -120,7 +120,7 @@ action:
state: Auto state: Auto
- alias: "Lights are on" - alias: "Lights are on"
condition: state condition: state
entity_id: light.girls_room_fan_light_switch_light entity_id: light.girls_room_hue
state: "on" state: "on"
sequence: sequence:
- action: scene.turn_on - action: scene.turn_on
@@ -137,7 +137,7 @@ action:
state: Auto state: Auto
- alias: "Lights are off" - alias: "Lights are off"
condition: state condition: state
entity_id: light.girls_room_fan_light_switch_light entity_id: light.girls_room_hue
state: "off" state: "off"
sequence: sequence:
- action: scene.turn_on - action: scene.turn_on
@@ -148,7 +148,7 @@ action:
conditions: conditions:
- alias: "Room not manual or auto and lights are on" - alias: "Room not manual or auto and lights are on"
condition: state condition: state
entity_id: light.girls_room_fan_light_switch_light entity_id: light.girls_room_hue
state: "on" state: "on"
- alias: "Room set to Nightlight" - alias: "Room set to Nightlight"
condition: state condition: state
@@ -165,7 +165,7 @@ action:
conditions: conditions:
- alias: "Room not manual or auto and lights are on" - alias: "Room not manual or auto and lights are on"
condition: state condition: state
entity_id: light.girls_room_fan_light_switch_light entity_id: light.girls_room_hue
state: "on" state: "on"
sequence: sequence:
- action: scene.turn_on - action: scene.turn_on
@@ -178,7 +178,7 @@ action:
conditions: conditions:
- alias: "Room not manual or auto and lights are off" - alias: "Room not manual or auto and lights are off"
condition: state condition: state
entity_id: light.girls_room_fan_light_switch_light entity_id: light.girls_room_hue
state: "off" state: "off"
sequence: sequence:
- action: scene.turn_on - action: scene.turn_on
@@ -8,4 +8,4 @@ trigger:
action: action:
- action: media_player.turn_off - action: media_player.turn_off
entity_id: media_player.ma_girls_room_hub entity_id: media_player.ma_girls_room_clock
@@ -7,7 +7,7 @@ trigger:
to: "on" to: "on"
- platform: state - platform: state
entity_id: media_player.ma_girls_room_hub entity_id: media_player.ma_girls_room_clock
to: "idle" to: "idle"
for: 00:00:05 for: 00:00:05
@@ -22,16 +22,16 @@ action:
- choose: - choose:
- conditions: - conditions:
- condition: state - condition: state
entity_id: media_player.ma_girls_room_hub entity_id: media_player.ma_girls_room_clock
state: "playing" state: "playing"
sequence: sequence:
- action: media_player.media_stop - action: media_player.media_stop
target: target:
entity_id: media_player.ma_girls_room_hub entity_id: media_player.ma_girls_room_clock
- action: script.search_and_play_playlist - action: script.search_and_play_playlist
data: data:
speaker: media_player.ma_girls_room_hub speaker: media_player.ma_girls_room_clock
search_term: Clever Kids Goodnight Songs search_term: Clever Kids Goodnight Songs
volume: 0.25 volume: 0.25
repeat: all repeat: all
@@ -10,4 +10,4 @@ action:
- action: media_player.turn_off - action: media_player.turn_off
data: {} data: {}
target: target:
entity_id: media_player.ma_home_assistant_voice_097b44_media_player entity_id: media_player.ma_bedroom_hub
@@ -9,8 +9,8 @@ trigger:
action: action:
- action: script.search_and_play_playlist - action: script.search_and_play_playlist
data: data:
speaker: media_player.ma_master_bedroom_clock speaker: media_player.ma_bedroom_hub
search_term: CleverThunderstorm search_term: CleverThunderstorm
volume: 0.25 volume: 0.35
repeat: all repeat: all
shuffle: false shuffle: false
@@ -7,7 +7,7 @@ max_exceeded: silent
variables: variables:
# Map scanner device ID to media player entity ID # Map scanner device ID to media player entity ID
sources: sources:
299e280bcc3579ca9b3ef714677dbf9b: girls_room_hub 299e280bcc3579ca9b3ef714677dbf9b: girls_room_clock
75060fd1afdd90be: upstairs_speakers 75060fd1afdd90be: upstairs_speakers
# Map tag ID to content # Map tag ID to content
tags: tags:
@@ -8,7 +8,7 @@ max_exceeded: silent
variables: variables:
# Map scanner device ID to media player entity ID # Map scanner device ID to media player entity ID
sources: sources:
299e280bcc3579ca9b3ef714677dbf9b: girls_room_hub 299e280bcc3579ca9b3ef714677dbf9b: girls_room_clock
75060fd1afdd90be: front_room_hub 75060fd1afdd90be: front_room_hub
# Map tag ID to content # Map tag ID to content
tags: tags:
@@ -7,7 +7,7 @@ max_exceeded: silent
variables: variables:
# Map scanner device ID to media player entity ID # Map scanner device ID to media player entity ID
devices: devices:
299e280bcc3579ca9b3ef714677dbf9b: media_player.girls_room_hub 299e280bcc3579ca9b3ef714677dbf9b: media_player.girls_room_clock
# Map tag ID to content # Map tag ID to content
tags: tags:
@@ -0,0 +1,442 @@
blueprint:
name: Party Lights
author: AntonH
homeassistant:
min_version: 2024.10.0
description: '**Version 3.2**
Lights go to party mode (color loops or fade-in-and-out)
⚠️ **NOTE:** ⚠️
*This automation is triggered by the status of a switch or an input_boolean entity.*
*You can create this input_boolean by going to Settings > Devices & services >
Helpers*
*There you click on ''Create helper and choose ''Toggle''.*
'
source_url: https://gist.github.com/Twanne/fe33ab8466f9a4e94b3f8e21f745a377
domain: automation
input:
party_mode_trigger:
name: Party mode trigger
description: "The trigger you want to use to turn the party mode on.\nThe automation
will keep running until this is turned off.\nSupported entity types:\n -
input_boolean\n - switch\n"
default: []
selector:
entity:
filter:
- domain:
- input_boolean
- switch
reorder: false
multiple: false
target_lights:
name: Target lights
description: Which lights do you want to control?
selector:
entity:
multiple: true
filter:
- domain:
- light
reorder: false
input_sync_lights:
name: Synchronize lights
description: 'If more than 1 target light is selected, choose if they will all
change to the same state or if they each get their own random values.
`️ Light groups will be seen an a single entity.`
'
default: true
selector:
boolean: {}
time_between_changes:
name: Time between changes
description: Change the lights setting after this duration
default:
hours: 0
minutes: 0
seconds: 0
milliseconds: 0
selector:
duration:
enable_millisecond: true
transition_time:
name: Transition time
description: 'The time it takes for the light to transition to the assigned
value when it''s triggered.
`⚠️ This value should not be greater than the time between changes!`
'
default: 0
selector:
number:
min: 0.0
max: 300.0
step: 1.0
unit_of_measurement: s
mode: slider
color_mode:
name: Color mode
description: "Select how the lights need to change\n \n 1. ⬛ **NO COLOR CHANGE:**\n
\ Don't change colors.\n 2. \U0001F500 **RANDOM COLOR MODE:**\n Change all
RGB values randomly.\n 3. \U0001F308 **SATURATED COLOR MODE**\n Random,
but deeply saturated, colors only.\n 4. \U0001F384 **CHRISTMAS COLORS:**\n
\ Change only between Christmas colors.\n 5. \U0001F6A8 **POLICE LIGHTS**\n
\ Change between red and blue.\n `⚠️ Lights will be synchronized!`\n 6.
\U0001F7E5 **REDS ONLY MODE:**\n Change only red value randomly.\n 7. \U0001F7E9
**GREENS ONLY MODE:**\n Change only green value randomly.\n 8. \U0001F7E6
**BLUES ONLY MODE:**\n Change only blue value randomly.\n 9. \U0001F7E6
**TEALS ONLY MODE:**\n Change only teal shades randomly.\n 10. \U0001F338
**PINKS ONLY MODE:**\n Change only pink shades randomly.\n 11. \U0001F7E8
**YELLOWS ONLY MODE:**\n Change only yellow shades randomly.\n"
default: no_color_change
selector:
select:
mode: dropdown
options:
- label: NO COLOR CHANGE
value: no_color_change
- label: RANDOM COLOR MODE
value: random
- label: SATURATED COLOR MODE
value: deep
- label: CHRISTMAS COLORS
value: christmas
- label: POLICE LIGHTS
value: police
- label: REDS ONLY MODE
value: red
- label: GREENS ONLY MODE
value: green
- label: BLUES ONLY MODE
value: blue
- label: TEALS ONLY MODE
value: teal
- label: PINKS ONLY MODE
value: pink
- label: YELLOWS ONLY MODE
value: yellow
multiple: false
custom_value: false
sort: false
brightness_mode:
name: Brightness mode
description: "Select how the lights need to change\n 1. **RANDOM BRIGHTNESS:**\n
\ Change the brightness randomly within a set range\n \n 2. **FIXED BRIGHTNESS:**\n
\ Keep the light at a user defined brightness\n"
default: random
selector:
select:
mode: dropdown
options:
- label: RANDOM BRIGHTNESS
value: random
- label: FIXED BRIGHTNESS
value: fixed
multiple: false
custom_value: false
sort: false
random_brightness_section:
name: Settings for RANDOM BRIGHTNESS
icon: mdi:brightness-auto
collapsed: true
input:
min_brightness_pct:
name: Minimum brightness (RANDOM BRIGHTNESS MODE)
description: Don't set the brightness of the light below this value
default: 0
selector:
number:
min: 0.0
max: 100.0
step: 1.0
mode: slider
unit_of_measurement: '%'
max_brightness_pct:
name: Maximum brightness (RANDOM BRIGHTNESS MODE)
description: Don't set the brightness of the light above this value
default: 100
selector:
number:
min: 0.0
max: 100.0
step: 1.0
mode: slider
unit_of_measurement: '%'
fixed_brightness_section:
name: Settings for FIXED BRIGHTNESS
icon: mdi:brightness-percent
collapsed: true
input:
fixed_brightness_pct:
name: Brightness (FIXED BRIGHTNESS MODE)
description: Keep the light at this percentage (color changes might affect
this somewhat)
default: 0
selector:
number:
min: 0.0
max: 100.0
step: 1.0
mode: slider
unit_of_measurement: '%'
light_effects_section:
name: Light Effects
icon: mdi:creation-outline
collapsed: true
input:
light_effect:
name: Effects (All modes)
description: 'Which light effect do you want to run?
`️ Recommended to set the time between changes long enough for the effects
to loop at least once.`
'
default: ''
selector:
text:
multiple: false
multiline: false
turn_off_settings_section:
name: Turn off settings
icon: mdi:cog-stop-outline
collapsed: true
input:
turn_off_delay:
name: Turn off delay
description: 'The time to wait before the automation is turned off and the
After Party State becomes active.
'
default:
hours: 0
minutes: 0
seconds: 0
selector:
duration: {}
after_party_state:
name: After party state
description: "What state should the lights have when the party mode is turned
off.\n \n 1. **NO CHANGE:**\n Keep the lights in the state they are
at the end of the party.\n 2. **TURN OFF:**\n Turn the lights off.\n
\ 3. **RETURN TO PREVIOUS STATE:**\n Return the lights to the state they
were before the party began.\n 4. **USER DEFINED SCENE:**\n Activate
a scene that determines the state of the lights after the party.\n 5.
**SCENE THEN OFF**\n Set the lights to a specific setting by activating
the user defined scene, then turn them off.\n"
default: return_to_previous
selector:
select:
mode: dropdown
options:
- label: NO CHANGE
value: no_change
- label: LIGHTS OFF
value: lights_off
- label: RETURN TO PREVIOUS STATE
value: return_to_previous
- label: USER DEFINED SCENE
value: user_defined_scene
- label: SCENE THEN OFF
value: scene_then_off
multiple: false
custom_value: false
sort: false
after_party_scene:
name: After party scene
description: 'User defined scene that can be activated after the party mode
is turned off.
'
default: []
selector:
entity:
filter:
- domain:
- scene
reorder: false
multiple: false
mode: restart
variables:
party_mode_trigger: !input party_mode_trigger
target_lights: !input target_lights
time_between_changes: !input time_between_changes
transition_time: !input transition_time
color_mode: !input color_mode
brightness_mode: !input brightness_mode
min_brightness_pct: !input min_brightness_pct
max_brightness_pct: !input max_brightness_pct
fixed_brightness_pct: !input fixed_brightness_pct
light_effect: !input light_effect
after_party_state: !input after_party_state
after_party_scene: !input after_party_scene
turn_off_delay: !input turn_off_delay
input_sync_lights: !input input_sync_lights
sync_lights: '{{ true if color_mode == "police" else input_sync_lights }}
'
triggers:
- trigger: state
entity_id: !input party_mode_trigger
to: 'on'
actions:
- action: scene.create
metadata: {}
data:
scene_id: before_state
snapshot_entities: '{{ target_lights }}'
- repeat:
sequence:
- choose:
- conditions: '{{ sync_lights is true }}'
sequence:
- variables:
brightness_value: "{% if brightness_mode == \"random\" %}\n {{ range(min_brightness_pct,
max_brightness_pct) | random }}\n{% else %}\n {{ fixed_brightness_pct
}}\n{% endif %}\n"
rgb_value: "{% if color_mode == \"random\" %}\n {{ range(256) | random,
range(256) | random, range(256) | random }}\n{% elif color_mode == \"deep\"
%}\n {% set r = range(256) |random %}\n {% set g = range(256) |random
%}\n {% set b = range(256) |random %}\n {# check if all values aren't
too high. This will mute the colors as they will go towards white. #}\n
\ {% if ( r >= 200 and g >= 200 and b >= 200) %}\n {% set rgb_changer
= range(3) | random %}\n \n {% if rgb_changer == 0 %}\n {{
(r - 100), g, b }}\n {% elif rgb_changer == 1 %}\n {{ r, (g
- 100), b }}\n {% elif rgb_changer == 2 %}\n {{ r, g, (b - 100)
}}\n {% endif %} \n \n {# check if all values aren't too close
together. This will mute the colors because they will form a grey color.
#}\n {% elif ( (r - g)|abs <= 100 and (g - b)|abs <= 100 and (b - r)|abs
<= 100 ) %}\n {% set rgb_changer = range(3) | random %}\n {%
if rgb_changer == 0 %}\n {{ (r / 2)|int , g, b }}\n {% elif
rgb_changer == 1 %}\n {{ r, (g / 2)|int, b }}\n {% elif rgb_changer
== 2 %}\n {{ r, g, (b / 2)|int }}\n {% endif %}\n {% else %}\n
\ {{ r, g, b }}\n {% endif %}\n{% elif color_mode == \"christmas\"
%} \n {% macro random_rgb_component(max) %}\n {{ range(256) | random
}}\n {% endmacro %}\n {% macro get_color(color_key) %}\n {% if
color_key == 1 %}\n [{{ random_rgb_component(256) }}, 0, 0]\n {%
elif color_key == 2 %}\n [0, {{ random_rgb_component(256) }}, 0]\n
\ {% elif color_key == 3 %}\n [0, 0, {{ random_rgb_component(256)
}}]\n {% elif color_key == 4 %}\n [255, 255, {{ random_rgb_component(50)
}}]\n {% endif %}\n {% endmacro %}\n {% set color_key = range(1,
5) | random %}\n {% set random_color = get_color(color_key) %}\n {{
random_color }} \n{% elif color_mode == \"police\" %}\n {% if state_attr(
target_lights[0], 'rgb_color') | string == '(255, 0, 0)' %}\n [ 0,
0, 255 ]\n {% else %}\n [ 255, 0, 0 ]\n {% endif %}\n{% elif color_mode
== \"red\" %}\n {{ range(256) | random, 0, 0 }}\n{% elif color_mode
== \"green\" %}\n {{ 0, range(256) | random, 0 }}\n{% elif color_mode
== \"blue\" %}\n {{ 0, 0, range(256) | random }}\n{% elif color_mode
== \"teal\" %}\n {{ range(256) | random, 255, 255 }}\n{% elif color_mode
== \"pink\" %}\n {{ 255, range(256) | random, 255 }}\n{% elif color_mode
== \"yellow\" %}\n {{ 255, 255, range(256) | random }}\n{% else %}\n
\ {{ 255, 255, 255 }}\n{% endif %}\n"
- action: light.turn_on
data: "{% if light_effect == \"\" %}\n {% if color_mode == \"no_color_change\"
%}\n {{ { \"transition\": transition_time, \"brightness_pct\": brightness_value
} }}\n {% else %}\n {{ { \"transition\": transition_time, \"brightness_pct\":
brightness_value, \"rgb_color\": rgb_value } }}\n {% endif %}\n{% else
%}\n {% if color_mode == \"no_color_change\" %}\n {{ { \"transition\":
transition_time, \"brightness_pct\": brightness_value, \"effect\": light_effect
\ } }}\n {% else %}\n {{ { \"transition\": transition_time, \"brightness_pct\":
brightness_value, \"rgb_color\": rgb_value, \"effect\": light_effect }
}}\n {% endif %}\n{% endif %}\n"
target:
entity_id: '{{ target_lights }}'
- conditions: '{{ sync_lights is false }}'
sequence:
- repeat:
for_each: '{{ target_lights }}'
sequence:
- variables:
brightness_value: "{% if brightness_mode == \"random\" %}\n {{ range(min_brightness_pct,
max_brightness_pct) | random }}\n{% else %}\n {{ fixed_brightness_pct
}}\n{% endif %}\n"
rgb_value: "{% if color_mode == \"random\" %}\n {{ range(256) | random,
range(256) | random, range(256) | random }}\n{% elif color_mode
== \"deep\" %}\n {% set r = range(256) |random %}\n {% set g =
range(256) |random %}\n {% set b = range(256) |random %}\n {#
check if all values aren't too high. This will mute the colors as
they will go towards white. #}\n {% if ( r >= 200 and g >= 200
and b >= 200) %}\n {% set rgb_changer = range(3) | random %}\n
\ \n {% if rgb_changer == 0 %}\n {{ (r - 100), g, b }}\n
\ {% elif rgb_changer == 1 %}\n {{ r, (g - 100), b }}\n {%
elif rgb_changer == 2 %}\n {{ r, g, (b - 100) }}\n {% endif
%} \n \n {# check if all values aren't too close together.
This will mute the colors because they will form a grey color. #}\n
\ {% elif ( (r - g)|abs <= 100 and (g - b)|abs <= 100 and (b - r)|abs
<= 100 ) %}\n {% set rgb_changer = range(3) | random %}\n {%
if rgb_changer == 0 %}\n {{ (r / 2)|int , g, b }}\n {% elif
rgb_changer == 1 %}\n {{ r, (g / 2)|int, b }}\n {% elif
rgb_changer == 2 %}\n {{ r, g, (b / 2)|int }}\n {% endif
%}\n {% else %}\n {{ r, g, b }}\n {% endif %}\n{% elif color_mode
== \"christmas\" %} \n {% macro random_rgb_component(max) %}\n
\ {{ range(0, max) | random }}\n {% endmacro %}\n {% macro get_color(color_key)
%}\n {% if color_key == 1 %}\n [{{ random_rgb_component(256)
}}, 0, 0]\n {% elif color_key == 2 %}\n [0, {{ random_rgb_component(256)
}}, 0]\n {% elif color_key == 3 %}\n [0, 0, {{ random_rgb_component(256)
}}]\n {% elif color_key == 4 %}\n [255, 255, {{ random_rgb_component(50)
}}]\n {% endif %}\n {% endmacro %}\n {% set color_key = range(1,
5) | random %}\n {% set random_color = get_color(color_key) %}\n
\ {{ random_color }}\n{% elif color_mode == \"red\" %}\n {{ range(256)
| random, 0, 0 }}\n{% elif color_mode == \"green\" %}\n {{ 0, range(256)
| random, 0 }}\n{% elif color_mode == \"blue\" %}\n {{ 0, 0, range(256)
| random }}\n{% elif color_mode == \"teal\" %}\n {{ range(256)
| random, 255, 255 }}\n{% elif color_mode == \"pink\" %}\n {{ 255,
range(256) | random, 255 }}\n{% elif color_mode == \"yellow\" %}\n
\ {{ 255, 255, range(256) | random }}\n{% else %}\n {{ 255, 255,
255 }}\n{% endif %}\n"
- action: light.turn_on
data: "{% if light_effect == \"\" %}\n {% if color_mode == \"no_color_change\"
%}\n {{ { \"transition\": transition_time, \"brightness_pct\":
brightness_value } }}\n {% else %}\n {{ { \"transition\": transition_time,
\"brightness_pct\": brightness_value, \"rgb_color\": rgb_value } }}\n
\ {% endif %}\n{% else %}\n {% if color_mode == \"no_color_change\"
%}\n {{ { \"transition\": transition_time, \"brightness_pct\":
brightness_value, \"effect\": light_effect } }}\n {% else %}\n {{
{ \"transition\": transition_time, \"brightness_pct\": brightness_value,
\"rgb_color\": rgb_value, \"effect\": light_effect } }}\n {% endif
%}\n{% endif %}\n"
target:
entity_id: '{{ repeat.item }}'
- delay: !input time_between_changes
until:
- condition: state
entity_id: !input party_mode_trigger
state: 'off'
- delay: !input turn_off_delay
- choose:
- conditions: '{{ "lights_off" in after_party_state }}'
sequence:
- action: light.turn_off
target:
entity_id: '{{ target_lights }}'
- conditions: '{{ "return_to_previous" in after_party_state }}'
sequence:
- action: scene.turn_on
metadata: {}
target:
entity_id: scene.before_state
- conditions: '{{ "user_defined_scene" in after_party_state }}'
sequence:
- action: scene.turn_on
metadata: {}
target:
entity_id: '{{ after_party_scene }}'
- conditions: '{{ "scene_then_off" in after_party_state }}'
sequence:
- action: scene.turn_on
metadata: {}
target:
entity_id: '{{ after_party_scene }}'
- action: light.turn_off
target:
entity_id: '{{ target_lights }}'
@@ -0,0 +1,12 @@
name: "Dream-Frigate is unavailable"
done_message: "Dream-Frigate is now available"
entity_id: sensor.frigate_status
state: unavailable
repeat:
- 1
- 5
- 15
can_acknowledge: True
skip_first: true
notifiers:
- mobile_app_pixel_7
+34 -34
View File
@@ -1,36 +1,36 @@
adaptive_lighting: adaptive_lighting:
- name: "Southern" # - name: "Southern"
lights: [] # lights: []
interval: 90 # interval: 90
transition: 45 # transition: 45
initial_transition: 1 # initial_transition: 1
min_brightness: 1 # min_brightness: 1
max_brightness: 100 # max_brightness: 100
min_color_temp: 2000 # min_color_temp: 2000
max_color_temp: 6500 # max_color_temp: 6500
prefer_rgb_color: false # prefer_rgb_color: false
sleep_brightness: 1 # sleep_brightness: 1
sleep_color_temp: 1000 # sleep_color_temp: 1000
min_sunrise_time: "05:30:00" # min_sunrise_time: "05:30:00"
max_sunrise_time: "07:00:00" # max_sunrise_time: "07:00:00"
min_sunset_time: "19:00:00" # min_sunset_time: "19:00:00"
max_sunset_time: "21:00:00" # max_sunset_time: "21:00:00"
take_over_control: true # take_over_control: true
detect_non_ha_changes: false # detect_non_ha_changes: false
only_once: false # only_once: false
- name: "Northern" # - name: "Northern"
lights: [] # lights: []
interval: 90 # interval: 90
transition: 45 # transition: 45
initial_transition: 1 # initial_transition: 1
min_brightness: 1 # min_brightness: 1
max_brightness: 100 # max_brightness: 100
min_color_temp: 2000 # min_color_temp: 2000
max_color_temp: 6500 # max_color_temp: 6500
prefer_rgb_color: false # prefer_rgb_color: false
sleep_brightness: 1 # sleep_brightness: 1
sleep_color_temp: 1000 # sleep_color_temp: 1000
take_over_control: true # take_over_control: true
detect_non_ha_changes: false # detect_non_ha_changes: false
only_once: false # only_once: false
+8 -8
View File
@@ -28,10 +28,10 @@ group:
- media_player.great_room - media_player.great_room
- media_player.kitchen - media_player.kitchen
- media_player.front_room_hub - media_player.front_room_hub
- media_player.girls_room_hub - media_player.girls_room_clock
- media_player.boys_room_clock - media_player.boys_room_clock
- media_player.bathroom_mini - media_player.bathroom_mini
- media_player.ma_home_assistant_voice_097b44_media_player - media_player.bedroom_hub
- media_player.computer_area_hub - media_player.computer_area_hub
###### INPUT SELECT ------------------------------------------ ###### INPUT SELECT ------------------------------------------
@@ -101,7 +101,7 @@ script:
{% elif is_state("input_select.google_home", "Master Bedroom") %} media_player.ma_home_assistant_voice_097b44_media_player {% elif is_state("input_select.google_home", "Master Bedroom") %} media_player.ma_home_assistant_voice_097b44_media_player
{% elif is_state("input_select.google_home", "Master Bathroom") %} media_player.great_room {% elif is_state("input_select.google_home", "Master Bathroom") %} media_player.great_room
{% elif is_state("input_select.google_home", "Kitchen") %} media_player.kitchen {% elif is_state("input_select.google_home", "Kitchen") %} media_player.kitchen
{% elif is_state("input_select.google_home", "Girls Room") %} media_player.girls_room_hub {% elif is_state("input_select.google_home", "Girls Room") %} media_player.girls_room_clock
{% elif is_state("input_select.google_home", "Boys Room") %} media_player.boys_room_clock {% elif is_state("input_select.google_home", "Boys Room") %} media_player.boys_room_clock
{% elif is_state("input_select.google_home", "Computer Area") %} media_player.computer_area_hub {% elif is_state("input_select.google_home", "Computer Area") %} media_player.computer_area_hub
{% elif is_state("input_select.google_home", "Downstairs") %} media_player.downstairs_public {% elif is_state("input_select.google_home", "Downstairs") %} media_player.downstairs_public
@@ -116,7 +116,7 @@ script:
{% elif is_state("input_select.google_home", "Master Bedroom") %} media_player.ma_home_assistant_voice_097b44_media_player {% elif is_state("input_select.google_home", "Master Bedroom") %} media_player.ma_home_assistant_voice_097b44_media_player
{% elif is_state("input_select.google_home", "Master Bathroom") %} media_player.great_room {% elif is_state("input_select.google_home", "Master Bathroom") %} media_player.great_room
{% elif is_state("input_select.google_home", "Kitchen") %} media_player.kitchen {% elif is_state("input_select.google_home", "Kitchen") %} media_player.kitchen
{% elif is_state("input_select.google_home", "Girls Room") %} media_player.girls_room_hub {% elif is_state("input_select.google_home", "Girls Room") %} media_player.girls_room_clock
{% elif is_state("input_select.google_home", "Boys Room") %} media_player.boys_room_clock {% elif is_state("input_select.google_home", "Boys Room") %} media_player.boys_room_clock
{% elif is_state("input_select.google_home", "Computer Area") %} media_player.computer_area_hub {% elif is_state("input_select.google_home", "Computer Area") %} media_player.computer_area_hub
{% elif is_state("input_select.google_home", "Downstairs") %} media_player.downstairs_public {% elif is_state("input_select.google_home", "Downstairs") %} media_player.downstairs_public
@@ -162,10 +162,10 @@ script:
data_template: data_template:
entity_id: > entity_id: >
{% if is_state("input_select.google_home", "Front Room") %} media_player.front_room_hub {% if is_state("input_select.google_home", "Front Room") %} media_player.front_room_hub
{% elif is_state("input_select.google_home", "Master Bedroom") %} media_player.ma_home_assistant_voice_097b44_media_player {% elif is_state("input_select.google_home", "Master Bedroom") %} media_player.bedroom_hub
{% elif is_state("input_select.google_home", "Master Bathroom") %} media_player.great_room {% elif is_state("input_select.google_home", "Master Bathroom") %} media_player.great_room
{% elif is_state("input_select.google_home", "Kitchen") %} media_player.kitchen {% elif is_state("input_select.google_home", "Kitchen") %} media_player.kitchen
{% elif is_state("input_select.google_home", "Girls Room") %} media_player.girls_room_hub {% elif is_state("input_select.google_home", "Girls Room") %} media_player.girls_room_clock
{% elif is_state("input_select.google_home", "Boys Room") %} media_player.boys_room_clock {% elif is_state("input_select.google_home", "Boys Room") %} media_player.boys_room_clock
{% elif is_state("input_select.google_home", "Computer Area") %} media_player.computer_area_hub {% elif is_state("input_select.google_home", "Computer Area") %} media_player.computer_area_hub
{% elif is_state("input_select.google_home", "Downstairs") %} media_player.downstairs_public {% elif is_state("input_select.google_home", "Downstairs") %} media_player.downstairs_public
@@ -188,10 +188,10 @@ automation:
data_template: data_template:
entity_id: > entity_id: >
{% if is_state("input_select.google_home", "Front Room") %} media_player.front_room_hub {% if is_state("input_select.google_home", "Front Room") %} media_player.front_room_hub
{% elif is_state("input_select.google_home", "Master Bedroom") %} media_player.ma_home_assistant_voice_097b44_media_player {% elif is_state("input_select.google_home", "Master Bedroom") %} media_player.bedroom_hub
{% elif is_state("input_select.google_home", "Master Bathroom") %} media_player.great_room {% elif is_state("input_select.google_home", "Master Bathroom") %} media_player.great_room
{% elif is_state("input_select.google_home", "Kitchen") %} media_player.kitchen {% elif is_state("input_select.google_home", "Kitchen") %} media_player.kitchen
{% elif is_state("input_select.google_home", "Girls Room") %} media_player.girls_room_hub {% elif is_state("input_select.google_home", "Girls Room") %} media_player.girls_room_clock
{% elif is_state("input_select.google_home", "Boys Room") %} media_player.boys_room_clock {% elif is_state("input_select.google_home", "Boys Room") %} media_player.boys_room_clock
{% elif is_state("input_select.google_home", "Computer Area") %} media_player.computer_area_hub {% elif is_state("input_select.google_home", "Computer Area") %} media_player.computer_area_hub
{% elif is_state("input_select.google_home", "Downstairs") %} media_player.downstairs_public {% elif is_state("input_select.google_home", "Downstairs") %} media_player.downstairs_public
+6 -6
View File
@@ -18,7 +18,7 @@ input_select:
name: To Screen name: To Screen
options: options:
- Front Room Display - Front Room Display
- Girls Room Hub - Bedroom Hub
- Computer Area Hub - Computer Area Hub
script: script:
@@ -31,8 +31,8 @@ script:
media_player: > media_player: >
{% if is_state('input_select.cast_to_screen_dropdown', 'Front Room Display') %} {% if is_state('input_select.cast_to_screen_dropdown', 'Front Room Display') %}
media_player.front_room_hub media_player.front_room_hub
{% elif is_state('input_select.cast_to_screen_dropdown', 'Girls Room Hub') %} {% elif is_state('input_select.cast_to_screen_dropdown', 'Bedroom Hub') %}
media_player.girls_room_hub media_player.bedroom_hub
{% elif is_state('input_select.cast_to_screen_dropdown', 'Computer Area Hub') %} {% elif is_state('input_select.cast_to_screen_dropdown', 'Computer Area Hub') %}
media_player.computer_area_hub media_player.computer_area_hub
{% endif %} {% endif %}
@@ -119,7 +119,7 @@ script:
# {% if is_state('input_select.cast_to_screen_dropdown', 'Front Room Display') %} # {% if is_state('input_select.cast_to_screen_dropdown', 'Front Room Display') %}
# media_player.front_room_hub # media_player.front_room_hub
# {% elif is_state('input_select.cast_to_screen_dropdown', 'Girls Room Hub') %} # {% elif is_state('input_select.cast_to_screen_dropdown', 'Girls Room Hub') %}
# media_player.girls_room_hub # media_player.bedroom_hub
# {% elif is_state('input_select.cast_to_screen_dropdown', 'Computer Area Hub') %} # {% elif is_state('input_select.cast_to_screen_dropdown', 'Computer Area Hub') %}
# media_player.computer_area_hub # media_player.computer_area_hub
# {% endif %} # {% endif %}
@@ -152,7 +152,7 @@ script:
# {% if is_state('input_select.cast_to_screen_dropdown', 'Front Room Display') %} # {% if is_state('input_select.cast_to_screen_dropdown', 'Front Room Display') %}
# media_player.front_room_hub # media_player.front_room_hub
# {% elif is_state('input_select.cast_to_screen_dropdown', 'Girls Room Hub') %} # {% elif is_state('input_select.cast_to_screen_dropdown', 'Girls Room Hub') %}
# media_player.girls_room_hub # media_player.bedroom_hub
# {% elif is_state('input_select.cast_to_screen_dropdown', 'Computer Area Hub') %} # {% elif is_state('input_select.cast_to_screen_dropdown', 'Computer Area Hub') %}
# media_player.computer_area_hub # media_player.computer_area_hub
# {% endif %} # {% endif %}
@@ -188,7 +188,7 @@ script:
# {% if is_state('input_select.cast_to_screen_dropdown', 'Front Room Display') %} # {% if is_state('input_select.cast_to_screen_dropdown', 'Front Room Display') %}
# media_player.front_room_hub # media_player.front_room_hub
# {% elif is_state('input_select.cast_to_screen_dropdown', 'Girls Room Hub') %} # {% elif is_state('input_select.cast_to_screen_dropdown', 'Girls Room Hub') %}
# media_player.girls_room_hub # media_player.bedroom_hub
# {% elif is_state('input_select.cast_to_screen_dropdown', 'Computer Area Hub') %} # {% elif is_state('input_select.cast_to_screen_dropdown', 'Computer Area Hub') %}
# media_player.computer_area_hub # media_player.computer_area_hub
# {% endif %} # {% endif %}
+1 -1
View File
@@ -14,7 +14,7 @@ template:
- name: Master Bed Occupied - name: Master Bed Occupied
unique_id: a5620335-43a1-47ce-bf37-ac8433f3a406 unique_id: a5620335-43a1-47ce-bf37-ac8433f3a406
state: "{{ is_state('binary_sensor.bed_presence_2d14a4_bed_occupied_either', 'on') }}" state: "{{ is_state('binary_sensor.bed_presence_c175a4_bed_occupied_either', 'on') }}"
icon: > icon: >
{% if is_state("binary_sensor.master_bed_occupied", "on") %} {% if is_state("binary_sensor.master_bed_occupied", "on") %}
mdi:bed-king mdi:bed-king
+2
View File
@@ -2,6 +2,8 @@
logger: logger:
default: warning default: warning
logs: logs:
# Adaptive Lighting Issues
# custom_components.adaptive_lighting: debug
# WebRTC issues # WebRTC issues
# custom_components.webrtc: debug # custom_components.webrtc: debug
@@ -254,3 +254,11 @@ template:
availability: "{{ (states('climate.thermostat') not in ['unknown', 'unavailable']) }}" availability: "{{ (states('climate.thermostat') not in ['unknown', 'unavailable']) }}"
device_class: duration device_class: duration
unit_of_measurement: min unit_of_measurement: min
- name: HVAC Preset Mode
unique_id: templatesensor_hvac_preset_mode
state: "{{state_attr('climate.thermostat','preset_mode')}}"
availability: "{{ (states('climate.thermostat') not in ['unknown', 'unavailable']) }}"
device_class: enum
attributes:
options: "{{state_attr('climate.thermostat','preset_modes')}}"
+13 -2
View File
@@ -7,17 +7,28 @@ template:
{{ expand(integration_entities('Z-Wave JS') )| selectattr("entity_id", "search", "node_status") | {{ expand(integration_entities('Z-Wave JS') )| selectattr("entity_id", "search", "node_status") |
selectattr('state', 'in', 'alive') | selectattr('state', 'in', 'alive') |
map(attribute='entity_id')| list | count | int(default=0)}} map(attribute='entity_id')| list | count | int(default=0)}}
attributes:
devices: >-
{{ expand(integration_entities('Z-Wave JS') )| selectattr("entity_id", "search", "node_status") |
selectattr('state', 'in', 'alive') | map(attribute='entity_id')| list }}
- name: "Dead ZWave Devices" - name: "Dead ZWave Devices"
unique_id: template_sensor_failed_zwave unique_id: template_sensor_failed_zwave
icon: mdi:z-wave icon: mdi:z-wave
state: >- state: >-
{{ expand(integration_entities('Z-Wave JS') )| selectattr("entity_id", "search", "node_status") | {{ expand(integration_entities('Z-Wave JS') )| selectattr("entity_id", "search", "node_status") |
selectattr('state', 'in', 'alive') | map(attribute='entity_id')| list | count | int(default=0)}} selectattr('state', 'in', 'dead') | map(attribute='entity_id')| list | count | int(default=0)}}
attributes: attributes:
devices: >- devices: >-
{{ expand(integration_entities('Z-Wave JS') )| selectattr("entity_id", "search", "node_status") | {{ expand(integration_entities('Z-Wave JS') )| selectattr("entity_id", "search", "node_status") |
selectattr('state', 'in', 'alive') | map(attribute='entity_id')| list }} selectattr('state', 'in', 'dead') | map(attribute='entity_id')| list }}
- name: ZWave Pending Updates
unique_id: 6bf2876a-378a-4394-8a97-5b0603b17f2e
state: "{{ states.update | selectattr('state', 'eq', 'on') | map(attribute='entity_id') | select ('in',integration_entities('Z-Wave JS')) | list | count }}"
icon: mdi:z-wave
attributes:
devices: "{{ states.update | selectattr('state', 'eq', 'on') | map(attribute='entity_id') | select ('in',integration_entities('Z-Wave JS')) | list }}"
automation: automation:
- id: automation_alert_failed_zwave_nodes - id: automation_alert_failed_zwave_nodes
+2 -2
View File
@@ -12,10 +12,10 @@ lists:
- in: "front room" - in: "front room"
out: "media_player.front_room_hub" out: "media_player.front_room_hub"
- in: "master bedroom" - in: "master bedroom"
out: "media_player.master_bedroom_clock" out: "media_player.bedroom_hub"
- in: "downstairs" - in: "downstairs"
out: "media_player.computer_area_hub" out: "media_player.computer_area_hub"
volume: volume:
range: range:
from: 0 from: 0
to: 100 to: 100
+2 -2
View File
@@ -46,13 +46,13 @@
# media_player.kitchen: # media_player.kitchen:
# icon: mdi:cast-audio # icon: mdi:cast-audio
# media_player.master_bedroom_clock: # media_player.bedroom_hub:
# icon: mdi:cast-audio # icon: mdi:cast-audio
# # media_player.master_bedroom_tv: # # media_player.master_bedroom_tv:
# # icon: mdi:cast-variant # # icon: mdi:cast-variant
# media_player.girls_room_hub: # media_player.bedroom_hub:
# icon: mdi:cast-variant # icon: mdi:cast-variant
# media_player.outside: # media_player.outside:
+1 -1
View File
@@ -810,7 +810,7 @@ sensor:
topic: ${mqtt_root_topic}/${devicename}/${ct21Name}_kwh/status topic: ${mqtt_root_topic}/${devicename}/${ct21Name}_kwh/status
payload_available: online payload_available: online
payload_not_available: offline payload_not_available: offline
state_topic: ${mqtt_root_topic}/${devicename}/${ct21Name}_kwh state_topic: ${mqtt_root_topic}/${devicename}/${ct21Name}_kwh
# min_save_interval: ${update_time} # min_save_interval: ${update_time}
#kWh From CT 22 #kWh From CT 22
+4 -3
View File
@@ -38,14 +38,15 @@ packages:
- bed-presence-mk1/base.yaml - bed-presence-mk1/base.yaml
- esphome-common/bluetooth-proxy.yaml - esphome-common/bluetooth-proxy.yaml
binary_sensor: binary_sensor:
- id: !remove local_status_sensor - id: !remove bed_presence_status
button: button:
- id: !remove local_restart_button - id: !remove btn_restart
sensor: sensor:
- id: !remove local_uptime_sensor - id: !remove bed_presence_uptime
# See https://github.com/ElevatedSensors/sensor-configs/blob/main/bed-presence-mk1/sensor.yaml for a detailed # See https://github.com/ElevatedSensors/sensor-configs/blob/main/bed-presence-mk1/sensor.yaml for a detailed
# description of available substitutions. # description of available substitutions.
# #
@@ -6,33 +6,45 @@ sensor:
############ ############
- platform: atm90e32 - platform: atm90e32
release_device: true release_device: true
cs_pin: 0 cs_pin: ${addon1_ic1}
id: ${addon1_id1} id: ${addon1_id1}
phase_a: phase_a:
current: current:
name: ${ct7_name} Amps name: ${ct7_name} ${amp_label}
id: ct7Amps id: ct7Amps
power: power:
name: ${ct7_name} Watts name: ${ct7_name} ${watt_label}
id: ct7Watts id: ct7Watts
filters:
- lambda: |-
if (x < 0) return x * -1;
return x;
gain_voltage: ${voltage_cal1} gain_voltage: ${voltage_cal1}
gain_ct: ${current_cal_ct7} gain_ct: ${current_cal_ct7}
phase_b: phase_b:
current: current:
name: ${ct8_name} Amps name: ${ct8_name} ${amp_label}
id: ct8Amps id: ct8Amps
power: power:
name: ${ct8_name} Watts name: ${ct8_name} ${watt_label}
id: ct8Watts id: ct8Watts
filters:
- lambda: |-
if (x < 0) return x * -1;
return x;
gain_voltage: ${voltage_cal1} gain_voltage: ${voltage_cal1}
gain_ct: ${current_cal_ct8} gain_ct: ${current_cal_ct8}
phase_c: phase_c:
current: current:
name: ${ct9_name} Amps name: ${ct9_name} ${amp_label}
id: ct9Amps id: ct9Amps
power: power:
name: ${ct9_name} Watts name: ${ct9_name} ${watt_label}
id: ct9Watts id: ct9Watts
filters:
- lambda: |-
if (x < 0) return x * -1;
return x;
gain_voltage: ${voltage_cal1} gain_voltage: ${voltage_cal1}
gain_ct: ${current_cal_ct9} gain_ct: ${current_cal_ct9}
line_frequency: ${electric_freq} line_frequency: ${electric_freq}
@@ -44,33 +56,45 @@ sensor:
############ ############
- platform: atm90e32 - platform: atm90e32
release_device: true release_device: true
cs_pin: 16 cs_pin: ${addon1_ic2}
id: ${addon1_id2} id: ${addon1_id2}
phase_a: phase_a:
current: current:
name: ${ct10_name} Amps name: ${ct10_name} ${amp_label}
id: ct10Amps id: ct10Amps
power: power:
name: ${ct10_name} Watts name: ${ct10_name} ${watt_label}
id: ct10Watts id: ct10Watts
filters:
- lambda: |-
if (x < 0) return x * -1;
return x;
gain_voltage: ${voltage_cal2} gain_voltage: ${voltage_cal2}
gain_ct: ${current_cal_ct10} gain_ct: ${current_cal_ct10}
phase_b: phase_b:
current: current:
name: ${ct11_name} Amps name: ${ct11_name} ${amp_label}
id: ct11Amps id: ct11Amps
power: power:
name: ${ct11_name} Watts name: ${ct11_name} ${watt_label}
id: ct11Watts id: ct11Watts
filters:
- lambda: |-
if (x < 0) return x * -1;
return x;
gain_voltage: ${voltage_cal2} gain_voltage: ${voltage_cal2}
gain_ct: ${current_cal_ct11} gain_ct: ${current_cal_ct11}
phase_c: phase_c:
current: current:
name: ${ct12_name} Amps name: ${ct12_name} ${amp_label}
id: ct12Amps id: ct12Amps
power: power:
name: ${ct12_name} Watts name: ${ct12_name} ${watt_label}
id: ct12Watts id: ct12Watts
filters:
- lambda: |-
if (x < 0) return x * -1;
return x;
gain_voltage: ${voltage_cal2} gain_voltage: ${voltage_cal2}
gain_ct: ${current_cal_ct12} gain_ct: ${current_cal_ct12}
line_frequency: ${electric_freq} line_frequency: ${electric_freq}
@@ -79,9 +103,9 @@ sensor:
enable_offset_calibration: ${offset_calibration} enable_offset_calibration: ${offset_calibration}
enable_gain_calibration: ${gain_calibration} enable_gain_calibration: ${gain_calibration}
#Total Amps AddOn1 #Total A AddOn1
- platform: template - platform: template
name: ${friendly_name} Total Amps Add-on1 name: Add-on 1 Total ${amp_label}
id: totalAmpsAddOn1 id: totalAmpsAddOn1
lambda: return id(ct7Amps).state + id(ct8Amps).state + id(ct9Amps).state + id(ct10Amps).state + id(ct11Amps).state + id(ct12Amps).state ; lambda: return id(ct7Amps).state + id(ct8Amps).state + id(ct9Amps).state + id(ct10Amps).state + id(ct11Amps).state + id(ct12Amps).state ;
accuracy_decimals: 2 accuracy_decimals: 2
@@ -89,12 +113,78 @@ sensor:
device_class: current device_class: current
update_interval: ${update_time} update_interval: ${update_time}
#Total Watts AddOn1 #Total W AddOn1
- platform: template - platform: template
name: ${friendly_name} Total Watts Add-on1 name: Add-on 1 Total ${watt_label}
id: totalWattsAddOn1 id: totalWattsAddOn1
lambda: return id(ct7Watts).state + id(ct8Watts).state + id(ct9Watts).state + id(ct10Watts).state + id(ct11Watts).state + id(ct12Watts).state ; lambda: return id(ct7Watts).state + id(ct8Watts).state + id(ct9Watts).state + id(ct10Watts).state + id(ct11Watts).state + id(ct12Watts).state ;
accuracy_decimals: 2 accuracy_decimals: 2
unit_of_measurement: W unit_of_measurement: W
device_class: power device_class: power
update_interval: ${update_time} update_interval: ${update_time}
#kWh From CT 7
- platform: total_daily_energy
name: ${ct7_name} ${kwh_label}
id: ct7Kwh
power_id: ct7Watts
filters:
- multiply: 0.001
unit_of_measurement: kWh
device_class: energy
state_class: total_increasing
# kWh from CT 8
- platform: total_daily_energy
name: ${ct8_name} ${kwh_label}
id: ct8Kwh
power_id: ct8Watts
filters:
- multiply: 0.001
unit_of_measurement: kWh
device_class: energy
state_class: total_increasing
#kWh From CT 9
- platform: total_daily_energy
name: ${ct9_name} ${kwh_label}
id: ct9Kwh
power_id: ct9Watts
filters:
- multiply: 0.001
unit_of_measurement: kWh
device_class: energy
state_class: total_increasing
#kWh From CT 10
- platform: total_daily_energy
name: ${ct10_name} ${kwh_label}
id: ct10Kwh
power_id: ct10Watts
filters:
- multiply: 0.001
unit_of_measurement: kWh
device_class: energy
state_class: total_increasing
#kWh From CT 11
- platform: total_daily_energy
name: ${ct11_name} ${kwh_label}
id: ct11Kwh
power_id: ct11Watts
filters:
- multiply: 0.001
unit_of_measurement: kWh
device_class: energy
state_class: total_increasing
#kWh From CT 12
- platform: total_daily_energy
name: ${ct12_name} ${kwh_label}
id: ct12Kwh
power_id: ct12Watts
filters:
- multiply: 0.001
unit_of_measurement: kWh
device_class: energy
state_class: total_increasing
@@ -5,34 +5,46 @@ sensor:
#IC1 AddOn 2 #IC1 AddOn 2
############ ############
- platform: atm90e32 - platform: atm90e32
cs_pin: 27 cs_pin: ${addon2_ic1}
release_device: true release_device: true
id: ${addon2_id1} id: ${addon2_id1}
phase_a: phase_a:
current: current:
name: ${ct13_name} Amps name: ${ct13_name} ${amp_label}
id: ct13Amps id: ct13Amps
power: power:
name: ${ct13_name} Watts name: ${ct13_name} ${watt_label}
id: ct13Watts id: ct13Watts
filters:
- lambda: |-
if (x < 0) return x * -1;
return x;
gain_voltage: ${voltage_cal1} gain_voltage: ${voltage_cal1}
gain_ct: ${current_cal_ct13} gain_ct: ${current_cal_ct13}
phase_b: phase_b:
current: current:
name: ${ct14_name} Amps name: ${ct14_name} ${amp_label}
id: ct14Amps id: ct14Amps
power: power:
name: ${ct14_name} Watts name: ${ct14_name} ${watt_label}
id: ct14Watts id: ct14Watts
filters:
- lambda: |-
if (x < 0) return x * -1;
return x;
gain_voltage: ${voltage_cal1} gain_voltage: ${voltage_cal1}
gain_ct: ${current_cal_ct14} gain_ct: ${current_cal_ct14}
phase_c: phase_c:
current: current:
name: ${ct15_name} Amps name: ${ct15_name} ${amp_label}
id: ct15Amps id: ct15Amps
power: power:
name: ${ct15_name} Watts name: ${ct15_name} ${watt_label}
id: ct15Watts id: ct15Watts
filters:
- lambda: |-
if (x < 0) return x * -1;
return x;
gain_voltage: ${voltage_cal1} gain_voltage: ${voltage_cal1}
gain_ct: ${current_cal_ct15} gain_ct: ${current_cal_ct15}
line_frequency: ${electric_freq} line_frequency: ${electric_freq}
@@ -44,33 +56,45 @@ sensor:
############ ############
- platform: atm90e32 - platform: atm90e32
release_device: true release_device: true
cs_pin: 17 cs_pin: ${addon2_ic2}
id: ${addon2_id2} id: ${addon2_id2}
phase_a: phase_a:
current: current:
name: ${ct16_name} Amps name: ${ct16_name} ${amp_label}
id: ct16Amps id: ct16Amps
power: power:
name: ${ct16_name} Watts name: ${ct16_name} ${watt_label}
id: ct16Watts id: ct16Watts
filters:
- lambda: |-
if (x < 0) return x * -1;
return x;
gain_voltage: ${voltage_cal2} gain_voltage: ${voltage_cal2}
gain_ct: ${current_cal_ct16} gain_ct: ${current_cal_ct16}
phase_b: phase_b:
current: current:
name: ${ct17_name} Amps name: ${ct17_name} ${amp_label}
id: ct17Amps id: ct17Amps
power: power:
name: ${ct17_name} Watts name: ${ct17_name} ${watt_label}
id: ct17Watts id: ct17Watts
filters:
- lambda: |-
if (x < 0) return x * -1;
return x;
gain_voltage: ${voltage_cal2} gain_voltage: ${voltage_cal2}
gain_ct: ${current_cal_ct17} gain_ct: ${current_cal_ct17}
phase_c: phase_c:
current: current:
name: ${ct18_name} Amps name: ${ct18_name} ${amp_label}
id: ct18Amps id: ct18Amps
power: power:
name: ${ct18_name} Watts name: ${ct18_name} ${watt_label}
id: ct18Watts id: ct18Watts
filters:
- lambda: |-
if (x < 0) return x * -1;
return x;
gain_voltage: ${voltage_cal2} gain_voltage: ${voltage_cal2}
gain_ct: ${current_cal_ct18} gain_ct: ${current_cal_ct18}
line_frequency: ${electric_freq} line_frequency: ${electric_freq}
@@ -79,9 +103,9 @@ sensor:
enable_offset_calibration: ${offset_calibration} enable_offset_calibration: ${offset_calibration}
enable_gain_calibration: ${gain_calibration} enable_gain_calibration: ${gain_calibration}
#Total Amps AddOn2 #Total A AddOn2
- platform: template - platform: template
name: ${friendly_name} Total Amps Add-on2 name: Add-on 2 Total ${amp_label}
id: totalAmpsAddOn2 id: totalAmpsAddOn2
lambda: return id(ct13Amps).state + id(ct14Amps).state + id(ct15Amps).state + id(ct16Amps).state + id(ct17Amps).state + id(ct18Amps).state ; lambda: return id(ct13Amps).state + id(ct14Amps).state + id(ct15Amps).state + id(ct16Amps).state + id(ct17Amps).state + id(ct18Amps).state ;
accuracy_decimals: 2 accuracy_decimals: 2
@@ -89,12 +113,78 @@ sensor:
device_class: current device_class: current
update_interval: ${update_time} update_interval: ${update_time}
#Total Watts AddOn2 #Total W AddOn2
- platform: template - platform: template
name: ${friendly_name} Total Watts Add-on2 name: Add-on 2 Total ${watt_label}
id: totalWattsAddOn2 id: totalWattsAddOn2
lambda: return id(ct13Watts).state + id(ct14Watts).state + id(ct15Watts).state + id(ct16Watts).state + id(ct17Watts).state + id(ct18Watts).state ; lambda: return id(ct13Watts).state + id(ct14Watts).state + id(ct15Watts).state + id(ct16Watts).state + id(ct17Watts).state + id(ct18Watts).state ;
accuracy_decimals: 2 accuracy_decimals: 2
unit_of_measurement: W unit_of_measurement: W
device_class: power device_class: power
update_interval: ${update_time} update_interval: ${update_time}
#kWh From CT 13
- platform: total_daily_energy
name: ${ct13_name} ${kwh_label}
id: ct13Kwh
power_id: ct13Watts
filters:
- multiply: 0.001
unit_of_measurement: kWh
device_class: energy
state_class: total_increasing
# kWh from CT 14
- platform: total_daily_energy
name: ${ct14_name} ${kwh_label}
id: ct14Kwh
power_id: ct14Watts
filters:
- multiply: 0.001
unit_of_measurement: kWh
device_class: energy
state_class: total_increasing
#kWh From CT 15
- platform: total_daily_energy
name: ${ct15_name} ${kwh_label}
id: ct15Kwh
power_id: ct15Watts
filters:
- multiply: 0.001
unit_of_measurement: kWh
device_class: energy
state_class: total_increasing
#kWh From CT 16
- platform: total_daily_energy
name: ${ct16_name} ${kwh_label}
id: ct16Kwh
power_id: ct16Watts
filters:
- multiply: 0.001
unit_of_measurement: kWh
device_class: energy
state_class: total_increasing
#kWh From CT 17
- platform: total_daily_energy
name: ${ct17_name} ${kwh_label}
id: ct17Kwh
power_id: ct17Watts
filters:
- multiply: 0.001
unit_of_measurement: kWh
device_class: energy
state_class: total_increasing
#kWh From CT 18
- platform: total_daily_energy
name: ${ct18_name} ${kwh_label}
id: ct18Kwh
power_id: ct18Watts
filters:
- multiply: 0.001
unit_of_measurement: kWh
device_class: energy
state_class: total_increasing
@@ -7,33 +7,45 @@ sensor:
- platform: atm90e32 - platform: atm90e32
release_device: true release_device: true
#if ESP32 has an LED for GPIO2, remove jumper or ESP32 from meter stack before programming via serial #if ESP32 has an LED for GPIO2, remove jumper or ESP32 from meter stack before programming via serial
cs_pin: 2 cs_pin: ${addon3_ic1}
id: ${addon3_id1} id: ${addon3_id1}
phase_a: phase_a:
current: current:
name: ${ct19_name} Amps name: ${ct19_name} ${amp_label}
id: ct19Amps id: ct19Amps
power: power:
name: ${ct19_name} Watts name: ${ct19_name} ${watt_label}
id: ct19Watts id: ct19Watts
filters:
- lambda: |-
if (x < 0) return x * -1;
return x;
gain_voltage: ${voltage_cal1} gain_voltage: ${voltage_cal1}
gain_ct: ${current_cal_ct19} gain_ct: ${current_cal_ct19}
phase_b: phase_b:
current: current:
name: ${ct20_name} Amps name: ${ct20_name} ${amp_label}
id: ct20Amps id: ct20Amps
power: power:
name: ${ct20_name} Watts name: ${ct20_name} ${watt_label}
id: ct20Watts id: ct20Watts
filters:
- lambda: |-
if (x < 0) return x * -1;
return x;
gain_voltage: ${voltage_cal1} gain_voltage: ${voltage_cal1}
gain_ct: ${current_cal_ct20} gain_ct: ${current_cal_ct20}
phase_c: phase_c:
current: current:
name: ${ct21_name} Amps name: ${ct21_name} ${amp_label}
id: ct21Amps id: ct21Amps
power: power:
name: ${ct21_name} Watts name: ${ct21_name} ${watt_label}
id: ct21Watts id: ct21Watts
filters:
- lambda: |-
if (x < 0) return x * -1;
return x;
gain_voltage: ${voltage_cal1} gain_voltage: ${voltage_cal1}
gain_ct: ${current_cal_ct21} gain_ct: ${current_cal_ct21}
line_frequency: ${electric_freq} line_frequency: ${electric_freq}
@@ -45,33 +57,45 @@ sensor:
############ ############
- platform: atm90e32 - platform: atm90e32
release_device: true release_device: true
cs_pin: 21 cs_pin: ${addon3_ic2}
id: ${addon3_id2} id: ${addon3_id2}
phase_a: phase_a:
current: current:
name: ${ct22_name} Amps name: ${ct22_name} ${amp_label}
id: ct22Amps id: ct22Amps
power: power:
name: ${ct22_name} Watts name: ${ct22_name} ${watt_label}
id: ct22Watts id: ct22Watts
filters:
- lambda: |-
if (x < 0) return x * -1;
return x;
gain_voltage: ${voltage_cal2} gain_voltage: ${voltage_cal2}
gain_ct: ${current_cal_ct22} gain_ct: ${current_cal_ct22}
phase_b: phase_b:
current: current:
name: ${ct23_name} Amps name: ${ct23_name} ${amp_label}
id: ct23Amps id: ct23Amps
power: power:
name: ${ct23_name} Watts name: ${ct23_name} ${watt_label}
id: ct23Watts id: ct23Watts
filters:
- lambda: |-
if (x < 0) return x * -1;
return x;
gain_voltage: ${voltage_cal2} gain_voltage: ${voltage_cal2}
gain_ct: ${current_cal_ct23} gain_ct: ${current_cal_ct23}
phase_c: phase_c:
current: current:
name: ${ct24_name} Amps name: ${ct24_name} ${amp_label}
id: ct24Amps id: ct24Amps
power: power:
name: ${ct24_name} Watts name: ${ct24_name} ${watt_label}
id: ct24Watts id: ct24Watts
filters:
- lambda: |-
if (x < 0) return x * -1;
return x;
gain_voltage: ${voltage_cal2} gain_voltage: ${voltage_cal2}
gain_ct: ${current_cal_ct24} gain_ct: ${current_cal_ct24}
line_frequency: ${electric_freq} line_frequency: ${electric_freq}
@@ -80,9 +104,9 @@ sensor:
enable_offset_calibration: ${offset_calibration} enable_offset_calibration: ${offset_calibration}
enable_gain_calibration: ${gain_calibration} enable_gain_calibration: ${gain_calibration}
#Total Amps AddOn3 #Total A AddOn3
- platform: template - platform: template
name: ${friendly_name} Total Amps Add-on3 name: Add-on 3 Total ${amp_label}
id: totalAmpsAddOn3 id: totalAmpsAddOn3
lambda: return id(ct19Amps).state + id(ct20Amps).state + id(ct21Amps).state + id(ct22Amps).state + id(ct23Amps).state + id(ct24Amps).state ; lambda: return id(ct19Amps).state + id(ct20Amps).state + id(ct21Amps).state + id(ct22Amps).state + id(ct23Amps).state + id(ct24Amps).state ;
accuracy_decimals: 2 accuracy_decimals: 2
@@ -90,12 +114,78 @@ sensor:
device_class: current device_class: current
update_interval: ${update_time} update_interval: ${update_time}
#Total Watts AddOn3 #Total W AddOn3
- platform: template - platform: template
name: ${friendly_name} Total Watts Add-on3 name: Add-on 3 Total ${watt_label}
id: totalWattsAddOn3 id: totalWattsAddOn3
lambda: return id(ct19Watts).state + id(ct20Watts).state + id(ct21Watts).state + id(ct22Watts).state + id(ct23Watts).state + id(ct24Watts).state ; lambda: return id(ct19Watts).state + id(ct20Watts).state + id(ct21Watts).state + id(ct22Watts).state + id(ct23Watts).state + id(ct24Watts).state ;
accuracy_decimals: 2 accuracy_decimals: 2
unit_of_measurement: W unit_of_measurement: W
device_class: power device_class: power
update_interval: ${update_time} update_interval: ${update_time}
#kWh From CT 19
- platform: total_daily_energy
name: ${ct19_name} ${kwh_label}
id: ct19Kwh
power_id: ct19Watts
filters:
- multiply: 0.001
unit_of_measurement: kWh
device_class: energy
state_class: total_increasing
# kWh from CT 20
- platform: total_daily_energy
name: ${ct20_name} ${kwh_label}
id: ct20Kwh
power_id: ct20Watts
filters:
- multiply: 0.001
unit_of_measurement: kWh
device_class: energy
state_class: total_increasing
#kWh From CT 21
- platform: total_daily_energy
name: ${ct21_name} ${kwh_label}
id: ct21Kwh
power_id: ct21Watts
filters:
- multiply: 0.001
unit_of_measurement: kWh
device_class: energy
state_class: total_increasing
#kWh From CT 22
- platform: total_daily_energy
name: ${ct22_name} ${kwh_label}
id: ct22Kwh
power_id: ct22Watts
filters:
- multiply: 0.001
unit_of_measurement: kWh
device_class: energy
state_class: total_increasing
#kWh From CT 23
- platform: total_daily_energy
name: ${ct23_name} ${kwh_label}
id: ct23Kwh
power_id: ct23Watts
filters:
- multiply: 0.001
unit_of_measurement: kWh
device_class: energy
state_class: total_increasing
#kWh From CT 24
- platform: total_daily_energy
name: ${ct24_name} ${kwh_label}
id: ct24Kwh
power_id: ct24Watts
filters:
- multiply: 0.001
unit_of_measurement: kWh
device_class: energy
state_class: total_increasing
@@ -3,7 +3,7 @@ sensor:
######### #########
- platform: atm90e32 - platform: atm90e32
release_device: true release_device: true
cs_pin: 5 cs_pin: ${main_ic1}
id: ${main_meter_id1} id: ${main_meter_id1}
phase_a: phase_a:
voltage: voltage:
@@ -11,35 +11,45 @@ sensor:
id: ic1Volts id: ic1Volts
accuracy_decimals: 1 accuracy_decimals: 1
current: current:
name: ${ct1_name} Amps name: ${ct1_name} ${amp_label}
id: ct1Amps id: ct1Amps
# The max value for current that the meter can output is 65.535. If you expect to measure current over 65A, # The max value for current that the meter can output is 65.535. If you expect to measure current over 65A,
# divide the gain_ct by 2 (120A CT) or 4 (200A CT) and multiply the current and power values by 2 or 4 by uncommenting the filter below # divide the gain_ct by 2 (120A CT) or 4 (200A CT) and multiply the current and power values by 2 or 4 by uncommenting the filter below
# filters: # filters:
# - multiply: 2 # - multiply: 2
power: power:
name: ${ct1_name} Watts name: ${ct1_name} ${watt_label}
id: ct1Watts id: ct1Watts
# filters: filters:
# - multiply: 2 - lambda: |-
if (x < 0) return x * -1;
return x;
gain_voltage: ${voltage_cal1} gain_voltage: ${voltage_cal1}
gain_ct: ${current_cal_ct1} gain_ct: ${current_cal_ct1}
phase_b: phase_b:
current: current:
name: ${ct2_name} Amps name: ${ct2_name} ${amp_label}
id: ct2Amps id: ct2Amps
power: power:
name: ${ct2_name} Watts name: ${ct2_name} ${watt_label}
id: ct2Watts id: ct2Watts
filters:
- lambda: |-
if (x < 0) return x * -1;
return x;
gain_voltage: ${voltage_cal1} gain_voltage: ${voltage_cal1}
gain_ct: ${current_cal_ct2} gain_ct: ${current_cal_ct2}
phase_c: phase_c:
current: current:
name: ${ct3_name} Amps name: ${ct3_name} ${amp_label}
id: ct3Amps id: ct3Amps
power: power:
name: ${ct3_name} Watts name: ${ct3_name} ${watt_label}
id: ct3Watts id: ct3Watts
filters:
- lambda: |-
if (x < 0) return x * -1;
return x;
gain_voltage: ${voltage_cal1} gain_voltage: ${voltage_cal1}
gain_ct: ${current_cal_ct3} gain_ct: ${current_cal_ct3}
frequency: frequency:
@@ -55,7 +65,7 @@ sensor:
########## ##########
- platform: atm90e32 - platform: atm90e32
release_device: true release_device: true
cs_pin: 4 cs_pin: ${main_ic2}
id: ${main_meter_id2} id: ${main_meter_id2}
phase_a: phase_a:
#this voltage is only needed if monitoring 2 voltages #this voltage is only needed if monitoring 2 voltages
@@ -64,29 +74,41 @@ sensor:
# id: ic2Volts # id: ic2Volts
# accuracy_decimals: 1 # accuracy_decimals: 1
current: current:
name: ${ct4_name} Amps name: ${ct4_name} ${amp_label}
id: ct4Amps id: ct4Amps
power: power:
name: ${ct4_name} Watts name: ${ct4_name} ${watt_label}
id: ct4Watts id: ct4Watts
filters:
- lambda: |-
if (x < 0) return x * -1;
return x;
gain_voltage: ${voltage_cal2} gain_voltage: ${voltage_cal2}
gain_ct: ${current_cal_ct4} gain_ct: ${current_cal_ct4}
phase_b: phase_b:
current: current:
name: ${ct5_name} Amps name: ${ct5_name} ${amp_label}
id: ct5Amps id: ct5Amps
power: power:
name: ${ct5_name} Watts name: ${ct5_name} ${watt_label}
id: ct5Watts id: ct5Watts
filters:
- lambda: |-
if (x < 0) return x * -1;
return x;
gain_voltage: ${voltage_cal2} gain_voltage: ${voltage_cal2}
gain_ct: ${current_cal_ct5} gain_ct: ${current_cal_ct5}
phase_c: phase_c:
current: current:
name: ${ct6_name} Amps name: ${ct6_name} ${amp_label}
id: ct6Amps id: ct6Amps
power: power:
name: ${ct6_name} Watts name: ${ct6_name} ${watt_label}
id: ct6Watts id: ct6Watts
filters:
- lambda: |-
if (x < 0) return x * -1;
return x;
gain_voltage: ${voltage_cal2} gain_voltage: ${voltage_cal2}
gain_ct: ${current_cal_ct6} gain_ct: ${current_cal_ct6}
#this is only needed if monitoring 2 voltages #this is only needed if monitoring 2 voltages
@@ -100,24 +122,90 @@ sensor:
enable_offset_calibration: ${offset_calibration} enable_offset_calibration: ${offset_calibration}
enable_gain_calibration: ${gain_calibration} enable_gain_calibration: ${gain_calibration}
#Total Amps Main #Total A Main
################ ################
- platform: template - platform: template
name: ${friendly_name} Total Amps Main name: Mainboard Total ${amp_label}
id: totalAmpsMain id: totalAmpsMain
lambda: return id(ct1Amps).state + id(ct2Amps).state + id(ct3Amps).state + id(ct4Amps).state + id(ct5Amps).state + id(ct6Amps).state ; lambda: return id(ct1Amps).state + id(ct2Amps).state + id(ct3Amps).state + id(ct4Amps).state + id(ct5Amps).state + id(ct6Amps).state ;
accuracy_decimals: 2 accuracy_decimals: 2
unit_of_measurement: A unit_of_measurement: A
device_class: current device_class: current
update_interval: ${update_time} update_interval: ${update_time}
#Total Watts Main #Total W Main
################# #################
- platform: template - platform: template
name: ${friendly_name} Total Watts Main name: Mainboard Total ${watt_label}
id: totalWattsMain id: totalWattsMain
lambda: return id(ct1Watts).state + id(ct2Watts).state + id(ct3Watts).state + id(ct4Watts).state + id(ct5Watts).state + id(ct6Watts).state ; lambda: return id(ct1Watts).state + id(ct2Watts).state + id(ct3Watts).state + id(ct4Watts).state + id(ct5Watts).state + id(ct6Watts).state ;
accuracy_decimals: 1 accuracy_decimals: 1
unit_of_measurement: W unit_of_measurement: W
device_class: power device_class: power
update_interval: ${update_time} update_interval: ${update_time}
#kWh From CT 1
- platform: total_daily_energy
name: ${ct1_name} ${kwh_label}
id: ct1Kwh
power_id: ct1Watts
filters:
- multiply: 0.001
unit_of_measurement: kWh
device_class: energy
state_class: total_increasing
# kWh from CT 2
- platform: total_daily_energy
name: ${ct2_name} ${kwh_label}
id: ct2Kwh
power_id: ct2Watts
filters:
- multiply: 0.001
unit_of_measurement: kWh
device_class: energy
state_class: total_increasing
#kWh From CT 3
- platform: total_daily_energy
name: ${ct3_name} ${kwh_label}
id: ct3Kwh
power_id: ct3Watts
filters:
- multiply: 0.001
unit_of_measurement: kWh
device_class: energy
state_class: total_increasing
#kWh From CT 4
- platform: total_daily_energy
name: ${ct4_name} ${kwh_label}
id: ct4Kwh
power_id: ct4Watts
filters:
- multiply: 0.001
unit_of_measurement: kWh
device_class: energy
state_class: total_increasing
#kWh From CT 5
- platform: total_daily_energy
name: ${ct5_name} ${kwh_label}
id: ct5Kwh
power_id: ct5Watts
filters:
- multiply: 0.001
unit_of_measurement: kWh
device_class: energy
state_class: total_increasing
#kWh From CT 6
- platform: total_daily_energy
name: ${ct6_name} ${kwh_label}
id: ct6Kwh
power_id: ct6Watts
filters:
- multiply: 0.001
unit_of_measurement: kWh
device_class: energy
state_class: total_increasing
+5 -1
View File
@@ -11,7 +11,7 @@ logger:
# Sync time with Home Assistant. # Sync time with Home Assistant.
time: time:
- platform: homeassistant - platform: homeassistant
id: homeassistant_time id: local_homeassistant_time
# Enable Home Assistant API # Enable Home Assistant API
api: api:
@@ -23,8 +23,12 @@ ota:
- platform: esphome - platform: esphome
password: !secret ota-password password: !secret ota-password
debug:
update_interval: 10s
packages: packages:
binary_sensor: !include binary_sensor/status_sensor.config.yaml binary_sensor: !include binary_sensor/status_sensor.config.yaml
button: !include button/restart_button.config.yaml button: !include button/restart_button.config.yaml
sensor: !include sensor/uptime_sensor.config.yaml sensor: !include sensor/uptime_sensor.config.yaml
debug: !include sensor/debug_sensor.config.yaml
text_sensor: !include text_sensor/version_sensor.config.yaml text_sensor: !include text_sensor/version_sensor.config.yaml
@@ -0,0 +1,10 @@
sensor:
- platform: debug
free:
name: "Heap Free"
id: heap_free_sensor
entity_category: diagnostic
loop_time:
name: "Loop Time"
id: loop_time_sensor
entity_category: diagnostic
@@ -8,6 +8,7 @@ sensor:
- platform: copy # Reports the WiFi signal strength in % - platform: copy # Reports the WiFi signal strength in %
source_id: local_wifi_signal_db source_id: local_wifi_signal_db
id: local_wifi_signal_percent
name: "WiFi Signal Strength" name: "WiFi Signal Strength"
filters: filters:
- lambda: return min(max(2 * (x + 100.0), 0.0), 100.0); - lambda: return min(max(2 * (x + 100.0), 0.0), 100.0);
@@ -3,17 +3,17 @@ text_sensor:
ip_address: ip_address:
name: IP name: IP
icon: mdi:ip icon: mdi:ip
update_interval: 60s # update_interval: 60s
disabled_by_default: true disabled_by_default: true
ssid: ssid:
name: SSID name: SSID
icon: mdi:lan icon: mdi:lan
update_interval: 60s # update_interval: 60s
disabled_by_default: true disabled_by_default: true
bssid: bssid:
name: BSSID name: BSSID
disabled_by_default: true disabled_by_default: true
update_interval: 60s # update_interval: 60s
icon: mdi:router-network icon: mdi:router-network
mac_address: mac_address:
name: Wifi MAC Address name: Wifi MAC Address
@@ -21,8 +21,6 @@ psram:
packages: packages:
network: !include ../common/wifi.yaml network: !include ../common/wifi.yaml
# captive_portal:
# wifi: # wifi:
# # Enable fast connect # # Enable fast connect
# fast_connect: true # fast_connect: true
+1 -1
View File
@@ -1,11 +1,11 @@
esphome: esphome:
captive_portal:
wifi: wifi:
# Enable fast connect # Enable fast connect
fast_connect: true fast_connect: true
min_auth_mode: WPA2 min_auth_mode: WPA2
use_address: ${devicename}.local use_address: ${devicename}.local
#use_address: ${static_ip}
networks: networks:
- ssid: !secret wifi_ssid - ssid: !secret wifi_ssid
-1
View File
@@ -1,5 +1,4 @@
esphome: esphome:
captive_portal:
wifi: wifi:
# Enable fast connect # Enable fast connect
+287 -745
View File
File diff suppressed because it is too large Load Diff
+2 -2
View File
@@ -398,8 +398,8 @@ all_my_speakers:
entities: entities:
- media_player.front_room_hub - media_player.front_room_hub
- media_player.kitchen - media_player.kitchen
- media_player.girls_room_hub - media_player.bedroom_hub
- media_player.master_bedroom_clock - media_player.girls_room_clock
- media_player.bathroom_mini - media_player.bathroom_mini
- media_player.great_room - media_player.great_room
- media_player.computer_area_hub - media_player.computer_area_hub
+82 -72
View File
@@ -2,81 +2,91 @@ title: Dishwasher
path: dishwasher path: dishwasher
icon: mdi:dishwasher icon: mdi:dishwasher
subview: true subview: true
type: sidebar
badges: [] badges: []
cards: type: sections
- type: vertical-stack max_columns: 4
sections:
- type: grid
cards: cards:
- type: history-graph - type: history-graph
entities: entities:
- entity: sensor.pm_dishwasher_w - entity: sensor.pm_dishwasher_w
hours_to_show: 2 name: Dishwasher Watts
grid_options:
- type: vertical-stack columns: full
view_layout: hours_to_show: 3
position: sidebar column_span: 4
- type: grid
cards: cards:
- type: grid - type: tile
cards: grid_options:
- type: tile columns: 3
entity: sensor.dishwasher rows: 2
name: Dishwasher entity: sensor.dishwasher
icon_tap_action: hide_state: false
action: navigate vertical: true
navigation_path: /phone-yaml/dishwasher features_position: bottom
tap_action: - type: tile
action: navigate grid_options:
navigation_path: /phone-yaml/dishwasher columns: 3
show_entity_picture: true rows: 2
vertical: true entity: sensor.washing_machine
- type: tile vertical: true
entity: input_select.washing_machine_fun_status features_position: bottom
name: Washing Machine - type: tile
icon_tap_action: entity: sensor.tumble_dryer
action: navigate vertical: true
navigation_path: /phone-yaml/washing-machine features_position: bottom
tap_action: grid_options:
action: navigate columns: 3
navigation_path: /phone-yaml/washing-machine rows: 2
show_entity_picture: true - type: tile
vertical: true entity: sensor.pm_dishwasher_w
- type: tile name: Watts
entity: input_select.dryer_fun_status vertical: true
name: Dryer features_position: bottom
icon_tap_action: grid_options:
action: navigate columns: 3
navigation_path: /phone-yaml/tumble-dryer rows: 2
tap_action: - type: tile
action: navigate entity: sensor.dishwasher_door_device_temperature
navigation_path: /phone-yaml/tumble-dryer name: Door Temp
show_entity_picture: true vertical: true
vertical: true features_position: bottom
- type: tile grid_options:
entity: binary_sensor.keurig columns: 3
icon_tap_action: rows: 2
action: navigate - type: tile
navigation_path: /phone-yaml/keurig grid_options:
tap_action: columns: 3
action: navigate rows: 2
navigation_path: /phone-yaml/keurig entity: number.dishwasher_run_counter
show_entity_picture: true name: Counter
vertical: true vertical: true
- type: tile features_position: bottom
entity: binary_sensor.stove - type: tile
icon_tap_action: grid_options:
action: navigate columns: 3
navigation_path: /phone-yaml/stove rows: 2
tap_action: entity: number.dishwasher_delay_on
action: navigate name: Start
navigation_path: /phone-yaml/stove vertical: true
show_entity_picture: true features_position: bottom
vertical: true - type: tile
- type: glance entity: timer.dishwasher_off
entities: name: End
- entity: sensor.pm_dishwasher_w vertical: true
name: Watts features_position: bottom
- entity: binary_sensor.dishwasher_door_contact grid_options:
- entity: input_text.dishwasher_runtime columns: 3
name: Runtime rows: 2
- entity: counter.dishwasher - type: tile
name: Cycles entity: timer.dishwasher_watchdog
name: Too Long
state_content: remaining_time
vertical: true
features_position: bottom
grid_options:
columns: 3
rows: 2
column_span: 4
+7
View File
@@ -76,6 +76,13 @@ card:
style: style:
left: 8% left: 8%
top: 95% top: 95%
- type: state-icon
entity: switch.tapo_c560ws_1f31_auto_track
tap_action:
action: toggle
style:
left: 30%
top: 95%
- type: state-icon - type: state-icon
entity: input_boolean.front_room_occupied entity: input_boolean.front_room_occupied
tap_action: tap_action:
+7
View File
@@ -75,6 +75,13 @@ card:
style: style:
left: 8% left: 8%
top: 95% top: 95%
- type: state-icon
entity: switch.tapo_c560ws_1f8d_auto_track
tap_action:
action: toggle
style:
left: 30%
top: 95%
- type: state-icon - type: state-icon
entity: sensor.great_room_person_count entity: sensor.great_room_person_count
style: style:
+3 -3
View File
@@ -20,11 +20,11 @@ cards:
- type: custom:mushroom-title-card - type: custom:mushroom-title-card
title: Current Live Totals title: Current Live Totals
- type: custom:mushroom-title-card - type: custom:mushroom-title-card
title: "{{states('sensor.pm_grid_total_a')}} A" title: "{{states('sensor.pm_grid_a')|float(default=0)|round(2) }} A"
- type: custom:mushroom-title-card - type: custom:mushroom-title-card
title: "{{states('sensor.pm_grid_total_w')}} W" title: "{{states('sensor.pm_grid_w')|float(default=0)|round(2) }} W"
- type: custom:mushroom-title-card - type: custom:mushroom-title-card
title: "{{states('sensor.pm_grid_kwh')}} kWh" title: "{{states('sensor.pm_grid_kwh')|float(default=0)|round(2) }} kWh"
- type: horizontal-stack - type: horizontal-stack
cards: cards:
- type: vertical-stack - type: vertical-stack
+1 -1
View File
@@ -1,6 +1,6 @@
title: AI Cam15 title: AI Cam15
path: ai-cam15 path: ai-cam15
icon: mdi:desktop-classic icon: mdi:microsoft-xbox-controller
type: sidebar type: sidebar
visible: visible:
- user: 24a4bd075e7f41a497dd0390a1dd4a9f - user: 24a4bd075e7f41a497dd0390a1dd4a9f
+1 -1
View File
@@ -308,7 +308,7 @@ cards:
- type: horizontal-stack - type: horizontal-stack
cards: cards:
- type: custom:mini-media-player - type: custom:mini-media-player
entity: media_player.girls_room_hub entity: media_player.girls_room_clock
artwork: cover-fit artwork: cover-fit
- type: vertical-stack - type: vertical-stack
cards: cards:
+1 -1
View File
@@ -90,7 +90,7 @@ cards:
- type: horizontal-stack - type: horizontal-stack
cards: cards:
- type: custom:mini-media-player - type: custom:mini-media-player
entity: media_player.master_bedroom_clock entity: media_player.bedroom_hub
artwork: cover-fit artwork: cover-fit
- type: vertical-stack - type: vertical-stack
cards: cards:
+1 -1
View File
@@ -164,7 +164,7 @@ elements:
#button #5 #button #5
- type: "custom:button-card" - type: "custom:button-card"
color: auto color: auto
entity: media_player.girls_room_hub entity: media_player.girls_room_clock
show_name: false show_name: false
show_entity_picture: true show_entity_picture: true
style: style:
+1 -1
View File
@@ -163,7 +163,7 @@ elements:
#button #5 #button #5
- type: "custom:button-card" - type: "custom:button-card"
color: auto color: auto
entity: media_player.master_bedroom_clock entity: media_player.bedroom_hub
show_name: false show_name: false
show_entity_picture: true show_entity_picture: true
style: style:
@@ -33,7 +33,7 @@ shortcuts:
icon: mdi:home-floor-b icon: mdi:home-floor-b
- name: Nursery - name: Nursery
type: source type: source
id: girls_room_hub id: girls_room_clock
icon: mdi:teddy-bear icon: mdi:teddy-bear
- name: Timeless - name: Timeless
type: playlist type: playlist
+1 -1
View File
@@ -13,7 +13,7 @@ cards:
- !include /config/lovelace/cameras/view-camera-12.yaml - !include /config/lovelace/cameras/view-camera-12.yaml
- !include /config/lovelace/cameras/view-camera-14.yaml - !include /config/lovelace/cameras/view-camera-14.yaml
- !include /config/lovelace/cameras/view-camera-03.yaml - !include /config/lovelace/cameras/view-camera-03.yaml
- !include /config/lovelace/cameras/view-camera-04.yaml - !include /config/lovelace/cameras/view-camera-15.yaml
- !include /config/lovelace/cameras/view-camera-08.yaml - !include /config/lovelace/cameras/view-camera-08.yaml
- !include /config/lovelace/cameras/view-camera-01.yaml - !include /config/lovelace/cameras/view-camera-01.yaml
- !include /config/lovelace/cameras/view-camera-06.yaml - !include /config/lovelace/cameras/view-camera-06.yaml
+6 -2
View File
@@ -64,6 +64,7 @@ cards:
- input_boolean.deck_occupied - input_boolean.deck_occupied
- input_boolean.front_porch_occupied - input_boolean.front_porch_occupied
- input_boolean.furnace_room_occupied - input_boolean.furnace_room_occupied
- input_boolean.deck_occupied
states: states:
- state: "on" - state: "on"
@@ -133,6 +134,8 @@ cards:
- binary_sensor.great_room_person_occupancy - binary_sensor.great_room_person_occupancy
- binary_sensor.kitchen_person_occupancy - binary_sensor.kitchen_person_occupancy
- binary_sensor.master_bedroom_person_occupancy - binary_sensor.master_bedroom_person_occupancy
- binary_sensor.downstairs_person_occupancy
- binary_sensor.upstairs_person_occupancy
- binary_sensor.girls_room_person_occupancy - binary_sensor.girls_room_person_occupancy
- binary_sensor.utility_room_person_occupancy - binary_sensor.utility_room_person_occupancy
- binary_sensor.utility_room_person_occupancy - binary_sensor.utility_room_person_occupancy
@@ -287,9 +290,9 @@ cards:
- media_player.garage - media_player.garage
- media_player.great_room - media_player.great_room
- media_player.kitchen - media_player.kitchen
- media_player.master_bedroom_clock - media_player.girls_room_clock
- media_player.front_room_hub - media_player.front_room_hub
- media_player.girls_room_hub - media_player.bedroom_hub
- media_player.boys_room_clock - media_player.boys_room_clock
- media_player.ma_home_assistant_voice_097b44_media_player - media_player.ma_home_assistant_voice_097b44_media_player
states: states:
@@ -816,6 +819,7 @@ cards:
- camera.frigate_cam08 - camera.frigate_cam08
- camera.frigate_cam12 - camera.frigate_cam12
- camera.frigate_cam14 - camera.frigate_cam14
- camera.frigate_cam15
- camera.frigate_cam18 - camera.frigate_cam18
- camera.frigate_cam19 - camera.frigate_cam19
states: states:
+12 -12
View File
@@ -55,16 +55,8 @@ cards:
artwork: cover artwork: cover
show_source: true show_source: true
- entity: media_player.girls_room_hub - entity: media_player.girls_room_clock
name: Nursery name: Girls Room
#type: media-control
type: custom:mini-media-player
group: true
artwork: cover
show_source: true
- entity: media_player.master_bedroom_clock
name: Master Bedroom
#type: media-control #type: media-control
type: custom:mini-media-player type: custom:mini-media-player
group: true group: true
@@ -79,6 +71,14 @@ cards:
artwork: cover artwork: cover
show_source: true show_source: true
- entity: media_player.bedroom_hub
name: Bedroom
#type: media-control
type: custom:mini-media-player
group: true
artwork: cover
show_source: true
- entity: media_player.computer_area_hub - entity: media_player.computer_area_hub
name: Computer Area name: Computer Area
#type: media-control #type: media-control
@@ -291,10 +291,10 @@ cards:
# id: great_room # id: great_room
# - name: Nursery # - name: Nursery
# type: source # type: source
# id: girls_room_hub # id: girls_room_clock
# - name: Master Bedroom # - name: Master Bedroom
# type: source # type: source
# id: master_bedroom_clock # id: bedroom_hub
# - name: Front Room # - name: Front Room
# type: source # type: source
# id: front_room_hub # id: front_room_hub
+2 -2
View File
@@ -1255,8 +1255,8 @@ cards:
- entity: media_player.garage - entity: media_player.garage
- entity: media_player.great_room - entity: media_player.great_room
- entity: media_player.kitchen - entity: media_player.kitchen
- entity: media_player.master_bedroom_clock - entity: media_player.bedroom_hub
- entity: media_player.girls_room_hub - entity: media_player.girls_room_clock
- entity: device_tracker.amcrest_technologies_24_1f_27 - entity: device_tracker.amcrest_technologies_24_1f_27
name: MBR Left name: MBR Left
icon: mdi:cctv icon: mdi:cctv
+3 -3
View File
@@ -15,7 +15,7 @@ cards:
image: /local/background100.png image: /local/background100.png
elements: elements:
- type: state-label - type: state-label
entity: sensor.pm_grid_total_w entity: sensor.pm_grid_w
style: style:
font-size: 300% font-size: 300%
left: 50% left: 50%
@@ -40,7 +40,7 @@ cards:
update_interval: 30 update_interval: 30
group: true group: true
entities: entities:
- entity: sensor.pm_grid_total_w - entity: sensor.pm_grid_w
show: show:
icon: false icon: false
name: false name: false
@@ -88,7 +88,7 @@ cards:
update_interval: 30 update_interval: 30
group: true group: true
entities: entities:
- entity: sensor.pm_grid_total_w - entity: sensor.pm_grid_w
show: show:
icon: false icon: false
name: false name: false
+1 -1
View File
@@ -12,7 +12,7 @@ cards:
cards: cards:
- type: entities - type: entities
entities: entities:
- entity: sensor.pm_grid_total_w - entity: sensor.pm_grid_w
name: Grid [W] name: Grid [W]
- entity: sensor.pm_grid_kwh - entity: sensor.pm_grid_kwh
name: Grid [kWh] name: Grid [kWh]
+9 -9
View File
@@ -1,9 +1,9 @@
alias: Cam03 on Computer Area Hub # alias: Cam03 on Computer Area Hub
sequence: # sequence:
- action: webrtc.dash_cast # - action: webrtc.dash_cast
data: # data:
entity_id: media_player.computer_area_hub # entity_id: media_player.computer_area_hub
url: rtsp_cam03 # url: rtsp_cam03
force: true # force: true
extra: # extra:
mode: webrtc # mode: webrtc
+9 -9
View File
@@ -1,9 +1,9 @@
alias: Cam03_sub on Computer Area Hub # alias: Cam03_sub on Computer Area Hub
sequence: # sequence:
- action: webrtc.dash_cast # - action: webrtc.dash_cast
data: # data:
entity_id: media_player.computer_area_hub # entity_id: media_player.computer_area_hub
url: cam03_sub # url: cam03_sub
force: true # force: true
extra: # extra:
mode: webrtc # mode: webrtc
+8 -8
View File
@@ -1,8 +1,8 @@
alias: Cam08 on Computer Area Hub # alias: Cam08 on Computer Area Hub
sequence: # sequence:
- action: webrtc.dash_cast # - action: webrtc.dash_cast
data: # data:
entity_id: media_player.computer_area_hub # entity_id: media_player.computer_area_hub
url: cam08_sub # url: cam08_sub
extra: # extra:
mode: webrtc # mode: webrtc
+9 -9
View File
@@ -1,9 +1,9 @@
alias: Cam08 on Front Room Hub # alias: Cam08 on Front Room Hub
sequence: # sequence:
- action: webrtc.dash_cast # - action: webrtc.dash_cast
data: # data:
entity_id: media_player.front_room_hub # entity_id: media_player.front_room_hub
url: cam08_sub # url: cam08_sub
force: true # force: true
extra: # extra:
mode: webrtc # mode: webrtc
+9 -9
View File
@@ -1,9 +1,9 @@
alias: Cam13 on Computer Area Hub # alias: Cam13 on Computer Area Hub
sequence: # sequence:
- action: webrtc.dash_cast # - action: webrtc.dash_cast
data: # data:
entity_id: media_player.computer_area_hub # entity_id: media_player.computer_area_hub
url: cam13_sub # url: cam13_sub
force: true # force: true
extra: # extra:
mode: webrtc # mode: webrtc
+9 -9
View File
@@ -1,9 +1,9 @@
alias: Cam13 on Front Room Hub # alias: Cam13 on Front Room Hub
sequence: # sequence:
- action: webrtc.dash_cast # - action: webrtc.dash_cast
data: # data:
entity_id: media_player.front_room_hub # entity_id: media_player.front_room_hub
url: cam13_sub # url: cam13_sub
force: true # force: true
extra: # extra:
mode: webrtc # mode: webrtc
+9 -9
View File
@@ -1,9 +1,9 @@
alias: Cam19 on Computer Area Hub # alias: Cam19 on Computer Area Hub
sequence: # sequence:
- action: webrtc.dash_cast # - action: webrtc.dash_cast
data: # data:
entity_id: media_player.computer_area_hub # entity_id: media_player.computer_area_hub
url: rtsp://192.168.1.7:8554/cam19_sub # url: rtsp://192.168.1.7:8554/cam19_sub
force: true # force: true
extra: # extra:
mode: webrtc # mode: webrtc
+9 -9
View File
@@ -1,9 +1,9 @@
alias: Cam19 on Front Room Hub # alias: Cam19 on Front Room Hub
sequence: # sequence:
- action: webrtc.dash_cast # - action: webrtc.dash_cast
data: # data:
entity_id: media_player.front_room_hub # entity_id: media_player.front_room_hub
url: cam19_sub # url: cam19_sub
force: true # force: true
extra: # extra:
mode: webrtc # mode: webrtc
+15 -15
View File
@@ -1,17 +1,17 @@
alias: Create temporary camera link # alias: Create temporary camera link
sequence: # sequence:
- variables: # - variables:
link_id: "{% for _ in range(40) %}{{ range(10)|random }}{% endfor %}" # link_id: "{% for _ in range(40) %}{{ range(10)|random }}{% endfor %}"
- action: webrtc.create_link # - action: webrtc.create_link
data: # data:
link_id: "{{ link_id }}" # create a random or permanent link ID # link_id: "{{ link_id }}" # create a random or permanent link ID
# url: rtsp://rtsp:12345678@192.168.1.123:554/av_stream/ch0 # # url: rtsp://rtsp:12345678@192.168.1.123:554/av_stream/ch0
# entity: camera.sonoff # you can use camera entity_id or url # # entity: camera.sonoff # you can use camera entity_id or url
url: rtsp://192.168.1.7:8554/cam03_sub # url: rtsp://192.168.1.7:8554/cam03_sub
open_limit: 1 # how many times a link can be opened (0 - unlimit, 1 - default) # open_limit: 1 # how many times a link can be opened (0 - unlimit, 1 - default)
time_to_live: 60 # how many seconds will the link live (0 - unlimit, 60 - default) # time_to_live: 60 # how many seconds will the link live (0 - unlimit, 60 - default)
- action: persistent_notification.create # - action: persistent_notification.create
data: # data:
message: '<a href="/webrtc/embed?url={{ link_id }}" target="_blank">Open Camera</a>' # message: '<a href="/webrtc/embed?url={{ link_id }}" target="_blank">Open Camera</a>'
+7 -7
View File
@@ -2,19 +2,19 @@ alias: House alert
sequence: sequence:
- action: media_player.turn_on - action: media_player.turn_on
data: data:
entity_id: media_player.master_bedroom_clock entity_id: media_player.bedroom_hub
- action: media_player.volume_set - action: media_player.volume_set
data: data:
entity_id: media_player.master_bedroom_clock entity_id: media_player.bedroom_hub
volume_level: 0.5 volume_level: 0.5
- action: media_player.play_media - action: media_player.play_media
data: data:
entity_id: media_player.master_bedroom_clock entity_id: media_player.bedroom_hub
media_content_id: http://192.168.1.11:8123/local/audio/alarms/Alarm_Clock.mp3 media_content_id: http://192.168.1.11:8123/local/audio/alarms/Alarm_Clock.mp3
media_content_type: music media_content_type: music
- delay: "00:00:10" - delay: "00:00:10"
# Wait for it to stop playing (5 second audio clip) # Wait for it to stop playing (5 second audio clip)
- wait_template: "{{ is_state('media_player.master_bedroom_clock','idle') }}" - wait_template: "{{ is_state('media_player.bedroom_hub','idle') }}"
timeout: "00:00:06" timeout: "00:00:06"
continue_on_timeout: "true" continue_on_timeout: "true"
# Send an audio alert # Send an audio alert
@@ -22,15 +22,15 @@ sequence:
target: target:
entity_id: tts.google_translate_en_com entity_id: tts.google_translate_en_com
data: data:
media_player_entity_id: media_player.master_bedroom_clock media_player_entity_id: media_player.bedroom_hub
message: >- message: >-
{{ (expand('binary_sensor.exterior_doors') | selectattr('state', 'eq', 'off')) | map(attribute='name') | list }} {{ (expand('binary_sensor.exterior_doors') | selectattr('state', 'eq', 'off')) | map(attribute='name') | list }}
- delay: "00:00:02" - delay: "00:00:02"
# Wait for it to stop playing (2 minute timeout) # Wait for it to stop playing (2 minute timeout)
- wait_template: "{{ is_state('media_player.master_bedroom_clock','idle') }}" - wait_template: "{{ is_state('media_player.bedroom_hub','idle') }}"
timeout: "00:02:00" timeout: "00:02:00"
continue_on_timeout: "true" continue_on_timeout: "true"
# Turn off the media players # Turn off the media players
- action: media_player.turn_off - action: media_player.turn_off
data: data:
entity_id: media_player.master_bedroom_clock entity_id: media_player.bedroom_hub
@@ -14,7 +14,7 @@ sequence:
- action: media_player.volume_set - action: media_player.volume_set
target: target:
# entity_id: media_player.ma_home_assistant_voice_097b44_media_player # entity_id: media_player.ma_home_assistant_voice_097b44_media_player
entity_id: media_player.ma_master_bedroom_clock entity_id: media_player.ma_bedroom_hub
data: data:
volume_level: "{{iif(volume>1,1,volume)}}" volume_level: "{{iif(volume>1,1,volume)}}"
@@ -23,7 +23,7 @@ sequence:
entity_id: tts.google_translate_en_com entity_id: tts.google_translate_en_com
data: data:
# media_player_entity_id: media_player.ma_home_assistant_voice_097b44_media_player # media_player_entity_id: media_player.ma_home_assistant_voice_097b44_media_player
media_player_entity_id: media_player.ma_master_bedroom_clock media_player_entity_id: media_player.ma_bedroom_hub
#message: "Pick up the kids at 7 for Donuts with Dads! Its {{ now().strftime('%-I:%M %p') }} so you need to get out of bed and get ready for work and get the kids ready for school" #message: "Pick up the kids at 7 for Donuts with Dads! Its {{ now().strftime('%-I:%M %p') }} so you need to get out of bed and get ready for work and get the kids ready for school"
message: "You have {{ states('todo.local_to_do') }} items on your daily task list: {{ local_todo['todo.local_to_do']['items'] | map(attribute='summary') | list | join(', ') }}" message: "You have {{ states('todo.local_to_do') }} items on your daily task list: {{ local_todo['todo.local_to_do']['items'] | map(attribute='summary') | list | join(', ') }}"
+1 -1
View File
@@ -4,7 +4,7 @@ icon: mdi:music
sequence: sequence:
- action: media_player.select_source - action: media_player.select_source
data: data:
source: girls_room_hub source: girls_room_clock
entity_id: media_player.ytube_music_player entity_id: media_player.ytube_music_player
- action: media_player.shuffle_set - action: media_player.shuffle_set
data: data:
@@ -4,7 +4,7 @@ icon: mdi:music
sequence: sequence:
- action: media_player.select_source - action: media_player.select_source
data: data:
source: girls_room_hub source: girls_room_clock
entity_id: media_player.ytube_music_player entity_id: media_player.ytube_music_player
- action: media_player.shuffle_set - action: media_player.shuffle_set
data: data:
+2 -5
View File
@@ -6,16 +6,13 @@ views:
- !include lovelace/view-surveillance.yaml - !include lovelace/view-surveillance.yaml
- !include lovelace/view-cameras.yaml - !include lovelace/view-cameras.yaml
- !include lovelace/frigate/view-ai-cam08.yaml - !include lovelace/frigate/view-ai-cam08.yaml
- !include lovelace/frigate/view-ai-cam01.yaml
- !include lovelace/frigate/view-ai-cam12.yaml - !include lovelace/frigate/view-ai-cam12.yaml
- !include lovelace/frigate/view-ai-cam14.yaml - !include lovelace/frigate/view-ai-cam14.yaml
- !include lovelace/frigate/view-ai-cam15.yaml
- !include lovelace/frigate/view-ai-cam03.yaml - !include lovelace/frigate/view-ai-cam03.yaml
- !include lovelace/frigate/view-ai-cam15.yaml
- !include lovelace/frigate/view-ai-cam06.yaml - !include lovelace/frigate/view-ai-cam06.yaml
- !include lovelace/frigate/view-ai-cam07.yaml - !include lovelace/frigate/view-ai-cam07.yaml
- !include lovelace/frigate/view-ai-cam01.yaml
- !include lovelace/frigate/view-ai-cam04.yaml - !include lovelace/frigate/view-ai-cam04.yaml
- !include lovelace/frigate/view-ai-cam18.yaml - !include lovelace/frigate/view-ai-cam18.yaml
- !include lovelace/frigate/view-ai-cam19.yaml - !include lovelace/frigate/view-ai-cam19.yaml
+52 -8
View File
@@ -38,9 +38,9 @@
borderopacity="1.0" borderopacity="1.0"
inkscape:pageopacity="0.0" inkscape:pageopacity="0.0"
inkscape:pageshadow="2" inkscape:pageshadow="2"
inkscape:zoom="0.01" inkscape:zoom="0.014142136"
inkscape:cx="29850" inkscape:cx="52149.125"
inkscape:cy="41850" inkscape:cy="22874.904"
inkscape:document-units="px" inkscape:document-units="px"
inkscape:current-layer="layer1" inkscape:current-layer="layer1"
showgrid="true" showgrid="true"
@@ -3526,6 +3526,38 @@
inkscape:label="binary_sensor.frigate_cam03_person_occupancy" inkscape:label="binary_sensor.frigate_cam03_person_occupancy"
transform="rotate(20.586101)" transform="rotate(20.586101)"
sodipodi:arc-type="slice" /> sodipodi:arc-type="slice" />
<g
style="display:inline;overflow:visible;fill:#8270a2;fill-opacity:1;stroke:none"
id="camera.frigate_cam15"
transform="matrix(0.58407329,-0.00406597,0.00406597,0.58407329,768.10459,-17600.35)"
inkscape:label="camera.frigate_cam15">
<svg
id="svg5025-0-6"
version="1.1"
height="24"
width="24"
style="fill:#8270a2;fill-opacity:1;stroke:none">
<path
id="path5023-1-4"
d="M 17,10.5 V 7 A 1,1 0 0 0 16,6 H 4 A 1,1 0 0 0 3,7 v 10 a 1,1 0 0 0 1,1 h 12 a 1,1 0 0 0 1,-1 v -3.5 l 4,4 v -11 z"
inkscape:connector-curvature="0"
style="fill:#8270a2;fill-opacity:1;stroke:none" />
</svg>
</g>
<path
style="display:inline;opacity:0.96;fill:#81c9a7;fill-opacity:1;fill-rule:evenodd;stroke:none;stroke-width:0.203567;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1"
id="binary_sensor.frigate_cam15_person_occupancy"
sodipodi:type="arc"
sodipodi:cx="9500.0059"
sodipodi:cy="14828.762"
sodipodi:rx="9.9992313"
sodipodi:ry="10"
sodipodi:start="1.5707178"
sodipodi:end="3.1397678"
d="m 9500.0066,14838.762 a 9.9992313,10 0 0 1 -10,-9.982 l 9.9993,-0.02 z"
inkscape:label="binary_sensor.frigate_cam15_person_occupancy"
transform="rotate(-144.81275)"
sodipodi:arc-type="slice" />
<path <path
style="display:inline;opacity:0.96;fill:#81c9a7;fill-opacity:1;fill-rule:evenodd;stroke:none;stroke-width:0.203567;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1" style="display:inline;opacity:0.96;fill:#81c9a7;fill-opacity:1;fill-rule:evenodd;stroke:none;stroke-width:0.203567;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1"
id="binary_sensor.frigate_cam06_person_occupancy" id="binary_sensor.frigate_cam06_person_occupancy"
@@ -3825,7 +3857,7 @@
d="m 720.0222,-17679.003 a 4.5,4.5 0 0 1 4.99225,3.941 4.5,4.5 0 0 1 -3.93422,4.997 4.5,4.5 0 0 1 -5.00204,-3.928 4.5,4.5 0 0 1 3.92178,-5.007" d="m 720.0222,-17679.003 a 4.5,4.5 0 0 1 4.99225,3.941 4.5,4.5 0 0 1 -3.93422,4.997 4.5,4.5 0 0 1 -5.00204,-3.928 4.5,4.5 0 0 1 3.92178,-5.007"
inkscape:label="light.storage_room" inkscape:label="light.storage_room"
sodipodi:arc-type="arc" /> sodipodi:arc-type="arc" />
&#10;&#10;&#10;&#10;&#10;&#10;&#10;&#10;&#10;&#10;&#10;&#10;&#10;&#10;&#10;&#10;&#10;&#10;&#10;&#10;&#10;&#10;&#10;&#10;&#10;&#10;&#10;&#10;&#10;&#10;&#10;&#10;&#10;&#10;&#10;&#10;&#10;&#10;&#10;&#10;&#10;&#10;&#10;&#10;&#10;&#10;&#10;&#10;&#10;&#10;&#10;&#10;&#10;&#10;&#10;&#10;&#10;&#10;&#10;&#10;&#10;&#10;&#10;&#10;&#10;&#10;&#10;&#10;&#10;&#10;&#10;&#10;&#10;&#10;&#10;&#10;&#10;&#10;&#10;&#10;&#10;&#10;&#10;&#10;&#10;&#10;&#10;&#10;&#10;&#10;&#10;&#10;&#10;&#10;&#10;&#10;&#10;&#10;&#10;&#10;&#10;&#10;&#10;&#10;&#10; inkscape:label=&quot;light.front_porch_overhead&quot; /&gt;&#10; <rect &#10;&#10;&#10;&#10;&#10;&#10;&#10;&#10;&#10;&#10;&#10;&#10;&#10;&#10;&#10;&#10;&#10;&#10;&#10;&#10;&#10;&#10;&#10;&#10;&#10;&#10;&#10;&#10;&#10;&#10;&#10;&#10;&#10;&#10;&#10;&#10;&#10;&#10;&#10;&#10;&#10;&#10;&#10;&#10;&#10;&#10;&#10;&#10;&#10;&#10;&#10;&#10;&#10;&#10;&#10;&#10;&#10;&#10;&#10;&#10;&#10;&#10;&#10;&#10;&#10;&#10;&#10;&#10;&#10;&#10;&#10;&#10;&#10;&#10;&#10;&#10;&#10;&#10;&#10;&#10;&#10;&#10;&#10;&#10;&#10;&#10;&#10;&#10;&#10;&#10;&#10;&#10;&#10;&#10;&#10;&#10;&#10;&#10;&#10;&#10;&#10;&#10;&#10;&#10;&#10;&#10; inkscape:label=&quot;light.front_porch_overhead&quot; /&gt;&#10; <rect
id="rect12-8-8-9-3-20-4-5-3" id="rect12-8-8-9-3-20-4-5-3"
width="43.5" width="43.5"
height="4.5" height="4.5"
@@ -4155,9 +4187,9 @@
style="fill-rule:evenodd" /> style="fill-rule:evenodd" />
</g> </g>
<g <g
id="media_player.master_bedroom_clock" id="media_player.bedroom_hub"
transform="matrix(0,-0.03802678,0.03802678,0,306.02087,-17394.397)" transform="matrix(0,-0.03802678,0.03802678,0,306.02087,-17394.397)"
inkscape:label="media_player.master_bedroom_clock"> inkscape:label="media_player.bedroom_hub">
<path <path
d="m 235.81,50.402 c -23.977,0 -43.398,19.422 -43.398,43.227 v 372.57 c 0,23.875 19.414,43.398 43.398,43.398 h 228.38 c 23.988,0 43.398,-19.516 43.398,-43.398 V 93.629 c 0,-23.812 -19.422,-43.227 -43.398,-43.227 z m 114.1,34.648 c 22.637,0 41.125,18.359 41.125,40.949 0,22.594 -18.488,41.125 -41.125,41.125 -22.633,0 -40.949,-18.547 -40.949,-41.125 0,-22.578 18.316,-40.949 40.949,-40.949 z m 0,194.77 c 53.941,0 97.824,43.734 97.824,97.477 0,53.801 -43.883,97.477 -97.824,97.477 -53.879,0 -97.648,-43.672 -97.648,-97.477 0,-53.742 43.77,-97.477 97.648,-97.477 z" d="m 235.81,50.402 c -23.977,0 -43.398,19.422 -43.398,43.227 v 372.57 c 0,23.875 19.414,43.398 43.398,43.398 h 228.38 c 23.988,0 43.398,-19.516 43.398,-43.398 V 93.629 c 0,-23.812 -19.422,-43.227 -43.398,-43.227 z m 114.1,34.648 c 22.637,0 41.125,18.359 41.125,40.949 0,22.594 -18.488,41.125 -41.125,41.125 -22.633,0 -40.949,-18.547 -40.949,-41.125 0,-22.578 18.316,-40.949 40.949,-40.949 z m 0,194.77 c 53.941,0 97.824,43.734 97.824,97.477 0,53.801 -43.883,97.477 -97.824,97.477 -53.879,0 -97.648,-43.672 -97.648,-97.477 0,-53.742 43.77,-97.477 97.648,-97.477 z"
id="path70-9-99-1" id="path70-9-99-1"
@@ -4180,9 +4212,9 @@
style="fill-rule:evenodd" /> style="fill-rule:evenodd" />
</g> </g>
<g <g
id="media_player.girls_room_hub" id="media_player.girls_room_clock"
transform="matrix(0.03802678,0,0,0.03802678,586.69139,-17442.661)" transform="matrix(0.03802678,0,0,0.03802678,586.69139,-17442.661)"
inkscape:label="media_player.girls_room_hub"> inkscape:label="media_player.girls_room_clock">
<path <path
d="m 235.81,50.402 c -23.977,0 -43.398,19.422 -43.398,43.227 v 372.57 c 0,23.875 19.414,43.398 43.398,43.398 h 228.38 c 23.988,0 43.398,-19.516 43.398,-43.398 V 93.629 c 0,-23.812 -19.422,-43.227 -43.398,-43.227 z m 114.1,34.648 c 22.637,0 41.125,18.359 41.125,40.949 0,22.594 -18.488,41.125 -41.125,41.125 -22.633,0 -40.949,-18.547 -40.949,-41.125 0,-22.578 18.316,-40.949 40.949,-40.949 z m 0,194.77 c 53.941,0 97.824,43.734 97.824,97.477 0,53.801 -43.883,97.477 -97.824,97.477 -53.879,0 -97.648,-43.672 -97.648,-97.477 0,-53.742 43.77,-97.477 97.648,-97.477 z" d="m 235.81,50.402 c -23.977,0 -43.398,19.422 -43.398,43.227 v 372.57 c 0,23.875 19.414,43.398 43.398,43.398 h 228.38 c 23.988,0 43.398,-19.516 43.398,-43.398 V 93.629 c 0,-23.812 -19.422,-43.227 -43.398,-43.227 z m 114.1,34.648 c 22.637,0 41.125,18.359 41.125,40.949 0,22.594 -18.488,41.125 -41.125,41.125 -22.633,0 -40.949,-18.547 -40.949,-41.125 0,-22.578 18.316,-40.949 40.949,-40.949 z m 0,194.77 c 53.941,0 97.824,43.734 97.824,97.477 0,53.801 -43.883,97.477 -97.824,97.477 -53.879,0 -97.648,-43.672 -97.648,-97.477 0,-53.742 43.77,-97.477 97.648,-97.477 z"
id="path70-9-1" id="path70-9-1"
@@ -4905,6 +4937,18 @@
id="binary_sensor.great_room_person_occupancy" id="binary_sensor.great_room_person_occupancy"
style="stroke-width:0.892033" style="stroke-width:0.892033"
inkscape:label="binary_sensor.great_room_person_occupancy" /> inkscape:label="binary_sensor.great_room_person_occupancy" />
<path
inkscape:connector-curvature="0"
d="m 844.11517,-17608.177 a 1.7840606,1.7840606 0 0 1 1.78106,1.713 1.7840606,1.7840606 0 0 1 -1.78106,1.711 1.7840606,1.7840606 0 0 1 -1.7816,-1.711 1.7840606,1.7840606 0 0 1 1.7816,-1.713 m -1.33634,4.281 h 2.67214 a 1.7840606,1.7840606 0 0 1 1.78105,1.713 v 5.138 h -1.33579 v 6.851 h -3.57087 v -6.851 h -1.33579 v -5.138 a 1.7840606,1.7840606 0 0 1 1.78106,-1.713 z"
id="binary_sensor.downstairs_person_occupancy"
style="stroke-width:0.892033"
inkscape:label="binary_sensor.downstairs_person_occupancy" />
<path
inkscape:connector-curvature="0"
d="m 478.04226,-17659 a 1.7840606,1.7840606 0 0 1 1.78106,1.713 1.7840606,1.7840606 0 0 1 -1.78106,1.711 1.7840606,1.7840606 0 0 1 -1.7816,-1.711 1.7840606,1.7840606 0 0 1 1.7816,-1.713 m -1.33634,4.281 h 2.67214 a 1.7840606,1.7840606 0 0 1 1.78105,1.713 v 5.138 h -1.33579 v 6.851 h -3.57087 v -6.851 h -1.33579 v -5.138 a 1.7840606,1.7840606 0 0 1 1.78106,-1.713 z"
id="binary_sensor.upstairs_person_occupancy"
style="stroke-width:0.892033"
inkscape:label="binary_sensor.upstairs_person_occupancy" />
<path <path
inkscape:connector-curvature="0" inkscape:connector-curvature="0"
d="m 705.78981,-17610.132 a 1.7840606,1.7840606 0 0 1 1.78106,1.713 1.7840606,1.7840606 0 0 1 -1.78106,1.711 1.7840606,1.7840606 0 0 1 -1.7816,-1.711 1.7840606,1.7840606 0 0 1 1.7816,-1.713 m -1.33634,4.281 h 2.67214 a 1.7840606,1.7840606 0 0 1 1.78105,1.713 v 5.138 h -1.33579 v 6.851 H 704 v -6.851 h -1.33579 v -5.138 a 1.7840606,1.7840606 0 0 1 1.78106,-1.713 z" d="m 705.78981,-17610.132 a 1.7840606,1.7840606 0 0 1 1.78106,1.713 1.7840606,1.7840606 0 0 1 -1.78106,1.711 1.7840606,1.7840606 0 0 1 -1.7816,-1.711 1.7840606,1.7840606 0 0 1 1.7816,-1.713 m -1.33634,4.281 h 2.67214 a 1.7840606,1.7840606 0 0 1 1.78105,1.713 v 5.138 h -1.33579 v 6.851 H 704 v -6.851 h -1.33579 v -5.138 a 1.7840606,1.7840606 0 0 1 1.78106,-1.713 z"

Before

Width:  |  Height:  |  Size: 520 KiB

After

Width:  |  Height:  |  Size: 522 KiB

+1
View File
@@ -0,0 +1 @@
# Placeholder to keep default images directory

Before

Width:  |  Height:  |  Size: 40 KiB

After

Width:  |  Height:  |  Size: 40 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 63 KiB

Before

Width:  |  Height:  |  Size: 35 KiB

After

Width:  |  Height:  |  Size: 35 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 40 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 34 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 46 KiB