summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorunitexe <unitexe70@gmail.com>2026-02-08 11:41:19 -0600
committerunitexe <unitexe70@gmail.com>2026-02-08 11:41:39 -0600
commit019a45d52dc06c812c3ba74941ee692df6a72e21 (patch)
tree2f2eb9784cf5d7f94725216392037206d245c407
parente9ef477e623a397c3cae8e1e2d676046069cbb01 (diff)
U-boot splash for raspberrypi3-64
-rw-r--r--meta-unit-core/dynamic-layers/unit-graphics-layer/recipes-unit/images/core-image-unit.bbappend3
-rw-r--r--meta-unit-graphics/README.md11
-rw-r--r--meta-unit-graphics/conf/layer.conf2
-rw-r--r--meta-unit-graphics/dynamic-layers/raspberrypi/recipes-bsp/u-boot/files/0001-tweak-rpi-environment.patch51
-rw-r--r--meta-unit-graphics/dynamic-layers/raspberrypi/recipes-bsp/u-boot/files/splash.cfg8
-rw-r--r--meta-unit-graphics/dynamic-layers/raspberrypi/recipes-bsp/u-boot/u-boot_%.bbappend4
-rw-r--r--meta-unit-graphics/recipes-bsp/u-boot-splash/files/yocto_project_logo_white_800x480_24bpp.bmp.gzbin0 -> 27081 bytes
-rw-r--r--meta-unit-graphics/recipes-bsp/u-boot-splash/u-boot-splash.bb21
8 files changed, 100 insertions, 0 deletions
diff --git a/meta-unit-core/dynamic-layers/unit-graphics-layer/recipes-unit/images/core-image-unit.bbappend b/meta-unit-core/dynamic-layers/unit-graphics-layer/recipes-unit/images/core-image-unit.bbappend
index 379ddca..e46a10d 100644
--- a/meta-unit-core/dynamic-layers/unit-graphics-layer/recipes-unit/images/core-image-unit.bbappend
+++ b/meta-unit-core/dynamic-layers/unit-graphics-layer/recipes-unit/images/core-image-unit.bbappend
@@ -3,3 +3,6 @@ inherit fix-kiosk-home-dir-ownership
IMAGE_FEATURES:append = " hwcodecs"
IMAGE_INSTALL:append = " packagegroup-unit-kiosk"
+
+IMAGE_INSTALL:append:raspberrypi3-64 = " u-boot-splash"
+IMAGE_BOOT_FILES:append:raspberrypi3-64 = " yocto_project_logo_white_800x480_24bpp.bmp.gz"
diff --git a/meta-unit-graphics/README.md b/meta-unit-graphics/README.md
new file mode 100644
index 0000000..76867e8
--- /dev/null
+++ b/meta-unit-graphics/README.md
@@ -0,0 +1,11 @@
+# meta-unit-graphics
+
+## U-boot splash
+The u-boot splash has bee configured to show the [yocto project logo](https://commons.wikimedia.org/wiki/File:Yocto_Project_logo.svg).
+
+To convert the logo to a u-boot compatible bitmap, the following command was used:
+```bash
+convert yocto_project_logo.png -resize 700x400 -background white -gravity center -extent 800x480 -depth 8 -type TrueColor -compress none BMP3:yocto_project_logo_800x480_24bpp.bmp
+```
+
+The dimensions for `resize` and `extent` are device specific.
diff --git a/meta-unit-graphics/conf/layer.conf b/meta-unit-graphics/conf/layer.conf
index b87c882..27f9afb 100644
--- a/meta-unit-graphics/conf/layer.conf
+++ b/meta-unit-graphics/conf/layer.conf
@@ -13,6 +13,8 @@ LAYERSERIES_COMPAT_unit-graphics-layer = "whinlatter"
BBFILES_DYNAMIC += " \
flutter-layer:${LAYERDIR}/dynamic-layers/flutter-layer/recipes-*/*/*.bb \
flutter-layer:${LAYERDIR}/dynamic-layers/flutter-layer/recipes-*/*/*.bbappend \
+ raspberrypi:${LAYERDIR}/dynamic-layers/raspberrypi/recipes-*/*/*.bb \
+ raspberrypi:${LAYERDIR}/dynamic-layers/raspberrypi/recipes-*/*/*.bbappend \
"
UNIT_GRAPHICS_LAYERDIR = "${LAYERDIR}"
diff --git a/meta-unit-graphics/dynamic-layers/raspberrypi/recipes-bsp/u-boot/files/0001-tweak-rpi-environment.patch b/meta-unit-graphics/dynamic-layers/raspberrypi/recipes-bsp/u-boot/files/0001-tweak-rpi-environment.patch
new file mode 100644
index 0000000..97b07ac
--- /dev/null
+++ b/meta-unit-graphics/dynamic-layers/raspberrypi/recipes-bsp/u-boot/files/0001-tweak-rpi-environment.patch
@@ -0,0 +1,51 @@
+From b4b7380aab0ae3ff590e9627c59fbf5b07f47ef6 Mon Sep 17 00:00:00 2001
+From: unitexe <unitexe70@gmail.com>
+Date: Sun, 8 Feb 2026 11:27:08 -0600
+Subject: [PATCH] tweak rpi environment
+
+- Restrict boot targets to SD card
+- Add custom splash support
+- Disable stdout & stderr vidconsole so it doesn't write over splash
+
+Upstream-Status: Inappropriate [embedded-specific]
+---
+ board/raspberrypi/rpi/rpi.env | 19 ++++++++++++++++---
+ 1 file changed, 16 insertions(+), 3 deletions(-)
+
+diff --git a/board/raspberrypi/rpi/rpi.env b/board/raspberrypi/rpi/rpi.env
+index 9ac9d6768ca..b93b731406a 100644
+--- a/board/raspberrypi/rpi/rpi.env
++++ b/board/raspberrypi/rpi/rpi.env
+@@ -6,8 +6,8 @@ dhcpuboot=usb start; dhcp u-boot.uimg; bootm
+
+ /* Environment */
+ stdin=serial,usbkbd
+-stdout=serial,vidconsole
+-stderr=serial,vidconsole
++stdout=serial
++stderr=serial
+
+ /* DFU over USB/UDC */
+ #ifdef CONFIG_CMD_DFU
+@@ -77,4 +77,17 @@ pxefile_addr_r=0x05500000
+ fdt_addr_r=0x05600000
+ ramdisk_addr_r=0x05700000
+
+-boot_targets=mmc usb pxe dhcp
++/*
++ * Not interested in booting from anything but SD card.
++ */
++boot_targets=mmc
++
++/*
++ * Custom splash screen. Using 0x05800000 gives ramdisk_add_r ~1MB
++ * before the splash and is well within the bootm_size limit. No
++ * alignment is necessary since image size is the same size as the
++ * target LCD.
++ */
++splashfile=yocto_project_logo_white_800x480_24bpp.bmp.gz
++splashimage=0x05800000
++splashsource=mmc_fs
+--
+2.43.0
+
diff --git a/meta-unit-graphics/dynamic-layers/raspberrypi/recipes-bsp/u-boot/files/splash.cfg b/meta-unit-graphics/dynamic-layers/raspberrypi/recipes-bsp/u-boot/files/splash.cfg
new file mode 100644
index 0000000..6420088
--- /dev/null
+++ b/meta-unit-graphics/dynamic-layers/raspberrypi/recipes-bsp/u-boot/files/splash.cfg
@@ -0,0 +1,8 @@
+CONFIG_CMD_BMP=y
+CONFIG_BMP=y
+CONFIG_BMP_24BPP=y
+CONFIG_HIDE_LOGO_VERSION=y
+CONFIG_SPLASH_SCREEN=y
+CONFIG_SPLASH_SOURCE=y
+CONFIG_VIDEO_BMP_GZIP=y
+CONFIG_VIDEO_LOGO_MAX_SIZE=0x120000
diff --git a/meta-unit-graphics/dynamic-layers/raspberrypi/recipes-bsp/u-boot/u-boot_%.bbappend b/meta-unit-graphics/dynamic-layers/raspberrypi/recipes-bsp/u-boot/u-boot_%.bbappend
new file mode 100644
index 0000000..0cb8d8b
--- /dev/null
+++ b/meta-unit-graphics/dynamic-layers/raspberrypi/recipes-bsp/u-boot/u-boot_%.bbappend
@@ -0,0 +1,4 @@
+FILESEXTRAPATHS:prepend := "${THISDIR}/files:"
+
+SRC_URI:append = " file://splash.cfg"
+SRC_URI:append = " file://0001-tweak-rpi-environment.patch"
diff --git a/meta-unit-graphics/recipes-bsp/u-boot-splash/files/yocto_project_logo_white_800x480_24bpp.bmp.gz b/meta-unit-graphics/recipes-bsp/u-boot-splash/files/yocto_project_logo_white_800x480_24bpp.bmp.gz
new file mode 100644
index 0000000..d603f12
--- /dev/null
+++ b/meta-unit-graphics/recipes-bsp/u-boot-splash/files/yocto_project_logo_white_800x480_24bpp.bmp.gz
Binary files differ
diff --git a/meta-unit-graphics/recipes-bsp/u-boot-splash/u-boot-splash.bb b/meta-unit-graphics/recipes-bsp/u-boot-splash/u-boot-splash.bb
new file mode 100644
index 0000000..7e5b318
--- /dev/null
+++ b/meta-unit-graphics/recipes-bsp/u-boot-splash/u-boot-splash.bb
@@ -0,0 +1,21 @@
+SUMMARY = "Deploy u-boot splash image"
+LICENSE = "MIT"
+LIC_FILES_CHKSUM = "file://${UNIT_GRAPHICS_LAYERDIR}/LICENSE;md5=a77c12e0c0e8a14cebb1494195720ccc"
+
+inherit deploy
+
+SRC_URI = "\
+ file://yocto_project_logo_white_800x480_24bpp.bmp.gz;unpack=0 \
+"
+
+S = "${UNPACKDIR}"
+
+do_deploy() {
+ install -d ${DEPLOY_DIR_IMAGE}
+ install -m 0644 ${S}/yocto_project_logo_white_800x480_24bpp.bmp.gz ${DEPLOY_DIR_IMAGE}/yocto_project_logo_white_800x480_24bpp.bmp.gz
+}
+
+addtask deploy before do_build after do_compile
+
+# The recipe just deploys a file it doesn't install anything to rootfs
+ALLOW_EMPTY:${PN} = "1"