This commit is contained in:
2020-11-19 23:07:49 +01:00
parent 1d69022e1d
commit ada748edbb
2 changed files with 5 additions and 4 deletions

View File

@ -390,7 +390,8 @@ void oledPrint(char msg[]) {
if (currentLine < MAX_LINES) {
memset(lines[currentLine], 0, MAX_CHARS);
strncpy(lines[currentLine], msg, MAX_CHARS);
memset(lines[currentLine] + strlen(msg), ' ', MAX_CHARS - strlen(msg) - 1);
lines[currentLine][MAX_CHARS - 1] = 0;
oled_P6x8Str(1, currentLine, lines[currentLine]);
currentLine++;
} else {