The only problem is that terminal is optional: https://github.com/apache/nuttx/blob/master/drivers/serial/Kconfig#L167-L174 So, if the user doesn't enable CONFIG_SERIAL_TERMIOS in defconfig, readline will stop working due to failure to disable ECHO. Three option here:
1. Remove SERIAL_TERMIOS and enable terminal setting always 2. readline or special tool designed for raw mode select SERIAL_TERMIOS in their config 3. Keep SERIAL_TERMIOS option, but simulate terminal setting by change isconsole flag Both code size and change is small for option 3. On Fri, Mar 10, 2023 at 9:52 PM Gregory Nutt <spudan...@gmail.com> wrote: > > > Thank you for this good change for better posix compliance. > > The TERMIOS changes are basically good and does help with POSIX > compliance, but the console ECHO behavior is not and has nothing to do > with POSIX compliance. POSIX does not deal with implementation. We can > look at standard implementations for guidance, however: > > Standard implementations of readline place the console in raw mode in > which any echo from the driver is disabled (ECHO is not selected in the > TERMIOS). All echo is preformed selectively by the readline > implementation without trashing the users terminal. > > >