mirror of
https://github.com/TomNisbet/TommyPROM.git
synced 2024-11-26 06:49:16 +00:00
Fixes #8 - allow CR or LF as the terminal EOL character
This commit is contained in:
parent
038f113606
commit
ee120e352f
@ -113,7 +113,7 @@ char * readLine(char * buffer, int len)
|
|||||||
buffer[ix++] = c;
|
buffer[ix++] = c;
|
||||||
Serial.write(c);
|
Serial.write(c);
|
||||||
}
|
}
|
||||||
} while ((c != '\n') && (ix < len));
|
} while ((c != '\n') && (c != '\r') && (ix < len));
|
||||||
|
|
||||||
buffer[ix - 1] = 0;
|
buffer[ix - 1] = 0;
|
||||||
return buffer;
|
return buffer;
|
||||||
|
Loading…
Reference in New Issue
Block a user