ppedro74 / Arduino-SerialCommands

BSD 3-Clause "New" or "Revised" License
87 stars 29 forks source link

support telnet server #9

Closed GralfR closed 1 year ago

GralfR commented 3 years ago

Hi!

Your library is great. It works fine inside my project for one serial on USB of Arduino Uno. I've read inside the documentation, that SerialCommands does support several serials. I wonder, if it can be used for a telnet, too.

I'd like to have a telnet server and a serial terminal inside one project. It would be great, if the telnet-session could use the same commandset as the serial. Is this possible? How to do that?

If that does not work, can one at least send any char array to the SerialCommands-parser? So I can at least grap any input and use the SerialCommands parser to direct to other command-functions without the need for another parser.

Thanks

GralfR commented 1 year ago

Turns out that Serial nd Ethernet.Client both are a stream. So SerialCommands do in deed work for both. I've successfully implemented USB/Serial-terminal and a telnet-terminal on the same device (UNO R3) without the need to change the library. I've just added some special one-key-commands to the library to detect backspace tab and ESC-key, but that's another story. So for the telnet topic: solved. Sad, that this library is not supported anymore, as there was no answer for more than 2 years and I had to answer myself...