With the TP-Link integration, I am currently using UDP as the communications protocol; however, with the advent of raw TCP, I could also use that (already tested as working).
Question: What is the preferred method from the Hubitat Environment perspective?
if you are maintaining a connection and the telnet interface does not work for you, raw tcp socket is the way to go. There is a lot of overhead in setting up the connection, so if you are planning on opening and closing it every time you send a message, I would not recommend it. You should instead send the raw lan message using HubAction with Protocol.RAW_LAN
In addition to what Chuck's saying — Socket is nice because you don't need to specify termChars, so parsing responses gets a a lot easier when they vary.
Not sure how you're implementing it, but feel to take any of the MagicHome raw code you need—raw socket has been great.
I will try to light the fire using Protocol.Raw_Lan. I am interested in minimizing overhead. Thanks.