Qt on Embedded Devices: Building Touchscreen Interfaces
Qt is widely used for touchscreen interfaces on industrial controllers, medical devices, appliances and instruments running embedded Linux. On a desktop, Qt sits on a window system someone else configured. On a custom board, the team chooses how Qt reaches the display, the GPU and the touch controller, and those choices decide start-up time, frame rate and how the product feels in the hand.
At a glance
- EGLFS
- The Qt platform plugin that renders full screen through the GPU with no window system.
- 16.7 ms
- The time available to draw each frame at 60 frames per second.
- Yocto
- The meta-qt6 layer builds Qt into a Yocto Linux image for the target board.
- Wayland
- Needed when several applications share the display through a compositor.
The problem
A UI that runs smoothly on a development PC often stutters on the target, because the embedded GPU, memory bandwidth and CPU are a fraction of the desktop. Late problems usually trace back to early choices: a heavy visual design, images at the wrong size, or software rendering where a GPU was available.
Start-up is the other common complaint. Users expect an appliance to be ready quickly, and a Linux boot followed by a slow application launch leaves a blank screen long enough to look like a fault.
Design the interface for the target hardware from the first screen. A UI tuned on a desktop will be retuned on the board, at greater cost.
How Qt reaches the screen
For a single full-screen application, the EGLFS plugin is usually the best choice: it renders directly through OpenGL ES with minimal overhead. The linuxfb plugin renders in software into the framebuffer for boards without a GPU. Wayland adds a compositor, which costs some overhead but allows several applications or windows.
Touch input normally arrives through evdev or libinput. Check calibration, rotation and multi-touch on the real panel, and test with gloves or a wet screen if the product will meet them. For microcontroller-based devices without Linux, Qt for MCUs is a separate commercial product.
What good looks like
Confirm the GPU, its OpenGL ES or Vulkan driver support and the display interface early, and build Qt for the board with the matching platform plugin.
Measure frame rate and start-up time on the target from the first prototype screen, and keep both visible in every build.
Shorten start-up with a splash image shown early in boot, QML compiled ahead of time, and only the first screen loaded before the UI appears.
| Plugin | Rendering | Suits |
|---|---|---|
| eglfs | GPU, full screen | A single application on a board with a GPU |
| linuxfb | Software, into the framebuffer | Simple UIs on boards without a GPU |
| wayland | GPU, through a compositor | Several applications or windows on one display |
| vnc | Software, over the network | Remote access and testing |
| ms | |
|---|---|
| 30 fps | 33.3 |
| 60 fps | 16.7 |
| 90 fps | 11.1 |
| 120 fps | 8.3 |
What it changes
Smooth Interaction
Animations and scrolling hold their frame rate on the real hardware.
Fast Start-up
The device shows a responsive interface soon after power-on.
Reliable Touch
Input works across the panel, in every orientation and in real operating conditions.
Maintainable Image
Qt built through Yocto is reproducible and updated with the rest of the system.
Where to go next
Size images to the display resolution and keep shapes simple where the GPU handles them well.
Plan for on-screen text entry if the product needs it. The Qt Virtual Keyboard module provides one, under GPL or commercial licence terms.
Problems this prevents
- A UI that is only smooth on a desktop
- A blank screen during a long start-up
- Touch offsets after the panel is mounted
- Images rescaled at runtime on every frame
Discuss your project
Email support@aavico.com or use Get in Touch when the website finishes loading.