Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

update infodisplay when WiFi and MQTT become available #57

Merged
merged 3 commits into from
Oct 22, 2024

Conversation

elratt0r
Copy link
Contributor

When using the info display, it mostly shows an error for MQTT and WiFi due to the task running earlier/faster than the others. Around 500ms of delay seem to be sufficient to have the correct values there.

@lanrat
Copy link
Owner

lanrat commented Oct 18, 2024

Instead of adding a delay (and making the UI appear slow) could we monitor the WIFI/MQTT state and reload the info display once they are connected?

@elratt0r
Copy link
Contributor Author

I refrained from this path, as it would mean waiting for two values and displaying inaccurate content first.

What would be your approach? Wait for both after drawing the infodisplay and then partial update? Or full redraw?

@lanrat
Copy link
Owner

lanrat commented Oct 20, 2024

I think a partial redraw when the data is ready works, or a full refresh when the data is ready.

@elratt0r
Copy link
Contributor Author

Partial redraw was the way to go, a full refresh just looked too ugly to me in UX terms.

@elratt0r elratt0r changed the title add 500ms delay for infodisplay to catch up with mqtt and wifi status update infodisplay when WiFi and MQTT become available Oct 21, 2024
@lanrat lanrat merged commit 8c40177 into lanrat:main Oct 22, 2024
3 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants