Add fire tablet

This commit is contained in:
Georgi Gardev
2023-09-18 17:58:13 +03:00
parent 97f6df0f0e
commit e822c331e3
11 changed files with 278 additions and 15 deletions

View File

@@ -61,6 +61,12 @@ lovelace:
icon: mdi:tablet-dashboard
show_in_sidebar: false
filename: hallway-lovelace.yaml
lovelace-fire:
mode: yaml
title: Fire Dashboard
icon: mdi:tablet-dashboard
show_in_sidebar: false
filename: fire-lovelace.yaml
lovelace-kitchen:
mode: yaml
title: Kitchen Dashboard
@@ -88,9 +94,9 @@ logger:
#
# https://www.home-assistant.io/integrations/discovery
discovery:
ignore:
- yeelight
# discovery:
# ignore:
# - yeelight
# https://www.home-assistant.io/integrations/ffmpeg
ffmpeg:

11
config/fire-lovelace.yaml Normal file
View File

@@ -0,0 +1,11 @@
decluttering_templates: !include_dir_merge_named lovelace/decluttering_templates
button_card_templates: !include_dir_merge_named lovelace/button_card_templates
title: Sarah
views:
- title: Sarah
path: fire_dashboard
icon: mdi:tablet-dashboard
background: '#333'
panel: true
cards: !include lovelace/fire_dashboard/fire_dashboard.yaml

View File

@@ -1,9 +1,6 @@
decluttering_templates: !include_dir_merge_named lovelace/decluttering_templates
button_card_templates: !include_dir_merge_named lovelace/button_card_templates
kiosk_mode:
hide_header: true
title: Floorplan
views:
- title: Floorplan

View File

@@ -1,9 +1,9 @@
decluttering_templates: !include_dir_merge_named lovelace/decluttering_templates
button_card_templates: !include_dir_merge_named lovelace/button_card_templates
kiosk_mode:
kiosk: false
hide_overflow: true
# kiosk_mode:
# kiosk: false
# hide_overflow: true
title: Sarah
views:

View File

@@ -0,0 +1,225 @@
- type: custom:mod-card
style:
layout-card:
$:
horizontal-layout:
$:
.: |
#columns {
padding-left: 10px;
margin: 0 20px;
grid-gap: 20px;
}
card:
type: custom:layout-card
layout_type: custom:horizontal-layout
layout:
max_cols: 2
cards:
# Column 1
- type: vertical-stack
cards:
- type: 'custom:simple-clock-card'
hide_seconds: true
font_size: 4rem
paddingTop_size: 0px
paddingBottom_size: 0px
style: |
ha-card {
background: none;
box-shadow: none;
margin-top: 30px;
text-align: left;
}
- type: horizontal-stack
cards:
- type: custom:button-card
template: v3_chip_person
entity: input_boolean.georgi_home
entity_picture: /local/images/people/georgi.jpg
name: Georgi
- type: custom:button-card
template: v3_chip_person
entity: input_boolean.player_2_home
entity_picture: /local/images/people/maya.jpg
name: Maya
- type: custom:button-card
template: v3_chip
entity: sensor.average_temperature
icon: mdi:thermometer
- type: custom:button-card
template: v3_chip
entity: sensor.average_humidity
icon: mdi:water-percent
- type: horizontal-stack
cards:
- type: custom:button-card
template: v3_chip_name
entity: group.all_motion_sensors
icon: |
[[[
return entity.state === 'off' ? 'mdi:motion-sensor-off' : 'mdi:motion-sensor';
]]]
name: Motion
tap_action:
action: more-info
- type: custom:button-card
template: v3_chip_entity_count
entity: sensor.open_window_count
variables:
entity_type: window
icon: |
[[[
return entity.state === 0 ? 'mdi:window-closed' : 'mdi:window-open';
]]]
- type: custom:button-card
template: v3_chip_entity_count
entity: sensor.open_door_count
variables:
entity_type: door
icon: |
[[[
return entity.state === 0 ? 'mdi:door-closed' : 'mdi:door-open';
]]]
- type: custom:decluttering-card
template: v3_section_title
variables:
- title: Modes & Devices
- type: horizontal-stack
cards:
- type: custom:button-card
template: v3_tablet_button
entity: light.fire1_screen
name: Display
icon: mdi:brightness-6
state_display: "[[[ return `${Math.floor(entity.attributes.brightness / 255 * 100)}%` ]]]"
tap_action:
action: call-service
service: script.fire_toggle_brightness
- type: custom:button-card
template: [v3_button, v3_tablet_button]
entity: input_select.bedroom_mode
name: Mode
icon: mdi:bed
tap_action:
action: call-service
service: script.toggle_bedroom_mode
- type: custom:button-card
template: [v3_button_tv, v3_tablet_button]
entity: media_player.living_room_tv
name: TV
- type: custom:button-card
template: [v3_button_ac, v3_tablet_button]
entity: climate.toshiba_ac
name: AC
tap_action:
action: call-service
service: script.toshiba_ac_toggle
- type: horizontal-stack
cards:
- type: custom:button-card
template: v3_tablet_button
entity: media_player.master_bedroom
name: Sonos Bedroom
hold_action:
action: call-service
service: media_player.media_play_pause
service_data:
entity_id: media_player.master_bedroom
- type: custom:button-card
template: [v3_button_cover, v3_tablet_button]
entity: cover.living_room
name: LR Blinds
tap_action:
action: call-service
service: script.toggle_living_room_cover
- type: custom:button-card
template: [v3_button_purifier, v3_tablet_button]
entity: fan.philips_airpurifier
name: Air Purifier
- type: custom:button-card
template: v3_button_brita_water
variables:
long_state: false
styles:
card:
- width: 100px
- height: 100px
- border-radius: 16px
icon:
- top: 4px
- left: 12px
- width: 20px
- height: 20px
- --mdc-icon-size: 20px
state:
- bottom: 4px
- left: 12px
name:
- left: 12px
- bottom: 22px
- width: 60px
- font-size: 13px
# Column 2
- type: vertical-stack
cards:
- type: custom:decluttering-card
template: stacked-weather
- type: custom:decluttering-card
template: v3_section_title
variables:
- title: Lights
- type: horizontal-stack
cards:
- type: custom:button-card
template: v3_xs_button
entity: light.living_room
name: Living room
- type: custom:button-card
template: v3_xs_button
entity: light.living_room_main
name: Main
- type: custom:button-card
template: v3_xs_button
entity: light.hue_ambiance_7
- type: custom:button-card
template: v3_xs_button
entity: light.living_room_ambient
name: Ambient
- type: custom:button-card
template: v3_xs_button
entity: light.hallway_main
name: Hallway
- type: horizontal-stack
cards:
- type: custom:button-card
template: v3_xs_button
entity: light.master_bedroom
name: Bedroom
- type: custom:button-card
template: v3_xs_button
entity: light.master_bedroom_main
name: Main
- type: custom:button-card
template: v3_xs_button
entity: light.bedside
name: Bedside
- type: custom:button-card
template: v3_xs_button
entity: light.kitchen
name: Kitchen
- type: custom:button-card
template: v3_xs_button
entity: light.hallway_entrance
name: Entrance
- !include ../popup_cards.yaml

