Skip to content

Commit

Permalink
Fix for appended 0 in scrolling text
Browse files Browse the repository at this point in the history
  • Loading branch information
dbambus committed Sep 13, 2024
1 parent e6fa426 commit fc2546b
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions include/clockWork.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -203,10 +203,10 @@ void ClockWork::scrollingText(const char *buf) {
led.show();

i++;
if (i > pgm_read_byte(&(fontWidth[normalSizeASCII]))) {
if (i >= pgm_read_byte(&(fontWidth[normalSizeASCII]))) {
i = 0;
ii++;
if (ii > strlen(buf)) {
if (ii >= strlen(buf)) {
ii = 0;
}
}
Expand Down

0 comments on commit fc2546b

Please sign in to comment.