20240410-21:12

This commit is contained in:
2024-04-10 21:12:15 +02:00
parent 523d1143f3
commit a863b212ed
10 changed files with 3222 additions and 2031 deletions

View File

@@ -15,7 +15,7 @@ homeassistant:
trusted_networks:
- 192.168.2.0/24
trusted_users:
- 192.168.2.170: lenovo
192.168.2.170: d60f15dc903c4db087bfe493d3fba434
allow_bypass_login: true
- type: homeassistant
#d60f15dc903c4db087bfe493d3fba434

View File

@@ -36,8 +36,8 @@ sensor:
weather_condition_0: >
{% set cond0 = daily["weather.forecast_home"].forecast[0].condition %}
{% set next_setting = as_timestamp(state_attr('sun.sun', 'next_setting')) %}
{% set next_rising = as_timestamp(state_attr('sun.sun', 'next_rising')) %}
# {% set next_setting = as_timestamp(state_attr('sun.sun', 'next_setting')) %}
# {% set next_rising = as_timestamp(state_attr('sun.sun', 'next_rising')) %}
{% set cond0_time = as_timestamp(daily["weather.forecast_home"].forecast[0].datetime) %}
{% if cond0_time > next_setting and cond0_time < next_rising %}
{% if cond0 == 'sunny' %} night {% elif cond0 == 'partlycloudy' %} night-partly-cloudy {% else %} {{ cond0 }} {% endif %}
@@ -46,13 +46,12 @@ sensor:
{% endif %}
weather_temperature_0: >
{{ daily["weather.forecast_home"].forecast[0].temperature | round }}
#{{ daily["weather.forecast_home"].forecast[0].temperature | round }}
weather_timestamp_0: >
{{ as_timestamp(daily["weather.forecast_home"].forecast[0].datetime) | timestamp_custom('%a') }}
weather_condition_1: >
{% set cond1 = daily["weather.forecast_home"].forecast[1].condition %}
{% set next_setting = as_timestamp(state_attr('sun.sun', 'next_setting')) %}
{% set next_rising = as_timestamp(state_attr('sun.sun', 'next_rising')) %}
# {% set next_setting = as_timestamp(state_attr('sun.sun', 'next_setting')) %}
# {% set next_rising = as_timestamp(state_attr('sun.sun', 'next_rising')) %}
{% set cond1_time = as_timestamp(daily["weather.forecast_home"].forecast[1].datetime) %}
{% if cond1_time > next_setting and cond1_time < next_rising %}
{% if cond1 == 'sunny' %} night {% elif cond1 == 'partlycloudy' %} night-partly-cloudy {% else %} {{ cond1 }} {% endif %}
@@ -65,8 +64,8 @@ sensor:
{{ as_timestamp(daily["weather.forecast_home"].forecast[1].datetime) | timestamp_custom('%a') }}
weather_condition_2: >
{% set cond2 = daily["weather.forecast_home"].forecast[2].condition %}
{% set next_setting = as_timestamp(state_attr('sun.sun', 'next_setting')) %}
{% set next_rising = as_timestamp(state_attr('sun.sun', 'next_rising')) %}
# {% set next_setting = as_timestamp(state_attr('sun.sun', 'next_setting')) %}
# {% set next_rising = as_timestamp(state_attr('sun.sun', 'next_rising')) %}
{% set cond2_time = as_timestamp(daily["weather.forecast_home"].forecast[2].datetime) %}
{% if cond2_time > next_setting and cond2_time < next_rising %}
{% if cond2 == 'sunny' %} night {% elif cond2 == 'partlycloudy' %} night-partly-cloudy {% else %} {{ cond2 }} {% endif %}
@@ -79,8 +78,8 @@ sensor:
{{ as_timestamp(daily["weather.forecast_home"].forecast[2].datetime) | timestamp_custom('%a') }}
weather_condition_3: >
{% set cond3 = daily["weather.forecast_home"].forecast[3].condition %}
{% set next_setting = as_timestamp(state_attr('sun.sun', 'next_setting')) %}
{% set next_rising = as_timestamp(state_attr('sun.sun', 'next_rising')) %}
# {% set next_setting = as_timestamp(state_attr('sun.sun', 'next_setting')) %}
# {% set next_rising = as_timestamp(state_attr('sun.sun', 'next_rising')) %}
{% set cond3_time = as_timestamp(daily["weather.forecast_home"].forecast[3].datetime) %}
{% if cond3_time > next_setting and cond3_time < next_rising %}
{% if cond3 == 'sunny' %} night {% elif cond3 == 'partlycloudy' %} night-partly-cloudy {% else %} {{ cond3 }} {% endif %}
@@ -111,8 +110,8 @@ sensor:
{{ state_attr('Sun.sun', 'next_rising') }}
sun_next_setting: >
{{ state_attr('Sun.sun', 'next_setting') }}
moon_phase_icon: >
{{ state_attr('sensor.moon_phase', 'icon') }}
# moon_phase_icon: >
# {{ state_attr('sensor.moon_phase', 'icon') }}
media_playing_status: >
{{ states('media_player.keuken') }}

View File

