The Remote Serial Debugging Nightmare

The Remote Serial Debugging Nightmare

Everybody playing around with hardware that has a serial port and is not located close to the desk will sooner or later run into the problem, that the wire simply gets to long for a serial connection, especially with non EIA-232/RS-232, known as serial-TTL-UART.

Especially for debugging such hardware protocols, it is nice to have a terminal program, that also shows hex output and can understand hex input. Hterm is one of my favorite programs, when it comes to debugging serial stuff from a microcontroller.

Unfortunately, hterm is neither open source, nor does it support TCP-serial-bridges directly. And also many other tools lack some stuff. While Putty can simply use it’s telnet protocol, it is missing a hex dump and input.

If you still want to use hterm, you have mostly three options (the latter two are mostly the same but differ in price):

  • Using a virtual COM port software (e.g. com2tcp, has an unsigned driver 🙁 )
  • Buying a professional/dedicated seriel2ethernet server (like in the picture of the post)
  • Use another ESP32/ESP8266 to create your own serial2ethernet server (quick hint: disable logging with baud: 0 setting to use the USB serial port for this)

Both solutions are not the best choice in my opinion, because with ESPhome StreamServer Component (using telnet as transport), you already have a serial port over TCP available. To why not connect directly using telnet.

Tera Term – Not best in class, but all you need

If you install e.g. StreamServer (yes, it is f*** easy to deploy) on your ESP32 or you use ESP-Link for ESP8266, you have the serial port you want. Now you need the appropriate terminal program to connect to it.

It perfectly works with putty, if you only want to send and receive ASCII text, just select telnet and enter the IP and port of your ESP.

But when it comes to hex (like in my Buderus KM271 post), you are simply lost with putty and you also can not easily connect hterm to it, without using a nasty com2tcp tool, running long wires or using the mentioned helper-ESP.

After configuring tera term appropriately, it seems to work quite well. Not as good as hterm, but better than the other options:


1 Kommentar bisher

Reverse Engineering the Buderus KM271 – And Making It WiFi-Flying on ESPhome and Home Assistant – MolesBlog Veröffentlicht am16:37 - 26. November 2022

[…] See my blog post to get to know how to access serial data over ethernet on windows: The Remote Serial Debugging Nightmare […]

Schreibe einen Kommentar

WordPress Cookie Plugin von Real Cookie Banner