Search code examples
videoraspberry-pi3splash-screenu-boot

Show splash screen during u-boot using bmp command on Raspberry CM3+


I'm trying to show a bootscreen during the boot of my Yocto-build distribution. This runs on a Compute Module 3+ (CM3+). Here's what I figured out so far:

  • Compile u-boot with CONFIG_CMD_BMP=y and CONFIG_DM_VIDEO=y
  • Place a bitmap image on the boot partition and load it with fatload mmc 0:1 $loadaddr /splash.bmp
  • Check that the bitmap was loaded correctly:
U-Boot> bmp info $loadaddr
Image size    : 480 x 800
Bits per pixel: 24
Compression   : 0

The last step would be to display it, but bmp display $loadaddr 0 0 simply does nothing and also spits out no error. I found out that this is due to this line here returns a 0. This seems to indicate that there is no video support for my board.

Now to the actual questions:

  • What could I do to enable video support for u-boot on the the Pi?
  • Is there generic HDMI video output? If yes, how do I enable it?
  • Do I need to supply my own video driver implementation?
  • I see the log output over the vidconsole. How is that working?

Also my u-boot version is:

U-Boot> version
U-Boot 2019.01-dirty (Jan 01 1970 - 00:00:00 +0000)

arm-poky-linux-gnueabi-gcc (GCC) 8.3.0
GNU ld (GNU Binutils) 2.32.0.20190204

EDIT: Looking a bit more, there is actually a bcm2835 video driver. It can be activated via CONFIG_VIDEO_BCM2835=y, but it doesn't seem to load. This is most likely because I don't get the right device tree nodes passed. Any clues why that could be?

EDIT 2: False alarm, the video driver loads fine.


Solution

  • Turns out I had a bitmap with 24 bit, so I also needed to define CONFIG_BMP_24BPP so the relevant support code is compiled-in (see here). Better error handling code would have been great here. :)