From 4b3dc655989a27466f2acd64114c23793728fec1 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Gu=C3=B0ni=20M=C3=A1r=20Gilbert?= Date: Sun, 2 Apr 2023 11:28:07 +0000 Subject: [PATCH 1/2] Don't always set MSG_WELCOME at end of toolchange This should only be set when NOT printing Change in memory: Flash: +8 bytes SRAM: 0 bytes --- Firmware/mmu2_reporting.cpp | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/Firmware/mmu2_reporting.cpp b/Firmware/mmu2_reporting.cpp index 114523a08..5504128a8 100644 --- a/Firmware/mmu2_reporting.cpp +++ b/Firmware/mmu2_reporting.cpp @@ -20,7 +20,9 @@ void BeginReport(CommandInProgress /*cip*/, uint16_t ec) { void EndReport(CommandInProgress /*cip*/, uint16_t /*ec*/) { // clear the status msg line - let the printed filename get visible again - lcd_setstatuspgm(MSG_WELCOME); // should be seen only when the printer is not printing a file + if (!printJobOngoing()) { + lcd_setstatuspgm(MSG_WELCOME); + } custom_message_type = CustomMsg::Status; } From f34c1ffeacaf1efcc870cd903ac0be30f27c4d39 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Gu=C3=B0ni=20M=C3=A1r=20Gilbert?= Date: Sun, 2 Apr 2023 11:28:58 +0000 Subject: [PATCH 2/2] Fix an issue where visualisation is overwritten by SD file name We should let EndReport set the custom message type state to Status This will ensure the SD file name is shown correctly AFTER we've shown the visualisation Currently the visualisation is cut off in the middle by ReportProgressHook Change in memory: Flash: -6 bytes SRAM: 0 bytes --- Firmware/mmu2_reporting.cpp | 5 ----- 1 file changed, 5 deletions(-) diff --git a/Firmware/mmu2_reporting.cpp b/Firmware/mmu2_reporting.cpp index 5504128a8..ea4bcd01f 100644 --- a/Firmware/mmu2_reporting.cpp +++ b/Firmware/mmu2_reporting.cpp @@ -272,11 +272,6 @@ void ReportProgressHook(CommandInProgress cip, uint16_t ec) { if (cip != CommandInProgress::NoCommand) { custom_message_type = CustomMsg::MMUProgress; lcd_setstatuspgm( _T(ProgressCodeToText(ec)) ); - } else { - // If there is no command in progress we can display other - // useful information such as the name of the SD file - // being printed - custom_message_type = CustomMsg::Status; } }