From a056538201ec129084df1a8bd5fd2b180508341e Mon Sep 17 00:00:00 2001 From: norbert-walter Date: Tue, 25 Jan 2022 09:51:21 +0100 Subject: [PATCH] Fix Date Time format for < 9 AM (one character) --- lib/obp60task/OBP60Pages.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/obp60task/OBP60Pages.h b/lib/obp60task/OBP60Pages.h index 9b7fed7..dea0c44 100644 --- a/lib/obp60task/OBP60Pages.h +++ b/lib/obp60task/OBP60Pages.h @@ -114,7 +114,7 @@ void showPage(busData values){ hour += values.timezone + 24; } hour %= 24; - sprintf(newhour, "%d", hour); + sprintf(newhour, "%02d", hour); newtime[0] = newhour[0]; newtime[1] = newhour[1]; display.print(newtime);