@@ -124,15 +124,6 @@ font:
id: font_month
size: 40
# - file: fonts/materialdesignicons-webfont.ttf
# id: font_wifi
# size: 20
# glyphs:
# - "\U000F091F"
# - "\U000F0922"
# - "\U000F0925"
# - "\U000F0928"
# - "\U000F092B"
# Include Material Design Icons font
# Thanks to https://community.home-assistant.io/t/display-materialdesign-icons-on-esphome-attached-to-screen/199790/16
@@ -173,18 +164,6 @@ font:
- "\U000f010b" # mdi-car
- "\U000f0819" # trash
# - file: 'fonts/materialdesignicons-webfont.ttf'
# id: font_mdi_medlarge
# size: 60
# glyphs:
# - "\U000f0f64" # new moon
# - "\U000f0f67" # mdi-moon-waxing-crescent
# - "\U000F0F61" # mdi-moon-first-quarter
# - "\U000F0F68" # mdi-moon-waxing-gibbous
# - "\U000F0F62" # mdi-moon-full
# - "\U000F0F66" # mdi-moon-waning-gibbous
# - "\U000F0F63" # mdi-moon-last-quarter
# - "\U000F0F65" # mdi-moon-waning-crescent
- file: 'fonts/materialdesignicons-webfont.ttf'
id: font_mdi_medium
size: 36
@@ -203,7 +182,7 @@ sensor:
id: weather_temperature
on_value:
then:
- lambda: 'id(data_updated) = true;'
- lambda: 'id(data_updated) = true;'
- !include { file: sensors/homeassistant.yaml, vars: { id: weather_temperature_0, entity_id: sensor.e_ink_display_data }}
- !include { file: sensors/homeassistant.yaml, vars: { id: weather_temperature_1, entity_id: sensor.e_ink_display_data }}
@@ -246,9 +225,9 @@ sensor:
unit_of_measurement: "refreshes"
text_sensor:
- platform: homeassistant
entity_id: weather.forecast_home
id: weather_state
# - platform: homeassistant
# entity_id: weather.forecast_home
# id: weather_state
- !include { file: sensors/homeassistant.yaml, vars: { id: weather_condition_now, entity_id: sensor.e_ink_display_data }}
- !include { file: sensors/homeassistant.yaml, vars: { id: weather_condition_0, entity_id: sensor.e_ink_display_data}}
@@ -265,19 +244,6 @@ text_sensor:
- !include { file: sensors/homeassistant.yaml, vars: { id: travel_ASML_name, entity_id: sensor.e_ink_display_data }}
- !include { file: sensors/homeassistant.yaml, vars: { id: travel_euretco_name, entity_id: sensor.e_ink_display_data }}
- platform: homeassistant
entity_id: sensor.moon_phase
#attribute: icon
id: moon_phase
on_value:
then:
- lambda: 'id(data_updated) = true;'
- platform: homeassistant
entity_id: sensor.moon
id: moon
internal: true
# Sunrise
- platform: sun
type: sunrise
@@ -295,24 +261,6 @@ text_sensor:
then:
- lambda: 'id(data_updated) = true;'
- platform: wifi_info
ssid:
name: "${device_name} Connected SSID"
id: ssid
icon: mdi:wifi-strength-2
entity_category: diagnostic
bssid:
name: "${device_name} Connected BSSID"
id: bssid
icon: mdi:wifi-strength-2
entity_category: diagnostic
mac_address:
name: "${device_name} WiFi Mac Address"
id: macaddress
icon: mdi:wifi-strength-2
entity_category: diagnostic
- platform: sun
id: sunrise
@@ -361,12 +309,13 @@ display:
- platform: waveshare_epaper
cs_pin: GPIO27
dc_pin: GPIO16
busy_pin: GPIO25
busy_pin:
number: 25
inverted: True
reset_pin: GPIO26
model: 7.50in-bV2
#model: 7.50inv2b
#model: 7.50inv2
#model: 7.50inV2alt
reset_duration: 2ms
model: 7.50in-bv2-rb
#model: 7.50in-bV2
update_interval: 30min
id: eink_display
rotation: 90°
@@ -379,39 +328,9 @@ display:
int wifi_x_a = xres-x_pad;
int wifi_y_a = yres-y_pad+2;
// Fill background in black.
it.fill(COLOR_OFF);
// wifi strength
// if (id(sensor_wifi_signal).has_state())
// {
// if (id(sensor_wifi_signal).state >= -50) {
// //Excellent
// it.print(wifi_x_a, wifi_y_a, id(font_wifi), TextAlign::BASELINE_RIGHT, "󰤨");
// ESP_LOGI("WiFi", "Excellent");
// } else if (id(sensor_wifi_signal).state >= -60) {
// //Good
// it.print(wifi_x_a, wifi_y_a, id(font_wifi), TextAlign::BASELINE_RIGHT, "󰤥");
// ESP_LOGI("WiFi", "Good");
// } else if (id(sensor_wifi_signal).state >= -67) {
// //Fair
// it.print(wifi_x_a, wifi_y_a, id(font_wifi), TextAlign::BASELINE_RIGHT, "󰤢");
// ESP_LOGI("WiFi", "Fair");
// } else if (id(sensor_wifi_signal).state >= -70) {
// //Weak
// it.print(wifi_x_a, wifi_y_a, id(font_wifi), TextAlign::BASELINE_RIGHT, "󰤟");
// ESP_LOGI("WiFi", "Weak");
// } else {
// //Unlikely working signal
// it.print(wifi_x_a, wifi_y_a, id(font_wifi), TextAlign::BASELINE_RIGHT, "󰤫");
// ESP_LOGI("WiFi", "Unlikely");
// }
//}
// clock section
int clk_yoffset = 50;
int clk_xoffset = 310;
@@ -437,7 +356,7 @@ display:
if(id(sun_sunset).has_state ()) {
it.printf(385, sry_offset, id(font_small_bold), TextAlign::CENTER_RIGHT, "%s", id(sun_sunset).state.c_str());
}
// Moonphae
// Moonphase
//it.printf(265, sry_offset, id(font_mdi_medlarge), TextAlign::CENTER, "%s", moon_icon_map[id(moon_phase).state.c_str()].c_str());
it.line(30, sry_offset+30, 420, sry_offset+30);

