Closed leonbrag closed 4 years ago
No problem, excellent library, thank you for sharing it. This is a suggestion.
If month, day, minute or second is a single digit please prepend with 0.
Please give detailed instructions needed for anyone to attempt to reproduce the problem.
Run samples, code with the slight modification:
void digitalClockDisplay(){ // digital clock display of the time Serial.print(hour()); Serial.print(":"); Serial.print(minute()); Serial.print(":"); Serial.print(second()); Serial.print(" "); Serial.print(day()); Serial.print(" "); Serial.print(month()); Serial.print(" "); Serial.print(year()); Serial.println(); }
Observe output similar to this in the serial window:
22:32:05.663 -> 21:32:4 29 5 2020
Desired outcome:
21:32:04 29 05 2020
While this can be easily worked around in the code, it would be nice for library to have ability to produce such output.
n/a
n/a - samples that comes with the library
My mistake. All values are returned as uint8_t.
Description
No problem, excellent library, thank you for sharing it. This is a suggestion.
If month, day, minute or second is a single digit please prepend with 0.
Steps To Reproduce Problem
Please give detailed instructions needed for anyone to attempt to reproduce the problem.
Run samples, code with the slight modification:
Observe output similar to this in the serial window:
22:32:05.663 -> 21:32:4 29 5 2020
Desired outcome:
21:32:04 29 05 2020
While this can be easily worked around in the code, it would be nice for library to have ability to produce such output.
Hardware & Software
n/a
Arduino Sketch
n/a - samples that comes with the library
Errors or Incorrect Output
n/a