A real Telnet server for Arduino + Ethernet Shield

Last year, I started looking in to Telnet as a learning exercise. I ended up implementing a full Telnet server for Arduino that actually supported the protocol. Most examples just open a socket and listen, and will get bits of garbage data when command packets come in. My work-in-progress server handles these, and supports many of them (echo, are you there, etc.) and has hooks for where anything else needed could be added.

It has an extensive debug mode that will display all the Telnet protocol stuff in text format -- a fun leaning tool.

I posted this all on my website...

...but since I have not had time to get back to this experiment, I decided to get the source code posted to GitHub so others could mess with it without having to copy/paste it from my website:

NOTE: This server supports multiple incoming connections (not at the same time; I have that worked out, but not posted) if you modify the Ethernet library to work around a bug:

http://subethasoftware.com/2013/04/09/arduino-ethernet-and-multiple-socket-server-connections/