View File

@@ -2,38 +2,6 @@
#include <iostream>
// #define ICON_stop "\U000F04DB"
// #define ICON_play "\U000F040A"
// #define ICON_pause "\U000F03E4"
// std::string playbackStatusToIcon(bool playing, bool paused) {
// if (playing) return ICON_play;
// else if (paused) return ICON_pause;
// else return ICON_stop;
// }
// #define ICON_moon_first_quarter "\U000F0F61"
// #define ICON_moon_full "\U000F0F62"
// #define ICON_moon_last_quarter "\U000F0F63"
// #define ICON_moon_new "\U000F0F64"
// #define ICON_moon_waning_crescent "\U000F0F65"
// #define ICON_moon_waning_gibbous "\U000F0F66"
// #define ICON_moon_waxing_crescent "\U000F0F67"
// #define ICON_moon_waxing_gibbous "\U000F0F68"
// std::string moonToIcon(std::string moonPhase)
// {
// if (moonPhase == "new_moon") return ICON_moon_new;
// if (moonPhase == "waxing_crescent") return ICON_moon_waxing_crescent;
// if (moonPhase == "first_quarter") return ICON_moon_first_quarter;
// if (moonPhase == "waxing_gibbous") return ICON_moon_waxing_gibbous;
// if (moonPhase == "full_moon") return ICON_moon_full;
// if (moonPhase == "waning_gibbous") return ICON_moon_waning_gibbous;
// if (moonPhase == "last_quarter") return ICON_moon_last_quarter;
// if (moonPhase == "waning_crescent") return ICON_moon_waning_crescent;
// return "";
// }
// Map weather states to MDI characters.
std::map<std::string, std::string> weather_icon_map
{
@@ -70,76 +38,67 @@ std::map<std::string, std::string> weather_icon_map
{"car", "\U000f010b"},
{"trash", "\U000F0819"},
};
// std::map<std::string, std::string> moon_icon_map
// #define ICON_w_clear_night "\U000F0594"
// #define ICON_w_cloudy "\U000F0590"
// #define ICON_w_fog "\U000F0591"
// #define ICON_w_hail "\U000F0592"
// #define ICON_w_lightning "\U000F0593"
// #define ICON_w_lightning_rainy "\U000F067E"
// #define ICON_w_night_partly_cloudy "\U000F0F31"
// #define ICON_w_partly_cloudy "\U000F0595"
// #define ICON_w_pouring "\U000F0596"
// #define ICON_w_rainy "\U000F0597"
// #define ICON_w_snowy "\U000F0F36"
// #define ICON_w_snowy_rainy "\U000F067F"
// #define ICON_w_sunny "\U000F0599"
// #define ICON_w_windy "\U000F059D"
// #define ICON_w_windy_variant "\U000F059E"
// #define ICON_w_exceptional "\U000F0F38"
// std::string conditionToIcon(std::string condition, bool daytime)
// {
// { "mdi:moon-waxing-crescent", "\U000f0f67" },
// { "mdi:moon-first-quarter", "\U000F0F61" },
// { "mdi:moon-waxing-gibbous", "\U000F0F68" },
// { "mdi:moon-full", "\U000F0F62" },
// { "mdi:moon-waning-gibbous", "\U000F0F66" },
// { "mdi:moon-last-quarter", "\U000F0F63" },
// { "mdi:moon-waning-crescent", "\U000F0F65" },
// };
#define ICON_w_clear_night "\U000F0594"
#define ICON_w_cloudy "\U000F0590"
#define ICON_w_fog "\U000F0591"
#define ICON_w_hail "\U000F0592"
#define ICON_w_lightning "\U000F0593"
#define ICON_w_lightning_rainy "\U000F067E"
#define ICON_w_night_partly_cloudy "\U000F0F31"
#define ICON_w_partly_cloudy "\U000F0595"
#define ICON_w_pouring "\U000F0596"
#define ICON_w_rainy "\U000F0597"
#define ICON_w_snowy "\U000F0F36"
#define ICON_w_snowy_rainy "\U000F067F"
#define ICON_w_sunny "\U000F0599"
#define ICON_w_windy "\U000F059D"
#define ICON_w_windy_variant "\U000F059E"
#define ICON_w_exceptional "\U000F0F38"
std::string conditionToIcon(std::string condition, bool daytime)
{
if (condition == "clear") return ICON_w_clear_night;
if (condition == "clear-night") return ICON_w_clear_night;
if (condition == "cloudy") return ICON_w_cloudy;
if (condition == "dust") return ICON_w_fog;
if (condition == "dusty") return ICON_w_fog;
if (condition == "fog") return ICON_w_fog;
if (condition == "frost") return ICON_w_snowy;
if (condition == "hail") return ICON_w_hail;
if (condition == "haze") return ICON_w_fog;
if (condition == "hazy") return ICON_w_fog;
if (condition == "heavy_shower") return ICON_w_rainy;
if (condition == "heavy_showers") return ICON_w_rainy;
if (condition == "light_rain") return ICON_w_rainy;
if (condition == "light_showers") return ICON_w_rainy;
if (condition == "light_shower") return ICON_w_rainy;
if (condition == "lightning") return ICON_w_lightning;
if (condition == "lightning-rainy") return ICON_w_lightning_rainy;
if (condition == "mostly_sunny") return ICON_w_sunny;
if (condition == "night") return ICON_w_clear_night;
if (condition == "partlycloudy" && !daytime) return ICON_w_night_partly_cloudy;
if (condition == "partlycloudy" && daytime) return ICON_w_partly_cloudy;
if (condition == "partly_cloudy" && !daytime) return ICON_w_night_partly_cloudy;
if (condition == "partly_cloudy" && daytime) return ICON_w_partly_cloudy;
if (condition == "pouring") return ICON_w_pouring;
if (condition == "rain") return ICON_w_rainy;
if (condition == "rainy") return ICON_w_rainy;
if (condition == "shower") return ICON_w_rainy;
if (condition == "showers") return ICON_w_rainy;
if (condition == "snow") return ICON_w_snowy;
if (condition == "snowy") return ICON_w_snowy;
if (condition == "snowy-rainy") return ICON_w_snowy_rainy;
if (condition == "storm") return ICON_w_lightning_rainy;
if (condition == "storms") return ICON_w_lightning_rainy;
if (condition == "sunny") return ICON_w_sunny;
if (condition == "wind") return ICON_w_windy;
if (condition == "windy") return ICON_w_windy;
if (condition == "windy-variant") return ICON_w_windy_variant;
if (condition == "exceptional") return ICON_w_exceptional;
return "";
}
// if (condition == "clear") return ICON_w_clear_night;
// if (condition == "clear-night") return ICON_w_clear_night;
// if (condition == "cloudy") return ICON_w_cloudy;
// if (condition == "dust") return ICON_w_fog;
// if (condition == "dusty") return ICON_w_fog;
// if (condition == "fog") return ICON_w_fog;
// if (condition == "frost") return ICON_w_snowy;
// if (condition == "hail") return ICON_w_hail;
// if (condition == "haze") return ICON_w_fog;
// if (condition == "hazy") return ICON_w_fog;
// if (condition == "heavy_shower") return ICON_w_rainy;
// if (condition == "heavy_showers") return ICON_w_rainy;
// if (condition == "light_rain") return ICON_w_rainy;
// if (condition == "light_showers") return ICON_w_rainy;
// if (condition == "light_shower") return ICON_w_rainy;
// if (condition == "lightning") return ICON_w_lightning;
// if (condition == "lightning-rainy") return ICON_w_lightning_rainy;
// if (condition == "mostly_sunny") return ICON_w_sunny;
// if (condition == "night") return ICON_w_clear_night;
// if (condition == "partlycloudy" && !daytime) return ICON_w_night_partly_cloudy;
// if (condition == "partlycloudy" && daytime) return ICON_w_partly_cloudy;
// if (condition == "partly_cloudy" && !daytime) return ICON_w_night_partly_cloudy;
// if (condition == "partly_cloudy" && daytime) return ICON_w_partly_cloudy;
// if (condition == "pouring") return ICON_w_pouring;
// if (condition == "rain") return ICON_w_rainy;
// if (condition == "rainy") return ICON_w_rainy;
// if (condition == "shower") return ICON_w_rainy;
// if (condition == "showers") return ICON_w_rainy;
// if (condition == "snow") return ICON_w_snowy;
// if (condition == "snowy") return ICON_w_snowy;
// if (condition == "snowy-rainy") return ICON_w_snowy_rainy;
// if (condition == "storm") return ICON_w_lightning_rainy;
// if (condition == "storms") return ICON_w_lightning_rainy;
// if (condition == "sunny") return ICON_w_sunny;
// if (condition == "wind") return ICON_w_windy;
// if (condition == "windy") return ICON_w_windy;
// if (condition == "windy-variant") return ICON_w_windy_variant;
// if (condition == "exceptional") return ICON_w_exceptional;
// return "";
// }

