4 Commits

Author SHA1 Message Date
Commander1024 4e46f60b65 Updated refresh logic to only rerender calendar, when contents changed. 2026-07-13 15:31:39 +02:00
ESPHome Device Builder 9e7684e294 Edit epaperframe.yaml 2026-07-13 14:33:32 +02:00
Commander1024 818b06f3d7 Merge branch 'epaperframe-gpt5.6' 2026-07-13 14:28:28 +02:00
Commander1024 35e7f81224 Base epaperframe config with Kinderzimmer 2026-07-11 19:14:03 +02:00
+31 -6
View File
@@ -22,6 +22,8 @@ esp32:
board: nodemcu-32s board: nodemcu-32s
framework: framework:
type: esp-idf type: esp-idf
advanced:
minimum_chip_revision: "3.0"
wifi: wifi:
ssid: "Voltage-legacy" ssid: "Voltage-legacy"
@@ -49,6 +51,13 @@ api:
# Include ArduinoJson support for the compact calendar event feed. # Include ArduinoJson support for the compact calendar event feed.
json: json:
# Avoid refreshing the panel when Home Assistant republishes unchanged calendar data.
globals:
- id: last_rendered_calendar_entries
type: std::string
restore_value: no
initial_value: '""'
ota: ota:
platform: esphome platform: esphome
password: !secret ota password: !secret ota
@@ -220,6 +229,17 @@ text_sensor:
entity_id: sensor.epaper_kalenderdaten entity_id: sensor.epaper_kalenderdaten
attribute: entries attribute: entries
id: calendar_entries id: calendar_entries
on_value:
then:
- if:
condition:
and:
- display.is_displaying_page: calendar
- lambda: return x != id(last_rendered_calendar_entries);
then:
- lambda: id(last_rendered_calendar_entries) = x;
- component.update: epaper
# Home Assistant selects one quote per day from its local quote library. # Home Assistant selects one quote per day from its local quote library.
- platform: homeassistant - platform: homeassistant
@@ -241,14 +261,19 @@ time:
- output.turn_on: power_key - output.turn_on: power_key
- delay: 0.5s - delay: 0.5s
- output.turn_off: power_key - output.turn_off: power_key
# Every 10 minutes # Refresh environmental readings every 10 minutes. The calendar page is
# redrawn only when its event feed actually changes.
- seconds: 0 - seconds: 0
minutes: /10 minutes: /10
then: then:
- logger.log: - if:
level: INFO condition:
format: "Timer based screen refresh" display.is_displaying_page: environment
- component.update: epaper then:
- logger.log:
level: INFO
format: "Timer based environment screen refresh"
- component.update: epaper
# Font definitions # Font definitions
font: font:
@@ -1289,7 +1314,7 @@ display:
it.strftime(614, 380, id(footer_font), TextAlign::BASELINE_RIGHT, it.strftime(614, 380, id(footer_font), TextAlign::BASELINE_RIGHT,
"Aktualisiert um %d.%m.%Y %H:%M", now); "Aktualisiert um %d.%m.%Y %H:%M", now);
/* WiFi Signal Strenght */ /* WiFi Signal strength */
if(id(wifisignal).has_state()) { if(id(wifisignal).has_state()) {
int x = 630; int x = 630;
int y = 384; int y = 384;