This ESP32-S3 Touchscreen Runs Its Own X11 Server, So Linux Apps Draw on It Over Wi-Fi

User Avatar Aswinth Raj
Author
Share
ESP32-S3 Touchscreen Running X11 Linux Applications Over

If you want a small touchscreen as a Linux display, the usual choices are to build a whole Linux computer into it or treat it as a dumb remote framebuffer. Sergey Zorin took a third route. Woodland X11 is an experimental X Window System server that runs directly on an ESP32-S3, so ordinary Linux X11 programs open their windows on a cheap touchscreen.

X11 written from the specification

This is not a port of Xorg and not a VNC-style viewer. The maker implemented the X11 core protocol himself, from the specification, with no extensions. The firmware is built on ESP-IDF and uses LovyanGFX for the display, which gives him direct control over memory use and rendering. It runs on an ESP32-S3 with PSRAM and has been tested on an Elecrow CrowPanel Advance 4.3 inch (800 x 480) board.

The X11 clients still run on a Linux machine. They connect to the ESP32-S3 over Wi-Fi, or over SPI from a Raspberry Pi host, and the touchscreen acts as the X pointer. In the demo video, xclock, xcalc and xeyes run under the Motif Window Manager (mwm), and their windows appear and respond to touch on the physical panel.

The hard parts

The maker lists the problems that took the most work: managing X11 clients, resources and drawing operations inside microcontroller memory; getting real applications and mwm to work while finding which X11 operations are still missing; finding stable LCD timing and avoiding wasted redraws; and translating touch events into X11 input events while keeping it responsive. On the SPI link to the Raspberry Pi, replacing constant polling with a GPIO interrupt cut idle CPU use on the Pi substantially.

It is still experimental and the protocol support is incomplete, but it already runs real X11 applications. The code is Apache-2.0, with a first release in preparation, and the project site is woodlandx11.dev.

Our take

Getting a 40-year-old network display protocol running on a microcontroller is a great systems exercise, and the result is useful too: a few dollars of ESP32-S3 panel could become a wireless status or control screen for any Linux box. We are running this as an experiment to see whether deep embedded-software builds like this one find an audience with our readers.

Image credit: Sergey Zorin (One_Manufacturer6839) / Reddit video frame, cropped and resized.

About the author: Aswinth Raj is an electronics engineer and the editor of CircuitDigest, where he has published more than 150 hands-on projects and tutorials across Arduino, PIC, ESP32, Raspberry Pi and EV battery systems. He selects the stories on this page for what engineers and makers can actually learn or build from. Connect on LinkedIn

Add a comment

No account needed. Your comment appears once a moderator has reviewed it.

Never shown publicly.
CAPTCHA
This question is for testing whether or not you are a human visitor and to prevent automated spam submissions.