mirror of
https://github.com/michivonah/esphome-eink-dashboard.git
synced 2025-12-22 21:16:28 +01:00
only refresh screen when lux higher than 5
This commit is contained in:
parent
055baedf38
commit
5f1553a265
2 changed files with 9 additions and 2 deletions
|
|
@ -32,7 +32,7 @@ In the center of the screen the current playing media of one or more speakers ca
|
||||||
At the bottom you find some stats of your Home Assistant instance that you can adjust.
|
At the bottom you find some stats of your Home Assistant instance that you can adjust.
|
||||||
|
|
||||||
## Intelligent Screen Refreshing
|
## Intelligent Screen Refreshing
|
||||||
To reduce the frequency of screen refreshes and to prolong the life of the e-ink screen, the screen will now only refresh when presence is detected.
|
To reduce the frequency of screen refreshes and to prolong the life of the e-ink screen, the screen will now only refresh when presence is detected and the lux in the current room is over 5 to avoid refreshing when the display's content can't be read in terms of brightness (like during night).
|
||||||
|
|
||||||
## Last Refreshed Timestamp
|
## Last Refreshed Timestamp
|
||||||
The last update timestamp can be displayed on the screen itself. No more wondering when the screen was last refreshed!
|
The last update timestamp can be displayed on the screen itself. No more wondering when the screen was last refreshed!
|
||||||
|
|
|
||||||
|
|
@ -168,7 +168,9 @@ time:
|
||||||
then:
|
then:
|
||||||
- if:
|
- if:
|
||||||
condition:
|
condition:
|
||||||
binary_sensor.is_on: presence_detected
|
all:
|
||||||
|
- binary_sensor.is_on: presence_detected
|
||||||
|
- lambda: 'return id(presence_lux).state > 5;'
|
||||||
then:
|
then:
|
||||||
- logger.log: "Sensor data updated and activity in home detected: Refreshing display..."
|
- logger.log: "Sensor data updated and activity in home detected: Refreshing display..."
|
||||||
- script.execute: update_screen
|
- script.execute: update_screen
|
||||||
|
|
@ -208,6 +210,11 @@ sensor:
|
||||||
entity_category: "diagnostic"
|
entity_category: "diagnostic"
|
||||||
update_interval: 60s
|
update_interval: 60s
|
||||||
|
|
||||||
|
# LUX value used for deciding if display should be updated (only if it can be read)
|
||||||
|
- platform: homeassistant
|
||||||
|
entity_id: <YOUR-LUX-SENSOR>
|
||||||
|
id: presence_lux
|
||||||
|
|
||||||
- platform: homeassistant
|
- platform: homeassistant
|
||||||
entity_id: weather.<YOUR-WEATHER>
|
entity_id: weather.<YOUR-WEATHER>
|
||||||
attribute: temperature
|
attribute: temperature
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue