Repository navigation
Building from Source
You only need this to work on NebulaScreen itself. A NebulaOS image build compiles it automatically (Integration with NebulaOS).
NebulaScreen uses a plain Makefile. There are two practical builds: the SDL simulator (desktop)
and the MIPS build for the Ender-3 V3 KE. The MIPS build is always done by
scripts/build-release.sh.
- A C++17 toolchain (GCC/G++ 7.2+),
make,cmake,git - For the simulator: SDL2 development headers
- For the MIPS build: a
mipselmusl cross toolchain — normally the NebulaOS build container -
python3(release packaging and its tests)
git clone --recurse-submodules https://github.com/NebulaOS-KE/NebulaOS-nebulascreen.git
cd NebulaOS-guppyscreenSubmodules: lvgl (LVGL v8), lv_drivers, libhv, spdlog.
(cd spdlog && git apply ../patches/0002-spdlog_fmt_initializer_list.patch)
(cd lvgl && git apply ../patches/0003-lvgl-dpi-text-scale.patch)| Patch | Purpose |
|---|---|
0002-spdlog_fmt_initializer_list.patch |
spdlog/fmt compatibility fix |
0003-lvgl-dpi-text-scale.patch |
DPI text-scaling adjustment |
scripts/build-release.sh applies both itself (only if not applied yet).
make libhv.a
make libspdlog.a(make wpaclient still exists but does nothing; Wi-Fi goes through NebulaOS.)
Install SDL2 headers, then build without CROSS_COMPILE:
# Fedora: sudo dnf install sdl2-compat-devel
# Debian / Ubuntu: sudo apt install libsdl2-dev
# Arch: sudo pacman -S sdl2
make -j"$(nproc)" GUPPY_SMALL_SCREEN=1 \
CFLAGS="-O3 -g0 -MD -MP -I./ -I./lvgl/ -I/usr/include/SDL2 -D_GNU_SOURCE=1 -Wno-incompatible-pointer-types" \
LDFLAGS="-lm -Llibhv/lib -Lspdlog/build -l:libhv.a -latomic -lpthread -lstdc++fs -l:libspdlog.a"The LDFLAGS override drops the Makefile's default -static, which a desktop SDL2 build cannot use.
-Wno-incompatible-pointer-types is needed on GCC 14+ for lv_touch_calibration.
GUPPY_SMALL_SCREEN=1 gives the KE's 480×272 layout.
Output: build/bin/nebulascreen. See Development and simulator to run it.
scripts/build-release.sh v0.9.0This is the one build recipe: this repository's CI and NebulaOS-firmware's image build both use it.
Run it inside the NebulaOS build container (ghcr.io/nebulaos-ke/nebulaos-build, pinned by digest in
NebulaOS-firmware's manifests/dependencies.conf), with the toolchain on PATH. CI uses
CROSS_COMPILE=mipsel-buildroot-linux-musl- from Bootlin mips32el--musl--stable-2024.02-1.
What it does:
- Applies the two submodule patches if needed.
- Builds the host
libhv.a/libspdlog.a, then runsscripts/build-mips.sh, which rebuilds libhv and spdlog for MIPS, builds NebulaScreen withGUPPY_SMALL_SCREEN=1andEVDEV_CALIBRATE=1, buildsnebulabeepfromk1/k1_mods/buzzer/guppybeep.c, and restores the host libraries. - Strips both programs and checks that the binary embeds the commit date (
SOURCE_DATE_EPOCHdefaults to the commit time ofHEAD, so the build does not depend on the wall clock). - Packages and checks
dist/nebulascreen-<version>.zipwithscripts/nebulascreen_release.py.
Environment: CROSS_COMPILE (default mipsel-linux-), NEBULASCREEN_THEME (default blue),
SOURCE_DATE_EPOCH.
Output: build/bin/nebulascreen and build/bin/nebulabeep (static ELF32 little-endian MIPS) and the
release zip. See Releases and deployment.
docker/Dockerfile defines a standalone toolchain image with the same Bootlin MIPS toolchain (plus an
aarch64 one), the replacement for upstream ballaswag/guppydev. Neither CI nor NebulaOS-firmware uses
it; if you build with it, the result is not the qualified NebulaOS build environment.
-
make buildruns the full sequence: clean and rebuildlibhv.a,libspdlog.a, then the app. -
make cleanremovesbuild/. - Without
CROSS_COMPILEthe Makefile adds-DSIMULATORand links-lSDL2. -
GUPPY_SMALL_SCREENselects thematerial_46icon set and the small-screen layout. -
NEBULASCREEN_VERSIONsets the version string (GUPPYSCREEN_VERSIONis still accepted). -
make testruns the host tests (Testing).
Get started
Get great prints
- Calibration guide (4 steps)
- Calibration walkthrough (A→Z)
- Bed tramming
- Load cell calibration (water bottle)
- Axis Twist Compensation
- Adaptive meshing + purge
- Square parts (Skew Correction)
- Quieter steppers (TMC Autotune)
Using the screen
Help
- Working on NebulaScreen
- Build from source
- Dev & simulator
- Architecture
- Configuration
- Releases & deployment
- Testing
- CI
- Contributing
- Publishing this wiki
NebulaOS