diff --git a/larry/larry.yaml b/larry/larry.yaml index bde6b71..1df9140 100644 --- a/larry/larry.yaml +++ b/larry/larry.yaml @@ -8,6 +8,7 @@ substitutions: external_media_player: your_media_player ##change this to your external media player enity_id: do not include media_player. home_assistant_host: http://nookie.nex:8123 ##change to the full url or IP of your HA server including port + home_assistant_ip: "192.168.50.36" tts_voice_speed: "16000" #options #nabu casa "24000" #piper "16000" elevenlabs "44100" must include quotes #################### ON DEVICE WAKE WORDS ####################################### @@ -139,6 +140,22 @@ wifi: captive_portal: +http_request: + useragent: esphome/device + timeout: 10s + verify_ssl: false # if you're using HTTP or self-signed HTTPS + +online_image: + - id: ewie_live_feed_image + format: JPEG + type: RGB565 + url: '${home_assistant_host}/static/icons/ohf.svg' + resize: "320x240" + on_download_finished: + - component.update: s3_box_lcd + on_error: + - logger.log: "❌ Failed to load camera snapshot" + time: - platform: homeassistant id: ha_time @@ -881,6 +898,10 @@ text_sensor: entity_id: weather.forecast_home id: ha_weather_condition + - platform: homeassistant + id: ewie_image_path + entity_id: camera.ewie_live_ansicht + attribute: entity_picture i2s_audio: @@ -2026,7 +2047,7 @@ display: it.printf(240, 200, id(icon_font_55), light_blue, TextAlign::CENTER, "\U000F0591"); } else if (condition == "windy") { it.printf(240, 200, id(icon_font_55), light_blue, TextAlign::CENTER, "\U000F059D"); - } else if (condition == "clearnight") { + } else if (condition == "clear-night") { it.printf(240, 200, id(icon_font_55), light_blue, TextAlign::CENTER, "\U000F0594"); } else { it.printf(240, 200, id(icon_font_55), green, TextAlign::CENTER, "\U000F07A6"); // default: cannabis @@ -2363,6 +2384,10 @@ display: it.printf(255, 30, id(icon_font_55), green, TextAlign::CENTER, "\U000F1828"); it.printf(255, 70, id(my_font3), green, TextAlign::CENTER, "Armed"); } + - id: video_feed_page ### load picture + lambda: |- + it.fill(id(purple)); + it.image(0, 0, id(ewie_live_feed_image)); i2c: - id: bus_a sda: GPIO08 @@ -2805,13 +2830,20 @@ binary_sensor: y_min: 90 y_max: 170 #### make sure that the following 4 lines are uncommented by removing the prefixed '#' ### - # on_click: - # min_length: 10ms - # max_length: 500ms - # then: - #### add your action here - make sure to uncomment the following line by removing the prefixed '#' and keep these below your action ##### - - # - component.update: s3_box_lcd + # MARK: ewie button + on_click: + min_length: 10ms + max_length: 500ms + then: + - lambda: |- + std::string host = "http://${home_assistant_ip}"; + std::string path = id(ewie_image_path).state; + std::string full_url = host + path; + ESP_LOGD("video_feed_page", "Current url: %s", full_url); + id(ewie_live_feed_image).set_url(full_url); + - component.update: ewie_live_feed_image + - display.page.show: video_feed_page + - component.update: s3_box_lcd - platform: touchscreen page_id: climate_page