Use ESPHome with e-ink Displays to blend in with your home decor!

The thing you are seeing makes sense.
The statement next_rising < next_setting in the if-statement will get true after sun-set-time. This is because, after sunset (in your case 5.02pm) the sensor next_setting will update to the sun-set-time for the following day.

Try this for the first if-statement:

{% if ( cond1_time < next_rising and next_rising < next_setting ) or ( cond1_time > next_setting and cond1_time < next_rising ) %}
1 Like

thanks. it works perfectly now :slight_smile:

1 Like

Was to be expected :slight_smile:
As soon as the time is greater than the sun-set-time (next_setting), the next_setting-sensor will update to the sun-set-time for tomorrow.

For this first item (4pm), we still want to check against the sun-set-time for today.

Try this (not tested), it introduces a new variable previous_setting, which is basically equal to next_setting - 24 hours. It is basically the sun-set-time for tomorrow at the date of today. I assume this will be more or less equal (will probably difference a few minutes).

{% set cond1 = state_attr('weather.forecast_home_hourly', 'forecast')[1].condition %}
{% set next_setting = as_timestamp(state_attr('sun.sun', 'next_setting')) %}
{% set previous_setting = as_timestamp(state_attr('sun.sun', 'next_setting')) - 86400  %}

{% set next_rising = as_timestamp(state_attr('sun.sun', 'next_rising')) %}
{% set cond1_time = as_timestamp(state_attr('weather.forecast_home_hourly', 'forecast')[1].datetime) %}

{% if ( cond1_time < next_rising and next_rising < next_setting and cond1_time > previous_setting) or ( cond1_time > next_setting and cond1_time < next_rising ) %}
  {% if cond1 == 'sunny' %} night {% elif cond1 == 'partlycloudy' %} night-partly-cloudy {% else %} {{ cond1 }} {% endif %}
{% else %}
  {{ cond1 }}
{% endif %}
1 Like

Thanks! Well I am using the refresh timestamp for that to confirm it is sleeping. If there is no new timestamp then it is sleeping. I do not like the idea of a blank screen, in my case it should still keep the daily solar result so I can take a look at the statistics even if it is asleep. But if you need this then just take a look at the ā€œWAITING FOR DATAā€¦ā€ part in the original code from madelena. You can use something like this.

Perhaps the problem is that your screen is updated too often? Iā€™ve read from the manufacturer that itā€™s recommended to set refresh rates to at least 180 seconds, and also to keep the display power off from time to time if possible.

Anyone else screen gone black after the latest esphome firmware update?

Edit: there been a fix put out now.

Just my experience, my display which I put together last august died this month. I had it updating every minute. So I suppose that works out to somewhere around 430,000 refreshes?

Anyway, I will definitely implement the prescence sensor for refreshing. Thatā€™s a clever idea to extend the panel life.

I love my screen so much but itā€™s rather small. Does anyone know if there is any bigger screens to use? No touch needed, or is the tablet a better choice for that?

1 Like

Hi Guys,
Does anyone have a list of glyph to midi as a reference, Iā€™d like to use more than the posted MDI icons.

