Skip to content

Commit fc2546b

Browse files
committed
Fix for appended 0 in scrolling text
1 parent e6fa426 commit fc2546b

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

include/clockWork.hpp

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -203,10 +203,10 @@ void ClockWork::scrollingText(const char *buf) {
203203
led.show();
204204

205205
i++;
206-
if (i > pgm_read_byte(&(fontWidth[normalSizeASCII]))) {
206+
if (i >= pgm_read_byte(&(fontWidth[normalSizeASCII]))) {
207207
i = 0;
208208
ii++;
209-
if (ii > strlen(buf)) {
209+
if (ii >= strlen(buf)) {
210210
ii = 0;
211211
}
212212
}

0 commit comments

Comments
 (0)