Skip to content

Commit

Permalink
Fix Progress / Remaining display on DOGM (MarlinFirmware#16005)
Browse files Browse the repository at this point in the history
  • Loading branch information
robbycandra authored and thinkyhead committed Nov 26, 2019
1 parent d0282e5 commit fc9f8d2
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions Marlin/src/lcd/dogm/status_screen_DOGM.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -353,7 +353,7 @@ void MarlinUI::draw_status_screen() {
#if ENABLED(DOGM_SD_PERCENT)
static char progress_string[5];
#endif
static uint8_t lastElapsed = 0, lastProgress = 0;
static uint8_t lastElapsed = 0xFF, lastProgress = 0xFF;
static u8g_uint_t elapsed_x_pos = 0, progress_bar_solid_width = 0;
static char elapsed_string[16];
#if ENABLED(SHOW_REMAINING_TIME)
Expand Down Expand Up @@ -460,7 +460,7 @@ void MarlinUI::draw_status_screen() {
+ get_remaining_time()
#endif
);
if (!timeval) timeval = elapsed.value * (100 * (PROGRESS_SCALE) - progress) / progress;
if (!timeval && progress > 0) timeval = elapsed.value * (100 * (PROGRESS_SCALE) - progress) / progress;
if (!timeval) {
estimation_string[0] = '\0';
estimation_x_pos = _SD_INFO_X(0);
Expand Down

0 comments on commit fc9f8d2

Please sign in to comment.