Closed Jimmyboy83 closed 8 months ago
Currently, the time string is created in ESPHome and sent to the display (page Home) every minute. You can try to customize that routine to send it also to the your new time component on "screensaver" page, however, as that would add one more point for maintenance, I would instead add a timer to that page with interval of 60000 (every minute) and in the timer event actions I would add a line to copy the text from home.time
to your new component.
Also, to set the brightness you have to set the variable dim
.
In summary:
screensaver
, very first line, change from dim=0
to dim=40
. This is defining the brightness when the screensaver
is shown.tim
to 60000
(1 min). (you can reduce this later, maybe 10s / 10000
or even less will work better).your_time_component.txt=home.time.txt
.With that, when the screensaver page is visible, it will copy the content of the time from the home page every minute (or any interval you set).
Please let me know if it worked.
I added timer on screensaver page and event trigger screensaver.clock.txt=home.time.txt It didn't work
Do you have any error message?
Is the timer enabled?
On attributes, make sure en
is 1.
Error in esphome logs? when enable screensaver:
19:07:02][E][nextion:535]: ERROR: Received numeric return but next in queue "set_component_value" is not a valid sensor type 0 [19:07:02][E][nextion:260]: Nextion queue is empty! [19:07:02][W][component:204]: Component nextion.display took a long time for an operation (0.10 s). [19:07:02][W][component:205]: Components should block for at most 20-30ms. [19:07:12][W][nextion:345]: Nextion reported picture ID invalid!
Timer is enabled
Do you mind sharing your HMI file or an export of page screensaver?
It doesn't matter now, after updating esphome to latest version tft file update again starts freeze at 23% Cleanup build files did not help :-)
Sounds like this one: https://github.com/Blackymas/NSPanel_HA_Blueprint/issues/1061#issue-1905619363
After several attempts, and alternation between blank and nspanel files, it works again (no logic) I upload my hmi and page files to github https://github.com/Jimmyboy83/nspanel/
Really cool idea. +1 from me 👍🏼Sent from my iPadOn 21 Sep 2023, at 12:02, Jimmyboy83 @.***> wrote: Hi! Thank You for this awesome work!!! It will be cool to add customization to screensaver. Not just screen off, but some information, like time or outside temperature. I have tried to add time to screensaver page in Nextion Editor (copy from home page), but it only left blank rectangle without time I have also edited dimming settings for screensaver page, added int brightness=100,brightness_dim=40 and replace font 6 with bigger one Can You help me with time object on screensaver?
—Reply to this email directly, view it on GitHub, or unsubscribe.You are receiving this because you are subscribed to this thread.Message ID: @.***>
Please take a look: https://github.com/Jimmyboy83/nspanel/pull/1
Looks great, 176 bold ubuntu font
Make it configurable and add as a feature!
Maybe outdoor temperature sensor will be good to add.
Make it configurable and add as a feature!
🤣
I will take a look...
Thank You!!!
Maybe outdoor temperature sensor will be good to add.
But then why not disabling Sleep and have the Home page dimmed?
The panel is on the bedside table and at night my wife can't see small text without glasses. Time and temperature outside, that's all she need at night and in the morning. I planned to turn on the screensaver mode at night through automation, but in version 4 the mechanism has changed and now it's not very convenient to do it
We tested the new screensaver mode last night. It is very convenient
Hello, can you tell me how can I switch-off the screensaver? Thank you.
Set Timeout Sleep to 0s.
Hi! Everything working fine, and i bought second NSPanel personally for myself. There are two little questions:
For updating to new version of tft is enough to simply import home and screensaver pages in new HMI from my config and upload it to panel?
It should be. The Home page can be a bit more complex, as the changes of we changing something in an update are quite big, so maybe you want to just adjust your changes again (based on what changed).
GitHub offers quite nice tools to see what changed from one version to other, so you might have to take a look at that on each release:
For the screensaver page, the chances of a change from our side are really low, so you probably will be good.
Just make sure you don't change page's names and pages ids, as we use those in the code.
2. Can you add refreshing of outdoor sensor on home page fo using it on screensaver page. I have added it on screensaver page like home.time.txt and in timer, but it only updates on start of screensaver
I've added that change to dev
. It would be included in the next release.
Thank you! I've already use your fix. It work even on version 4.0. Replacing screensaver page also works fine, on home page I made only some cosmetics changes, so I can edit it again. Cannot find how export import txt files :-)
Cannot find how export import txt files :-)
We use this: https://github.com/MMMZZZZ/Nextion2Text
Set Timeout Sleep to 0s.
Can you tell me where to set this? Can't find it in the blueprint, do I have to set it in esphome?
On Home Assistant, under Settings > Devices and Services > ESPHome.
Hi! Thank You for this awesome work!!! It will be cool to add customization to screensaver. Not just screen off, but some information, like time or outside temperature. I have tried to add time to screensaver page in Nextion Editor (copy from home page), but it only left blank rectangle without time I have also edited dimming settings for screensaver page, added int brightness=100,brightness_dim=40 and replace font 6 with bigger one
Can You help me with time object on screensaver?