File diff suppressed because it is too large Load Diff

View File

@@ -3333,6 +3333,7 @@ const Ts={},Os=He(class extends Ye{constructor(t){if(super(t),t.type!==Be&&t.typ
@closed=${t=>t.stopPropagation()}
.value=${null!=t?t:""}
naturalMenuWidth
fixedMenuPosition
>
${e.map((t=>Y`
<mwc-list-item .value=${t}>
@@ -3392,7 +3393,7 @@ const Ts={},Os=He(class extends Ye{constructor(t){if(super(t),t.type!==Be&&t.typ
flex: 1;
--mdc-theme-primary: rgb(var(--rgb-state-entity));
}
`]}};bm=n([pt(pm)],bm);const ym=`${Nl}-template-card`,xm=`${ym}-editor`;Pl({type:ym,name:"Mushroom Template Card",description:"Card for custom rendering with templates"});const wm=["icon","icon_color","badge_color","badge_icon","primary","secondary","picture"];let km=class extends jl{constructor(){super(...arguments),this._templateResults={},this._unsubRenderTemplates=new Map,this._inGrid=!1}static async getConfigElement(){return await Promise.resolve().then((function(){return Cp})),document.createElement(xm)}static async getStubConfig(t){return{type:`custom:${ym}`,primary:"Hello, {{user}}",secondary:"How are you?",icon:"mdi:home"}}getCardSize(){let t=1;if(!this._config)return t;return"vertical"===$l(this._config).layout&&(t+=1),t}getGridSize(){const{grid_columns:t,grid_rows:e}=this.getLayoutOptions();return[t,e]}getLayoutOptions(){this._inGrid=!0;const t={grid_columns:2,grid_rows:1};if(!this._config)return t;const e=$l(this._config);return"vertical"===e.layout&&(t.grid_rows+=1),"horizontal"===e.layout&&(t.grid_columns=4),t}setConfig(t){wm.forEach((e=>{var i,o;(null===(i=this._config)||void 0===i?void 0:i[e])===t[e]&&(null===(o=this._config)||void 0===o?void 0:o.entity)==t.entity||this._tryDisconnectKey(e)})),this._config=Object.assign({tap_action:{action:"toggle"},hold_action:{action:"more-info"}},t)}connectedCallback(){super.connectedCallback(),this._tryConnect()}disconnectedCallback(){this._tryDisconnect()}_handleAction(t){Ge(this,this.hass,this._config,t.detail.action)}isTemplate(t){var e;const i=null===(e=this._config)||void 0===e?void 0:e[t];return null==i?void 0:i.includes("{")}getValue(t){var e,i,o;return this.isTemplate(t)?null===(i=null===(e=this._templateResults[t])||void 0===e?void 0:e.result)||void 0===i?void 0:i.toString():null===(o=this._config)||void 0===o?void 0:o[t]}render(){if(!this._config||!this.hass)return G;const t=this.getValue("icon"),e=this.getValue("icon_color"),i=this.getValue("badge_icon"),o=this.getValue("badge_color"),n=this.getValue("primary"),r=this.getValue("secondary"),a=this.getValue("picture"),l=this._config.multiline_secondary,s=Ie(this.hass),c=$l({fill_container:this._config.fill_container,layout:this._config.layout,icon_type:Boolean(a)?"entity-picture":Boolean(t)?"icon":"none",primary_info:Boolean(n)?"name":"none",secondary_info:Boolean(r)?"state":"none"}),d=fs(t);return Y`
`]}};bm=n([pt(pm)],bm);const ym=`${Nl}-template-card`,xm=`${ym}-editor`;Pl({type:ym,name:"Mushroom Template Card",description:"Card for custom rendering with templates"});const wm=["icon","icon_color","badge_color","badge_icon","primary","secondary","picture"];let km=class extends jl{constructor(){super(...arguments),this._templateResults={},this._unsubRenderTemplates=new Map,this._inGrid=!1}static async getConfigElement(){return await Promise.resolve().then((function(){return Cp})),document.createElement(xm)}static async getStubConfig(t){return{type:`custom:${ym}`,primary:"Hello, {{user}}",secondary:"How are you?",icon:"mdi:home"}}getCardSize(){let t=1;if(!this._config)return t;return"vertical"===$l(this._config).layout&&(t+=1),t}getGridSize(){const{grid_columns:t,grid_rows:e}=this.getLayoutOptions();return[t,e]}getLayoutOptions(){var t;this._inGrid=!0;const e={grid_columns:2,grid_rows:1};if(!this._config)return e;const i=$l(this._config);return"vertical"===i.layout&&(e.grid_rows+=1),"horizontal"===i.layout&&(e.grid_columns=4),(null===(t=this._config)||void 0===t?void 0:t.multiline_secondary)&&(e.grid_rows=void 0),e}setConfig(t){wm.forEach((e=>{var i,o;(null===(i=this._config)||void 0===i?void 0:i[e])===t[e]&&(null===(o=this._config)||void 0===o?void 0:o.entity)==t.entity||this._tryDisconnectKey(e)})),this._config=Object.assign({tap_action:{action:"toggle"},hold_action:{action:"more-info"}},t)}connectedCallback(){super.connectedCallback(),this._tryConnect()}disconnectedCallback(){this._tryDisconnect()}_handleAction(t){Ge(this,this.hass,this._config,t.detail.action)}isTemplate(t){var e;const i=null===(e=this._config)||void 0===e?void 0:e[t];return null==i?void 0:i.includes("{")}getValue(t){var e,i,o;return this.isTemplate(t)?null===(i=null===(e=this._templateResults[t])||void 0===e?void 0:e.result)||void 0===i?void 0:i.toString():null===(o=this._config)||void 0===o?void 0:o[t]}render(){if(!this._config||!this.hass)return G;const t=this.getValue("icon"),e=this.getValue("icon_color"),i=this.getValue("badge_icon"),o=this.getValue("badge_color"),n=this.getValue("primary"),r=this.getValue("secondary"),a=this.getValue("picture"),l=this._config.multiline_secondary,s=Ie(this.hass),c=$l({fill_container:this._config.fill_container,layout:this._config.layout,icon_type:Boolean(a)?"entity-picture":Boolean(t)?"icon":"none",primary_info:Boolean(n)?"name":"none",secondary_info:Boolean(r)?"state":"none"}),d=fs(t);return Y`
<ha-card class=${Zr({"fill-container":c.fill_container})}>
<mushroom-card .appearance=${c} ?rtl=${s}>
<mushroom-state-item
@@ -3660,7 +3661,7 @@ const Ts={},Os=He(class extends Ye{constructor(t){if(super(t),t.type!==Be&&t.typ
mushroom-vacuum-commands-control {
flex: 1;
}
`]}};Um=n([pt(jm)],Um),console.info("%c🍄 Mushroom 🍄 - 3.5.2","color: #ef5350; font-weight: 700;");const Hm=Ce({tap_action:$e(ni),hold_action:$e(ni),double_tap_action:$e(ni)}),Ym=t=>[{name:"tap_action",selector:{"ui-action":{actions:t}}},{name:"hold_action",selector:{"ui-action":{actions:t}}},{name:"double_tap_action",selector:{"ui-action":{actions:t}}}],Wm=Ce({layout:$e(Se([we("horizontal"),we("vertical"),we("default")])),fill_container:$e(ye()),primary_info:$e(xe(ol)),secondary_info:$e(xe(ol)),icon_type:$e(xe(nl))}),Xm=[{type:"grid",name:"",schema:[{name:"layout",selector:{mush_layout:{}}},{name:"fill_container",selector:{boolean:{}}}]},{type:"grid",name:"",schema:[{name:"primary_info",selector:{mush_info:{}}},{name:"secondary_info",selector:{mush_info:{}}},{name:"icon_type",selector:{mush_icon_type:{}}}]}],Gm=["icon_color","layout","fill_container","primary_info","secondary_info","icon_type","content_info","use_entity_picture","collapsible_controls","icon_animation"],Km=Ce({entity:$e(Ee()),name:$e(Ee()),icon:$e(Ee())}),qm=Ce({index:$e(ke()),view_index:$e(ke()),view_layout:ve(),type:Ee()}),Zm=fe(qm,fe(Km,Wm,Hm),Ce({states:$e(be()),show_keypad:$e(ye())})),Jm=["more-info","navigate","url","call-service","assist","none"],Qm=["armed_home","armed_away","armed_night","armed_vacation","armed_custom_bypass"],tp=["show_keypad"],ep=Tt((t=>[{name:"entity",selector:{entity:{domain:Vl}}},{name:"name",selector:{text:{}}},{name:"icon",selector:{icon:{}},context:{icon_entity:"entity"}},...Xm,{type:"multi_select",name:"states",options:Qm.map((e=>[e,t(`ui.card.alarm_control_panel.${e.replace("armed","arm")}`)]))},{name:"show_keypad",selector:{boolean:{}}},...Ym(Jm)]));let ip=class extends jl{constructor(){super(...arguments),this._computeLabel=t=>{const e=Oo(this.hass);return Gm.includes(t.name)?e(`editor.card.generic.${t.name}`):tp.includes(t.name)?e(`editor.card.alarm_control_panel.${t.name}`):"states"===t.name?this.hass.localize("ui.panel.lovelace.editor.card.alarm-panel.available_states"):this.hass.localize(`ui.panel.lovelace.editor.card.generic.${t.name}`)}}connectedCallback(){super.connectedCallback(),vs()}setConfig(t){me(t,Zm),this._config=t}render(){if(!this.hass||!this._config)return G;const t=ep(this.hass.localize);return Y`
`]}};Um=n([pt(jm)],Um),console.info("%c🍄 Mushroom 🍄 - 3.5.4","color: #ef5350; font-weight: 700;");const Hm=Ce({tap_action:$e(ni),hold_action:$e(ni),double_tap_action:$e(ni)}),Ym=t=>[{name:"tap_action",selector:{"ui-action":{actions:t}}},{name:"hold_action",selector:{"ui-action":{actions:t}}},{name:"double_tap_action",selector:{"ui-action":{actions:t}}}],Wm=Ce({layout:$e(Se([we("horizontal"),we("vertical"),we("default")])),fill_container:$e(ye()),primary_info:$e(xe(ol)),secondary_info:$e(xe(ol)),icon_type:$e(xe(nl))}),Xm=[{type:"grid",name:"",schema:[{name:"layout",selector:{mush_layout:{}}},{name:"fill_container",selector:{boolean:{}}}]},{type:"grid",name:"",schema:[{name:"primary_info",selector:{mush_info:{}}},{name:"secondary_info",selector:{mush_info:{}}},{name:"icon_type",selector:{mush_icon_type:{}}}]}],Gm=["icon_color","layout","fill_container","primary_info","secondary_info","icon_type","content_info","use_entity_picture","collapsible_controls","icon_animation"],Km=Ce({entity:$e(Ee()),name:$e(Ee()),icon:$e(Ee())}),qm=Ce({index:$e(ke()),view_index:$e(ke()),view_layout:ve(),type:Ee(),layout_options:ve()}),Zm=fe(qm,fe(Km,Wm,Hm),Ce({states:$e(be()),show_keypad:$e(ye())})),Jm=["more-info","navigate","url","call-service","assist","none"],Qm=["armed_home","armed_away","armed_night","armed_vacation","armed_custom_bypass"],tp=["show_keypad"],ep=Tt((t=>[{name:"entity",selector:{entity:{domain:Vl}}},{name:"name",selector:{text:{}}},{name:"icon",selector:{icon:{}},context:{icon_entity:"entity"}},...Xm,{type:"multi_select",name:"states",options:Qm.map((e=>[e,t(`ui.card.alarm_control_panel.${e.replace("armed","arm")}`)]))},{name:"show_keypad",selector:{boolean:{}}},...Ym(Jm)]));let ip=class extends jl{constructor(){super(...arguments),this._computeLabel=t=>{const e=Oo(this.hass);return Gm.includes(t.name)?e(`editor.card.generic.${t.name}`):tp.includes(t.name)?e(`editor.card.alarm_control_panel.${t.name}`):"states"===t.name?this.hass.localize("ui.panel.lovelace.editor.card.alarm-panel.available_states"):this.hass.localize(`ui.panel.lovelace.editor.card.generic.${t.name}`)}}connectedCallback(){super.connectedCallback(),vs()}setConfig(t){me(t,Zm),this._config=t}render(){if(!this.hass||!this._config)return G;const t=ep(this.hass.localize);return Y`
<ha-form
.hass=${this.hass}
.data=${this._config}

View File

@@ -172,12 +172,10 @@ devices:
friendly_name: IKEA particles
'0xa4c138ece0125a19':
friendly_name: temperatuur Tim
'0xa4c138151c812a2e':
friendly_name: Temperatuur Luuk
'0x00158d0008ad9560':
friendly_name: Knoppen Luuk
'0x00158d00023783a0':
friendly_name: '0x00158d00023783a0'
'0xa4c138151c812a2e':
friendly_name: temperatuur luuk
advanced:
log_level: info
homeassistant_legacy_entity_attributes: false

File diff suppressed because it is too large Load Diff

View File

@@ -3,10 +3,10 @@
"voltage": 2995,
"battery": 97,
"power_outage_count": 50672,
"temperature": 22.17,
"humidity": 46.7,
"pressure": 1026.1,
"linkquality": 172
"temperature": 20.73,
"humidity": 45.81,
"pressure": 1026.3,
"linkquality": 176
},
"0x000d6ffffeb8d4b5": {
"update": {
@@ -16,7 +16,7 @@
},
"update_available": false,
"state": "ON",
"linkquality": 108,
"linkquality": 116,
"power_on_behavior": "previous"
},
"0x1c34f1fffeac6a84": {
@@ -28,7 +28,7 @@
"latest_version": 69638
},
"update_available": false,
"linkquality": 196
"linkquality": 116
},
"0xcc86ecfffec1bf03": {
"color_mode": "color_temp",
@@ -39,23 +39,23 @@
},
"update_available": false,
"brightness": 89,
"state": "OFF",
"state": "ON",
"color": {
"x": 0.5245,
"y": 0.4136
},
"color_temp": 495,
"linkquality": 116
"linkquality": 176
},
"0x00178801067e17c7": {
"state": "OFF",
"state": "ON",
"update": {
"state": "idle",
"installed_version": 16785666,
"latest_version": 16785666
},
"update_available": false,
"linkquality": 172,
"linkquality": 176,
"brightness": 89
},
"0xcc86ecfffec1bf69": {
@@ -67,7 +67,7 @@
},
"update_available": false,
"brightness": 89,
"state": "OFF",
"state": "ON",
"linkquality": 100,
"color_temp": 495,
"color": {
@@ -83,9 +83,9 @@
"latest_version": 18
},
"update_available": false,
"linkquality": 156,
"linkquality": 152,
"brightness": 89,
"state": "OFF",
"state": "ON",
"color_temp": 495,
"color": {
"x": 0.5245,
@@ -94,7 +94,7 @@
},
"0xcc86ecfffec1bf5c": {
"color_mode": "color_temp",
"state": "OFF",
"state": "ON",
"color_temp": 495,
"color": {
"x": 0.5245,
@@ -112,8 +112,8 @@
},
"0xcc86ecfffec1bf11": {
"color_mode": "color_temp",
"state": "OFF",
"linkquality": 172,
"state": "ON",
"linkquality": 176,
"update": {
"state": "idle",
"installed_version": 17,
@@ -135,9 +135,9 @@
"latest_version": 18
},
"update_available": false,
"linkquality": 120,
"linkquality": 116,
"brightness": 89,
"state": "OFF",
"state": "ON",
"color_temp": 495,
"color": {
"x": 0.5245,
@@ -152,13 +152,13 @@
"latest_version": 17
},
"update_available": false,
"state": "OFF",
"state": "ON",
"color_temp": 495,
"color": {
"x": 0.5245,
"y": 0.4136
},
"linkquality": 172,
"linkquality": 176,
"brightness": 89
},
"0x385b44fffe42a33d": {
@@ -169,8 +169,8 @@
"latest_version": 18
},
"update_available": false,
"state": "OFF",
"linkquality": 112,
"state": "ON",
"linkquality": 108,
"brightness": 89,
"color_temp": 495,
"color": {
@@ -180,14 +180,14 @@
},
"0xcc86ecfffec1bf51": {
"brightness": 89,
"state": "OFF",
"state": "ON",
"update": {
"state": "idle",
"installed_version": 17,
"latest_version": 17
},
"update_available": false,
"linkquality": 172,
"linkquality": 116,
"color_mode": "color_temp",
"color_temp": 495,
"color": {
@@ -209,12 +209,12 @@
},
"0x00158d000572837e": {
"occupancy": false,
"illuminance": 4,
"illuminance_lux": 4,
"linkquality": 236,
"illuminance": 3,
"illuminance_lux": 3,
"linkquality": 240,
"voltage": 3035,
"battery": 100,
"device_temperature": 18,
"device_temperature": 19,
"power_outage_count": 60
},
"0xdc8e95fffefec1f0": {
@@ -225,7 +225,7 @@
"latest_version": 268572245
},
"update_available": false,
"linkquality": 128,
"linkquality": 164,
"state": "OFF",
"brightness": 127,
"color": {
@@ -247,7 +247,7 @@
"illuminance_above_threshold": false
},
"0x0017880108fb4c8e": {
"state": "ON",
"state": "OFF",
"update": {
"state": "idle",
"installed_version": 16781314,
@@ -263,13 +263,13 @@
"latest_version": 587765297
},
"update_available": false,
"state": "ON",
"linkquality": 132,
"state": "OFF",
"linkquality": 136,
"power_on_behavior": "previous"
},
"0x804b50fffe80a266": {
"state": "ON",
"linkquality": 120,
"state": "OFF",
"linkquality": 84,
"update": {
"state": "idle",
"installed_version": 587753009,
@@ -280,12 +280,12 @@
},
"0x00158d000450bc4d": {
"occupancy": false,
"illuminance": 89,
"illuminance_lux": 89,
"linkquality": 144,
"illuminance": 3,
"illuminance_lux": 3,
"linkquality": 156,
"voltage": 3025,
"battery": 100,
"device_temperature": 20,
"device_temperature": 21,
"power_outage_count": 64
},
"0x003c84fffe32c0c0": {
@@ -295,7 +295,7 @@
"latest_version": 581
},
"update_available": false,
"linkquality": 144
"linkquality": 148
},
"0x5c0272fffe873332": {
"update": {
@@ -304,8 +304,8 @@
"latest_version": 587765297
},
"update_available": false,
"linkquality": 116,
"state": "ON",
"linkquality": 136,
"state": "OFF",
"power_on_behavior": "previous"
},
"0x00158d0001b95c9f": {
@@ -319,24 +319,24 @@
"0xdc8e95fffe5578fb": {
"state_l1": "OFF",
"state_l2": "OFF",
"linkquality": 208
"linkquality": 176
},
"0x00158d0002e6c64d": {
"voltage": 3035,
"battery": 100,
"device_temperature": 22,
"device_temperature": 20,
"power_outage_count": 26,
"contact": true,
"linkquality": 132,
"trigger_count": 0
"linkquality": 152,
"trigger_count": 1
},
"0x00158d0001b91af7": {
"contact": false,
"voltage": 3085,
"battery": 100,
"device_temperature": 28,
"device_temperature": 24,
"power_outage_count": 312,
"linkquality": 120,
"linkquality": 136,
"trigger_count": 0
},
"0x00158d0002c9572b": {
@@ -356,9 +356,9 @@
"latest_version": 17
},
"update_available": false,
"state": "OFF",
"state": "ON",
"brightness": 89,
"linkquality": 196,
"linkquality": 204,
"color_temp": 495,
"color": {
"x": 0.5245,
@@ -367,22 +367,22 @@
},
"0xbc33acfffe6f8eca": {
"battery": 37.5,
"linkquality": 132
"linkquality": 200
},
"0x60a423fffe28320f": {
"linkquality": 172,
"linkquality": 176,
"battery": 50
},
"0x540f57fffe96bd00": {
"color_mode": "color_temp",
"linkquality": 136,
"linkquality": 176,
"update": {
"state": "idle",
"installed_version": 23,
"latest_version": 23
},
"update_available": false,
"state": "OFF",
"state": "ON",
"color_temp": 495,
"color": {
"x": 0.5245,
@@ -392,14 +392,14 @@
},
"0x84b4dbfffeb28b4c": {
"color_mode": "color_temp",
"state": "OFF",
"state": "ON",
"update": {
"state": "idle",
"installed_version": 20,
"latest_version": 20
},
"update_available": false,
"linkquality": 172,
"linkquality": 176,
"color_temp": 495,
"color": {
"x": 0.5245,
@@ -411,9 +411,9 @@
"voltage": 2885,
"battery": 23,
"power_outage_count": 21453,
"temperature": 17.6,
"humidity": 44.35,
"pressure": 1025.6,
"temperature": 18.01,
"humidity": 49.3,
"pressure": 1025.8,
"linkquality": 156
},
"0x00124b00246d8628": {
@@ -430,7 +430,7 @@
"state": "ON",
"color_temp": 380,
"power_on_behavior": "previous",
"linkquality": 140,
"linkquality": 144,
"color_options": {
"execute_if_off": true
},
@@ -451,14 +451,14 @@
"state": "OFF",
"brightness": 31,
"color_temp": 454,
"linkquality": 116
"linkquality": 132
},
"0x90ab96fffe99035d": {
"humidity": 50,
"pm25": 2,
"voc_index": 97,
"humidity": 49,
"pm25": 1,
"voc_index": 132,
"temperature": 20,
"linkquality": 204,
"linkquality": 200,
"update": {
"state": "idle",
"installed_version": 16777233,
@@ -470,35 +470,35 @@
"battery": 100,
"device_temperature": 23,
"power_outage_count": 158,
"linkquality": 112
"linkquality": 116
},
"0xbc33acfffe1a21da": {
"brightness": 18,
"state": "OFF",
"brightness": 165,
"state": "ON",
"update": {
"state": "idle",
"installed_version": 587806257,
"latest_version": 587806257
},
"linkquality": 196
"linkquality": 204
},
"0xa4c138ece0125a19": {
"temperature": 18.1,
"humidity": 43.8,
"temperature": 18.2,
"humidity": 48.3,
"battery": 48,
"linkquality": 132
},
"0xa4c138151c812a2e": {
"temperature": 19.5,
"humidity": 71.6,
"battery": 100,
"linkquality": 76
"linkquality": 136
},
"0x00158d0008ad9560": {
"voltage": 3035,
"battery": 100,
"device_temperature": 18,
"device_temperature": 19,
"power_outage_count": 66,
"linkquality": 172
"linkquality": 180
},
"0xa4c138151c812a2e": {
"temperature": 17.9,
"humidity": 52.4,
"battery": 100,
"linkquality": 156
}
}