Serial.print("Error: unknown command: \"") Return // skip command processing and try again on next iteration of loop The original question did not say how the variable length strings are defined, but I'll assume they are terminated by a single newline character - which turns this into a line reading problem. ![]() It also avoids using the readStringUntil() function, to not timeout before the input arrives. ![]() It deliberately uses character arrays instead of the String type, to be more efficient and to avoid memory problems.
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |