PlatformIO Community with CR/LF

I have a simple serial command processor that gets ASCII commands terminated with a CR/LF.
I am finding that does not return in certain circumstances.
I wrote the following test code:

        if (Serial.available() == true)
            buff[index++] =;
            Serial.printf( "<%u>", buff[ index - 1 ] );

Whenever I hit a key in my serial terminal, I see it appear with its ASCII code. If I enter CR I get <13> and if I send LF I get <10> but if I set my terminal to transmit CR+LF on hitting the enter key I get nothing and my serial command read routine locks up. I suspect it is now stuck in read for some reason !

What am I missing?


And how did you do that?


How did I do what?
How did I send CR+LF?



TeraTerm’s behavior might be weird. When you set

monitor_eol = CRLF

in the platformio.ini and use the project task “monitor”, do you get the same behavior?


This is what my platformio.ini currently looks like:

platform = espressif32@3.4
framework = arduino
monitor_speed = 115200
monitor_flags = 
lib_deps =

Thanks for your interest.