Hi,
What would be the best approach to rotating between multiple sensors on one line of text on a display?
example: “test 123”, sleep 10s, replace text with “test 456”…
I’m using a 128x128 display and my display → lambda does quite a bit of stuff such as changing states and colors based on if a home assistant sensor states I’m in a meeting, weather display with icons, time, wifi reception, and some other text…).
What I want to do is rotate between 2 or 3 lines of text on a timer.
I tried adding a while loop with sleep but it seems that lambda doesn’t like sleep, at least not how I used it, and I had to re-flash to get back to it.
I’m aware of pages but from my understanding I would basically have to have a copy of my lambda for each page with the one different printf, but that feels wasteful to me.
I could probably do this from home assistant with a template sensor or even with using a text_sensor from an input_text, but that also feels like a workaround to me and really relies on home assistant for every change instead of just updating it once a day and rotating.
Am I missing something obvious? is there a way to do a while loop with a sleep? is there a way for a page to only replace 1 part of the page? some other obvious way that I’m missing?
Thanks!