↩ All projects and sketches Deze pagina in het Nederlands
ESP32 · UDP · WiFi

One sender, multiple screens

Lilygo T-Display S3 showing sockets and values
The T-Display S3 acting as sender — the only board that queries the P1 meter and the sockets itself

Several screens showing the same energy data in one house, without every board separately querying the HomeWizard P1 meter and sockets.

One P1 meter, several screens: that doesn't scale

Every AutoSockets board queries the HomeWizard P1 meter itself over HTTP — one round trip (request plus response) takes a few tens of milliseconds. With a single screen you never notice. Add a second or third, each with its own poll interval, and they start getting in each other's way at the meter. You'll see that as a board that occasionally skips a reading or briefly shows Conn ERR.

The fix: let only one board query the meter and the sockets, and have that board forward the values to the rest.

One sender, the rest just listen

Only the T-Display S3 scans the network, queries the P1 meter and the sockets, and switches them if configured to. Every second it forwards everything that belongs on a screen to the boards that registered as a client — via a small UDP unicast packet of just over 200 bytes.

The clients scan nothing, switch nothing, and there is nothing to configure. They receive the packet and draw the screen — that's it.

Why UDP instead of HTTP? UDP needs no handshake and no acknowledgement traffic — ideal for a small packet that arrives fresh every second anyway. A dropped packet is not a problem: the next one arrives a second later.

Which boards can act as a client?

Any board that already works as a display for AutoSockets can also run as a receive-only client — same screen, just without pestering the P1 meter itself:

Lilygo T-Display (TTGO)

Lilygo T-Display with P1 data
Lilygo T-Display
Lilygo T-Display mounted on the wall next to a socket in the kitchen
Handy setup right next to the heavy consumers in the kitchen (cooktop, oven)

Waveshare ESP32-S3 1.54"

Waveshare ESP32-S3 1.54 inch LCD showing energy data
Waveshare ESP32-S3 1.54"

M5Stack Fire / Basic Core

M5Stack Basic and M5Stack Fire side by side showing sockets and values
M5Stack Basic (left) and M5Stack Fire (right)

Waveshare ESP32-S3 4.2" RLCD

Battery client in development — an e-paper-like screen that draws no power while the image doesn't change.

Waveshare ESP32-S3 4.2 inch RLCD screen showing energy data and battery percentage
Waveshare ESP32-S3 4.2" RLCD

Only one sender per network

Two active senders at the same time is not supported — only one board may actually query and switch the P1 meter and the sockets. Every other board runs the client firmware.