Eg. Is there a list of these?

 - "\U000F0590" # mdi-weather-cloudy
  - "\U000F0F2F" # mdi-weather-cloudy-alert
  - "\U000F0E6E" # mdi-weather-cloudy-arrow-right
  - "\U000F0591" # mdi-weather-fog
  - "\U000F0592" # mdi-weather-hail
  - "\U000F0F30" # mdi-weather-hazy
  - "\U000F0898" # mdi-weather-hurricane
  - "\U000F0593" # mdi-weather-lightning
  - "\U000F067E" # mdi-weather-lightning-rainy
  - "\U000F0594" # mdi-weather-night
  - "\U000F0F31" # mdi-weather-night-partly-cloudy
  - "\U000F0595" # mdi-weather-partly-cloudy
  - "\U000F0F32" # mdi-weather-partly-lightning
  - "\U000F0F33" # mdi-weather-partly-rainy
  - "\U000F0F34" # mdi-weather-partly-snowy
  - "\U000F0F35" # mdi-weather-partly-snowy-rainy
  - "\U000F0596" # mdi-weather-pouring
  - "\U000F0597" # mdi-weather-rainy
  - "\U000F0598" # mdi-weather-snowy
  - "\U000F0F36" # mdi-weather-snowy-heavy
  - "\U000F067F" # mdi-weather-snowy-rainy
  - "\U000F0599" # mdi-weather-sunny
  - "\U000F0F37" # mdi-weather-sunny-alert
  - "\U000F14E4" # mdi-weather-sunny-off
  - "\U000F059A" # mdi-weather-sunset
  - "\U000F059B" # mdi-weather-sunset-down
  - "\U000F059C" # mdi-weather-sunset-up
  - "\U000F0F38" # mdi-weather-tornado
  - "\U000F059D" # mdi-weather-windy
  - "\U000F059E" # mdi-weather-windy-variant
  - "\U000F058E" # mdi-water-percent
  - "\U000F04C5" # mdi-spedometer
  - "\U000F0F29" # mdi-snowflake-alert
  - "\U000F15FA" # mdi-windsock
  - "\U000F19B3" # mdi-arrow-down-thin
  - "\U000F19B2" # mdi-arrow-up-thin
  - "\U000F19B4" # mdi-arrow-top-right-thin
  - "\U000F19B7" # mdi-arrow-bottom-right-thin
  - "\U000F00A5" # mdi-binoculars
  - "\U000F018C" # mdi-compass-outline
  - "\U000F05A9" # mdi-wifi
  - "\U000F0928" # mdi-wifi-strength-4
  - "\U000F0925" # mdi-wifi-strength-3 
  - "\U000F0922" # mdi-wifi-strength-2
  - "\U000F091F" # mdi-wifi-strength-1
  - "\U000F092B" # mdi-wifi-strength-alert-outline
  - "\U000F0079" # mdi-battery
  - "\U000F0082" # mdi-battery-90
  - "\U000F0081" # mdi-battery-80
  - "\U000F0080" # mdi-battery-70
  - "\U000F007F" # mdi-battery-60
  - "\U000F007E" # mdi-battery-50
  - "\U000F007D" # mdi-battery-40
  - "\U000F007C" # mdi-battery-30
  - "\U000F007B" # mdi-battery-20
  - "\U000F007A" # mdi-battery-10
  - "\U000F10CD" # mdi-battery-alert-variant-outline
  - "\U000F0E03" # mdi-thermometer-chevron-up
  - "\U000F0E02" # mdi-thermometer-chevron-down
  - "\U000F1A09" # mdi-triangle-small-down
  - "\U000F1A0A" # mdi-triangle-small-up

Thanks

You should find the answer in this post:

TLDR; by opening the font on your computer you will find all informations you need

Thanks @makai,
Very helpful!

1 Like

Love the image, how does one get that working?
Can you please share your code?

Finally got the screen and esp32 at home, and the demo program works. Now itā€™s time to start designing the UI of this thing.

As several else have stated, would be lovely to have a way to preview the results of the output script to a screen instead of having to flashing it all the time to the ESP32.

Anyone managed to make something for this function?

2 Likes

Same - sometimes after update screen gone black, sometimes update normal, BUT this happend after both firmware updates (1.6.2. last update). During update esphome were show me in logs a few little issues and i delete it, then esp was updated as normal, but this black screen problem has arise.

I was looking for a similar solution, because I did something like this for the first time in my life, but I didnā€™t find anything and did everything from scratch and flashed the device every time. The best way is to take something as an example.

The code is mostly made up of what has been done by OP with a few little customisations to suit my needs. To get it working, just follow along with this thread and the github. If you need to know something more specific, then let me know.

oh, Iā€™ve held off the 1.6.2 update after being too quick on the one before and having that issue. Perhaps restore the previous version and see how you go.

1 Like

How can I do it? I do not see the opportunity to return the previous version.

Settings > System > Backup and you should have had an ESPhome backup be automatically created for you that you can reapply. But Iā€™m not sure if that then triggers your ESP32 device to suggest to also revertā€¦ I did have troubles trying to work that one out myself the other day but perhaps itā€™ll be fine for you.