diff --git a/CHANGELOG.md b/CHANGELOG.md index f6caafd66..3208282e2 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -14,7 +14,8 @@ All notable changes to this project will be documented in this file. - Matter refactoring of bridged devices (#21575) - ESP32 Core3 platform update from 2024.05.13 to 2024.06.10 (#21569) - Optional MQTT_TELE_RETAIN to Energy Margins message replaced by ``SensorRetain`` -- Matter filter suffix automatically added for sensors +- Matter filter suffix automatically added for sensors (#21589) +- Display timing splash screen with display modes 1 to 5 ### Fixed - Berry `input()` returns empty string and does not crash (#21565) diff --git a/RELEASENOTES.md b/RELEASENOTES.md index 33fce959a..ed8cdc01e 100644 --- a/RELEASENOTES.md +++ b/RELEASENOTES.md @@ -126,8 +126,10 @@ The latter links can be used for OTA upgrades too like ``OtaUrl https://ota.tasm ### Changed - Optional MQTT_TELE_RETAIN to Energy Margins message replaced by ``SensorRetain`` +- Display timing splash screen with display modes 1 to 5 - ESP32 Core3 platform update from 2024.05.13 to 2024.06.10 [#21569](https://github.com/arendst/Tasmota/issues/21569) - Matter refactoring of bridged devices [#21575](https://github.com/arendst/Tasmota/issues/21575) +- Matter filter suffix automatically added for sensors [#21589](https://github.com/arendst/Tasmota/issues/21589) ### Fixed - Berry `input()` returns empty string and does not crash [#21565](https://github.com/arendst/Tasmota/issues/21565) diff --git a/lib/lib_display/UDisplay/uDisplay.cpp b/lib/lib_display/UDisplay/uDisplay.cpp index e24b0ab42..890c2157f 100755 --- a/lib/lib_display/UDisplay/uDisplay.cpp +++ b/lib/lib_display/UDisplay/uDisplay.cpp @@ -290,6 +290,10 @@ uDisplay::uDisplay(char *lp) : Renderer(800, 600) { col_type = uCOLOR_BW; } else { col_type = uCOLOR_COLOR; + if (bpp == 16) { + fg_col = GetColorFromIndex(fg_col); + bg_col = GetColorFromIndex(bg_col); + } } str2c(&lp1, ibuff, sizeof(ibuff)); if (!strncmp(ibuff, "I2C", 3)) { @@ -368,11 +372,9 @@ uDisplay::uDisplay(char *lp) : Renderer(800, 600) { splash_font = next_val(&lp1); splash_size = next_val(&lp1); fg_col = next_val(&lp1); - if (bpp == 16) { - fg_col = GetColorFromIndex(fg_col); - } bg_col = next_val(&lp1); if (bpp == 16) { + fg_col = GetColorFromIndex(fg_col); bg_col = GetColorFromIndex(bg_col); } splash_xp = next_val(&lp1); diff --git a/tasmota/tasmota_xdrv_driver/xdrv_13_display.ino b/tasmota/tasmota_xdrv_driver/xdrv_13_display.ino index 2f963237e..7bfaecc78 100644 --- a/tasmota/tasmota_xdrv_driver/xdrv_13_display.ino +++ b/tasmota/tasmota_xdrv_driver/xdrv_13_display.ino @@ -2943,8 +2943,7 @@ void AddValue(uint8_t num,float fval) { * Interface \*********************************************************************************************/ -bool Xdrv13(uint32_t function) -{ +bool Xdrv13(uint32_t function) { bool result = false; if (XdspPresent()) { @@ -2958,7 +2957,9 @@ bool Xdrv13(uint32_t function) } break; case FUNC_EVERY_50_MSECOND: - if (Settings->display_model) { XdspCall(FUNC_DISPLAY_EVERY_50_MSECOND); } + if (Settings->display_model) { + XdspCall(FUNC_DISPLAY_EVERY_50_MSECOND); + } break; case FUNC_SET_POWER: DisplaySetPower(); @@ -2966,20 +2967,27 @@ bool Xdrv13(uint32_t function) case FUNC_EVERY_SECOND: #ifdef USE_GRAPH DisplayCheckGraph(); -#endif +#endif // USE_GRAPH #ifdef USE_DT_VARS get_dt_mqtt(); draw_dt_vars(); -#endif // USE_DT_VARS - +#endif // USE_DT_VARS #ifdef USE_DISPLAY_MODES1TO5 - if (Settings->display_model && Settings->display_mode) { XdspCall(FUNC_DISPLAY_EVERY_SECOND); } -#endif + if (Settings->display_model && Settings->display_mode) { + uint32_t wait = 0; + if (!Settings->flag5.display_no_splash) { // SetOption135 - (Display & LVGL) force disabling default 5 second splash screen + wait = 6; + } + if (TasmotaGlobal.uptime > wait) { // Allow time to display splash screen + XdspCall(FUNC_DISPLAY_EVERY_SECOND); + } + } +#endif // USE_DISPLAY_MODES1TO5 break; case FUNC_AFTER_TELEPERIOD: #ifdef USE_DT_VARS DisplayDTVarsTeleperiod(); -#endif // USE_DT_VARS +#endif // USE_DT_VARS break; #ifdef USE_DISPLAY_MODES1TO5 case FUNC_MQTT_SUBSCRIBE: diff --git a/tasmota/tasmota_xdsp_display/xdsp_17_universal.ino b/tasmota/tasmota_xdsp_display/xdsp_17_universal.ino index e1845ccea..2f9c8edf7 100644 --- a/tasmota/tasmota_xdsp_display/xdsp_17_universal.ino +++ b/tasmota/tasmota_xdsp_display/xdsp_17_universal.ino @@ -483,6 +483,7 @@ int8_t cs; color_type = renderer->color_type(); renderer->DisplayInit(DISPLAY_INIT_MODE, Settings->display_size, inirot, Settings->display_font); + renderer->clearDisplay(); Settings->display_width = renderer->width(); Settings->display_height = renderer->height(); @@ -504,7 +505,7 @@ int8_t cs; ApplyDisplayDimmer(); #ifdef SHOW_SPLASH - if (!Settings->flag5.display_no_splash) { + if (!Settings->flag5.display_no_splash) { // SetOption135 - (Display & LVGL) force disabling default splash screen renderer->Splash(); } #endif // SHOW_SPLASH