Early Exploration: LVGL Integration in Unity on Embedded Systems June 24, 2025

Discovering LVGL for Embedded GUIs in Unity

As a solo dev of Spaceship Adventures, I’m constantly on the lookout for lightweight, embeddable UI frameworks. Recently, I came across LVGL—a C-based graphics library designed for microcontrollers and single-board computers. Even better, it can be bridged into Unity as a native plugin, letting me craft interactive, performant dashboards on Raspberry Pi–powered displays.

LVGL UI Banner

Why LVGL?

LVGL offers a rich widget set, theming, animations, and a low memory footprint—ideal for embedded SBCs. By rendering into a framebuffer, it decouples nicely from Unity’s Texture2D, giving me pixel-perfect control over each panel.

LVGL GUI on Raspberry Pi Display

Embedding into Unity

To integrate LVGL with Unity, I built a shared library (.so) that initializes LVGL, ticks its task handler, and exposes the framebuffer pointer. In Unity C#, I import these functions, copy the framebuffer into a Texture2D each frame, and forward touch events—seamlessly blending embedded UIs into my game scenes.

LVGL in Unity Editor

Scaling Across Panels

For my proof-of-concept, I’m testing both single-Pi and multi-Pi setups. Each Pi Zero W drives one or two small screens, fetching JSON payloads over MQTT for dynamic content updates. Here’s a look at my cluster setup:

Embedded Raspberry Pi Cluster Running LVGL+Unity

Next Steps

  • Refine the plugin for thread safety and double buffering.
  • Design themed LVGL widgets matching Spaceship Adventures’ sci-fi style.
  • Automate content pushes from my Flask-based server.

This exploration informed later decisions: the project eventually moved to Unreal Engine 5 for the main game (Hoshi no Isan), while embedded and multi-screen ideas remain possible for future physical installations. For the current ship design and dev journal, see the Yamabiko page and the Development Journal.

LVGL and Raspberry Pi remain useful for side projects or installations; the main game is now fully in UE5. More legacy technical posts are in the legacy archive, including Proof of Concept 2024 and the 2017 prototype build.

Disclaimer

This post is for informational purposes and reflects my ongoing experimentation. Details may change as development continues.

This entry is part of the Spaceship Adventures legacy archive: development logs, prototypes, and concept work from 2010–2025, before the project became Hoshi no Isan. The current game—a Japanese-aesthetic space visual novel and crew RPG aboard a JAXA Heritage Ship—is documented in the Development Journal and on the main site. For the full list of legacy posts, see the legacy archive.

← Legacy Archive Dev Journal