View File

@@ -107,6 +107,10 @@
template: v3_button
entity: light.browser_hallway
name: Hallway Dashboard
- type: custom:button-card
template: v3_button
entity: light.fire1_screen
name: Fire Dashboard
- type: custom:button-card
template: v3_button
entity: light.browser_kitchen

View File

@@ -16,8 +16,8 @@
type: module
- url: /hacsfiles/hass-bha-icons/hass-bha-icons.js
type: module
- url: /hacsfiles/kiosk-mode/kiosk-mode.js
type: module
# - url: /hacsfiles/kiosk-mode/kiosk-mode.js
# type: module
- url: /hacsfiles/light-entity-card/light-entity-card.js
type: module
- url: /hacsfiles/lovelace-card-mod/card-mod.js

View File

@@ -0,0 +1,14 @@
script:
fire_toggle_brightness:
sequence:
- service: light.turn_on
entity_id: light.fire1_screen
data_template:
brightness: >
{% if state_attr('light.fire1_screen', 'brightness') == 255 %}
30
{% elif state_attr('light.fire1_screen', 'brightness') <= 35 %}
128
{% else %}
255
{% endif %}

View File

@@ -2,13 +2,20 @@
browser_mod:
script:
browser_fire_low:
sequence:
- service: light.turn_on
entity_id:
- light.fire1_screen
data:
brightness_pct: 30
browser_hallway_low:
sequence:
- service: light.turn_on
entity_id:
- light.browser_hallway
data:
brightness_pct: 10
brightness_pct: 20
browser_kitchen_low:
sequence:
- service: light.turn_on
@@ -20,6 +27,7 @@ script:
sequence:
- service: script.browser_hallway_low
- service: script.browser_kitchen_low
- service: script.browser_fire_low

View File

@@ -23,6 +23,7 @@ script:
- light.hallway_main
- light.browser_kitchen
- light.browser_hallway
- light.fire1_screen
- light.living_room_ambient
- light.bedside
data:

View File

@@ -5,9 +5,6 @@ swipe_nav:
swipe_amount: 50
skip_tabs: 6
kiosk_mode:
hide_overflow: true
title: Home
views:
- title: World