Animated splash screen

Hi,

I’m running torizon os on verdin imx8mp.

I am able to change splash screen with single png with the help of OStree reference as mentioned on Splash Screen on Torizon OS | Toradex Developer Center .

What I want to play an animation with sequence of pngs. Which I’ll source from GitHub - adi1090x/plymouth-themes: A huge collection (80+) of plymouth themes ported from android bootanimations or my own custom pngs.

I tried placing/creating folder in /usr/share/plymouth/themes but cannot as it is a read only folder.

How to use OStree commits to play sequence of pngs at boot screen?

Regards
Samarth

Hi, I’m the Toradex AI Assistant. I’m in early beta, and I would appreciate your feedback.
The Toradex Support team will follow up with you shortly!

Did you like my answer?

:+1: :-1:


Hello,

For implementing an animated splash screen on a TorizonCore system running on a Verdin iMX8MP module, you’ll need to customize the OS image to include your animation. Since TorizonCore uses OSTree for system updates and version control, direct modifications to the file system (like adding files to /usr/share/plymouth/themes) are not persistent across updates. Instead, you should integrate your custom splash screen during the image build process using Yocto or a TorizonCore Builder customization.

Here’s a high-level approach to achieve this:

  1. Prepare Your Animation: Ensure your sequence of PNGs is ready and optimized for the display used with your Verdin iMX8MP module. The animation should be compatible with Plymouth, the application that manages the splash screen in many Linux distributions, including TorizonCore.

  2. Customize the Plymouth Theme: Use the Plymouth themes from the GitHub repository you mentioned or create your own. The theme should define how your sequence of PNGs is displayed during boot. Plymouth themes are typically stored in /usr/share/plymouth/themes/. You’ll need to package your theme into a format that can be included in the TorizonCore build process.

  3. Integrate with Yocto: If you’re building TorizonCore from source using Yocto, you can create a custom recipe to include your Plymouth theme in the image. This involves creating a BitBake recipe that installs your theme into the correct directory within the image being built. You’ll also need to ensure Plymouth is configured to use your theme by default.

  4. Use TorizonCore Builder: TorizonCore Builder is a tool provided by Toradex that simplifies the customization of TorizonCore images without the need to fully rebuild the OS using Yocto. You can use it to overlay your custom Plymouth theme onto the base TorizonCore image. This involves creating an overlay directory with your theme files structured as they should appear on the target filesystem and then applying this overlay to the base image.

  5. Testing and Deployment: After integrating your animated splash screen, build your custom TorizonCore image and deploy it to your Verdin iMX8MP module. Test the boot process to ensure the animation plays as expected.

Remember, since direct modifications to the filesystem are not persistent in TorizonCore due to its use of OSTree, these customizations need to be part of the image build process. This ensures that your animated splash screen remains intact across system updates.

Best regards,
Tor

Please, also check if these links can help you solve your problem:

SBOM | Toradex Developer Center.

I would like to go without a custom os build and Add a Custom Splash Screen directly from Torizon OS. @jeremias.tx , can you please help me out with this.

Greetings @Sudharshan,

I don’t believe you can solve this without a custom OS build. Even if /usr was writable, I don’t think placing the files here would be enough. Torizon OS uses an initramfs. To have the splash screen start early in the boot process Plymouth gets executed from the initramfs. This would mean to affect the boot splash screen you would need to have a custom initramfs with your new Plymouth themes embedded in it.

Best Regards,
Jeremias

Hi @jeremias.tx
When you say custom OS do you mean a yocto build or a custom os build with Torizon core builder?

Regards

It would most likely need something on the Yocto side. TorizonCore Builder can only customize the splash screen by adding a static image as the splash screen. The tool is not capable of adding a whole new theme to Plymouth to use. That’s why my current thought is that this would need to be customized on the Yocto level, as there’s no other mechanism at the moment.

I suppose you could try to extract the initramfs from the Torizon OS image. Then manually unpack, customize, and re-pack the initramfs with the new Plymouth theme. Though I can’t say I know the exact process for this and it would probably be an error-prone method. At that point a Yocto build may be of similar effort and complexity.

Is this an urgent requirement for your product?

Best Regards,
Jeremias

1 Like

As a user that’s actually done this via TCB, I concur it is not for the faint of heart, since if you do it wrong it will render your device unable to boot - but it is indeed possible. (In fact, if you look at the ostree-customize-plymouth script that is used by TCB to change the static image, it does something similar.) There’s a high-level overview of the principles in this thread, but of course it is not endorsed nor supported by Toradex, so your mileage may vary: Postioning rotating Cursor in splash screen

2 Likes