diff --git a/.vscode/tasks.json b/.vscode/tasks.json index 07ea919..451af39 100644 --- a/.vscode/tasks.json +++ b/.vscode/tasks.json @@ -30,6 +30,15 @@ "focus": true } }, + { + "label": "upload", + "type": "shell", + "command": "./bin/upload", + "problemMatcher": [], + "presentation": { + "focus": true + } + }, { "label": "logs", "type": "shell", diff --git a/config/lovelace/home_dashboard/09_system.yaml b/config/lovelace/home_dashboard/09_system.yaml index 89b40a4..bab6507 100644 --- a/config/lovelace/home_dashboard/09_system.yaml +++ b/config/lovelace/home_dashboard/09_system.yaml @@ -22,6 +22,7 @@ cards: title: Automations show_header_toggle: false entities: + # Presence - type: custom:fold-entity-row head: type: custom:dummy-entity-row @@ -37,12 +38,14 @@ cards: - type: divider + # Lighting - type: custom:fold-entity-row head: type: custom:dummy-entity-row entity: sun.sun name: Lighting icon: mdi:lightbulb + tap_action: none entities: - automation.lighting_turn_on_ceiling_lights_after_sunset - automation.lighting_turn_off_all_lights_after_sunrise @@ -58,12 +61,14 @@ cards: - type: divider + # Music - type: custom:fold-entity-row head: type: custom:dummy-entity-row entity: sun.sun name: Music icon: mdi:music-note + tap_action: none entities: - automation.music_play_pause_on_magic_cube_knock - automation.music_volume_down_on_magic_cube_rotate_left @@ -71,12 +76,14 @@ cards: - type: divider + # Media - type: custom:fold-entity-row head: type: custom:dummy-entity-row entity: sun.sun name: Media icon: mdi:play-box-outline + tap_action: none entities: - automation.tv_join_beam_to_sonos_group_when_off - automation.tv_plex_setup_house_for_plex @@ -87,6 +94,20 @@ cards: - type: divider + # Notifications + - type: custom:fold-entity-row + head: + type: custom:dummy-entity-row + entity: sun.sun + name: Notifications + icon: mdi:play-box-outline + tap_action: none + entities: + - automation.notification_phone_battery_low + + - type: divider + + # Sleep Mode - type: custom:fold-entity-row head: type: custom:dummy-entity-row @@ -101,6 +122,7 @@ cards: - type: divider + # Guest Mode - type: custom:fold-entity-row head: type: custom:dummy-entity-row @@ -113,6 +135,7 @@ cards: - type: divider + # Domestina - type: custom:fold-entity-row head: type: custom:dummy-entity-row @@ -125,24 +148,28 @@ cards: - type: divider + # Security - type: custom:fold-entity-row head: type: custom:dummy-entity-row entity: sun.sun name: Security icon: mdi:shield-home + tap_action: none entities: - automation.security_door_opened_while_away - automation.camera_startup - type: divider + # System - type: custom:fold-entity-row head: type: custom:dummy-entity-row entity: sun.sun icon: mdi:cogs name: System + tap_action: none entities: - automation.system_announce_start - automation.system_telegram_announce_status diff --git a/config/lovelace/home_dashboard/11_test.yaml b/config/lovelace/home_dashboard/11_test.yaml index 097f2ca..9ee60e8 100644 --- a/config/lovelace/home_dashboard/11_test.yaml +++ b/config/lovelace/home_dashboard/11_test.yaml @@ -1,11 +1,23 @@ title: test path: test cards: - - type: custom:button-card - name: Reload themes - tap_action: - action: call-service - service: frontend.reload_themes + - type: horizontal-stack + cards: + - type: custom:button-card + name: Reload themes + tap_action: + action: call-service + service: frontend.reload_themes + - type: custom:button-card + name: Reload automations + tap_action: + action: call-service + service: automation.reload + - type: custom:button-card + name: Reload scripts + tap_action: + action: call-service + service: script.reload - type: entities entities: diff --git a/config/packages/modules/notification.yaml b/config/packages/modules/notification.yaml new file mode 100644 index 0000000..58873a9 --- /dev/null +++ b/config/packages/modules/notification.yaml @@ -0,0 +1,21 @@ +automation: + - alias: Notification · Phone battery low + trigger: + platform: template + value_template: "{{ states('sensor.carbon_battery_level') | int < 10 }}" + condition: + condition: state + entity_id: sensor.carbon_battery_state + state: "Not Charging" + action: + service: script.say + data_template: + title: "❕*Notification Module*" + message: >- + + {{ + [ + "Hey, just wanted to let you know your phone needs charging!", + "Hey, your phone is running low on battery, put it on the charger!" + ] | random + }} diff --git a/config/packages/modules/speech.yaml b/config/packages/modules/speech.yaml index 9a8e9c8..4f665b1 100644 --- a/config/packages/modules/speech.yaml +++ b/config/packages/modules/speech.yaml @@ -36,7 +36,7 @@ script: # Combine partials for speech message. - service: script.say_discretely data_template: - volume_level: "{{ volume_level }}" # For sonos only + title: "{{ title | default('💬 *Speech Module*') }}" message: >- {%- if partials is defined -%} {%- for partial in partials -%} @@ -65,9 +65,8 @@ script: {% endif %} {% endif %} data_template: - title: "💬 *Speech Module*" # For telegram only + title: "{{ title | default('💬 *Speech Module*') }}" # For telegram only message: "{{ message }}" - volume_level: "{{ volume_level }}" # For sonos only sonos_blast: alias: Speech · Sonos blast