(I am not talking about a binary sensor/switch here)
I have a device that is connected to an ESPHome node via an UART. I would like to send and receive binary data (i. .e. including non-printable/null characters) to/from that UART with Home Assistant (in automations/scripts).
I have managed to get data in and out via an ESPHome stream_server component. But that’s just a TCP socket connection and I don’t know how I’d use that with HA.
Any ideas how I can achieve that?
No idea about stream_server. But you could experiment with uart debug.
Getting the data in and out on the UART into a variable in ESPHome isn’t the problem. Getting it to Home Assistant is.