Configuring the boot splash screens

From Openmoko

(Difference between revisions)
Jump to: navigation, search
m (U-boot Splash)
m (U-boot Splash)
Line 26: Line 26:
 
*** sudo ../bin/dfu-util -a splash -R -D splash.gz
 
*** sudo ../bin/dfu-util -a splash -R -D splash.gz
 
** If the size of splash.gz is not exactly 0x5000, please see the next section.
 
** If the size of splash.gz is not exactly 0x5000, please see the next section.
 +
 +
=== Alternative instructions ===
 +
Step 1, 2, 4 and 5 of [http://lists.openmoko.org/pipermail/devel/2008-December/003891.html this post]. An example is [[Image:splash-logos.png]].
  
 
=== Modifying the size of the compressed splash image ===
 
=== Modifying the size of the compressed splash image ===

Revision as of 23:50, 10 March 2009

There are three boot screens (also called splashes or splash screens) as of 13 Nov. 2007. The U-Boot splash is displayed until the kernel takes over. Presumably the kernel will eventually display a splash while it boots. When userspace initializes, psplash displays a splash. Finally X displays a splash when it starts.

Contents

U-boot Splash

TODO: See improvements to the procedure here and update information below accordingly.

Original instructions

Is a raw framebuffer bitmap that is gzipped.

Here is a basic description: http://svn.openmoko.org/trunk/src/host/splash/README

Use dfu-util or NeoTool to send to the Openmoko.

Instructions which worked for me

The above instruction did not work, unfortunately, maybe there were for a previous release of u-boot. The following did work for me:

  • How to use the tools
    • First, make a PNG 480x640x8 (or just get the original picture from https://docs.openmoko.org/trac/raw-attachment/ticket/1735/boot_image.png, or the older splash screen from http://wiki.openmoko.org/images/c/c2/), and name it System_boot.png
    • Convert the System_boot.png into a compressed converted image file splash.gz, then download it to the splash partition (the neo1973 must be in u-boot mode, and you need dfu-util)
      • ./imghs.pl | gzip -9 > splash.gz
      • sudo ../bin/dfu-util -a splash -R -D splash.gz
    • If the size of splash.gz is not exactly 0x5000, please see the next section.

Alternative instructions

Step 1, 2, 4 and 5 of this post. An example is Splash-logos.png.

Modifying the size of the compressed splash image

NOTE... the README states you must issue two U-Boot commands to enable the flashed splash image to appear on the screen at boot:

setenv splashimage nand read.e 0x32000000 splash 0x5000\; unzip 0x32000000 0x33d00000 0x96000 saveenv

This is already a part of the U-Boot image received in the phone... however, if you make changes to your splash image, you may need to change the splashimage variable to compensate!

0x5000 is the (maximum) size of the compressed file -- the splash.gz that gets created. If you've made changes to your image you may have increased the compressed size; if it exceeds 0x5000 (20480) bytes, the entire image will not load unless you increase this value in your splashimage U-Boot environment variable.

Note that the framebuffer address on GTA02 is mapped to 0x8800000, not 0x33d00000

See also

This ticket has recent explanations: 1735.

Linux kernel

To Do

psplash

You need to recompile psplash, because the picture is hardcoded. There is a script in the source for psplash for making a new header file. On Ubuntu, you need the libgtk2.0-dev package to run the script.

make-image-header.sh my_image.png HAND mv my_image-img.h psplash-hand-img.h

Then add your custom header to the OpenEmbedded recipe (org.openembedded.dev/packages/psplash/files/openmoko/psplash-hand-img.h), or rebuild psplash by hand.

X splash

The X server accepts a -root-ppm option, which takes a plain old (raw) ppm file. Replace /usr/share/pixmaps/xsplash-vga.ppm on the phone or org.openembedded.dev/packages/xserver-kdrive-common/xserver-kdrive-common/openmoko/xsplash-vga.ppm in OpenEmbedded.

With more gory details, /etc/X11/Xserver ends with the lines:

# start off server in conventional location.                               
                                                               
ARGS="$ARGS -dpi 285 -screen 480x640 -hide-cursor -root-ppm
/usr/share/pixmaps/jsplash-vga.ppm vt1"                                    
   
#ARGS="$ARGS -dpi 285 -screen 480x640 -hide-cursor vt1"                    
                                                               
DISPLAY=':0'                                                               
                                                               
exec xinit /etc/X11/Xsession -- $XSERVER $DISPLAY $ARGS $* >/tmp/x.log 2>&1

The '-root-ppm' is the static splash screen.  

Following that, Xsession starts enlightenment, passing it $E_PROFILE as defined in /etc/enlightenment/default_profile.

E splash

/usr/share/enlightenment/data/init contains one or more .edj files that each define an animated splash init that appears next, and until enlightenment finishes loading.  The .edj file used is determined by $E_PROFILE.  So if default_profile contains E_PROFILE='-profile illume' then enlightenment will try to start up with illume_init.edj for the splash (the 'cylon' animated blip, or various other animations depending on image) and will try to use /usr/share/enlightenment/data/themes/illume.edj as the theme for illume.  If it's E_PROFILE='-profile fso' then it looks for fso_init.edj splash and fso.edj theme, etc.

See also

Personal tools

There are three boot screens (also called splashes or splash screens) as of 13 Nov. 2007. The U-Boot splash is displayed until the kernel takes over. Presumably the kernel will eventually display a splash while it boots. When userspace initializes, psplash displays a splash. Finally X displays a splash when it starts.

U-boot Splash

TODO: See improvements to the procedure here and update information below accordingly.

Original instructions

Is a raw framebuffer bitmap that is gzipped.

Here is a basic description: http://svn.openmoko.org/trunk/src/host/splash/README

Use dfu-util or NeoTool to send to the Openmoko.

Instructions which worked for me

The above instruction did not work, unfortunately, maybe there were for a previous release of u-boot. The following did work for me:

  • How to use the tools
    • First, make a PNG 480x640x8 (or just get the original picture from https://docs.openmoko.org/trac/raw-attachment/ticket/1735/boot_image.png, or the older splash screen from http://wiki.openmoko.org/images/c/c2/), and name it System_boot.png
    • Convert the System_boot.png into a compressed converted image file splash.gz, then download it to the splash partition (the neo1973 must be in u-boot mode, and you need dfu-util)
      • ./imghs.pl | gzip -9 > splash.gz
      • sudo ../bin/dfu-util -a splash -R -D splash.gz
    • If the size of splash.gz is not exactly 0x5000, please see the next section.

Modifying the size of the compressed splash image

NOTE... the README states you must issue two U-Boot commands to enable the flashed splash image to appear on the screen at boot:

setenv splashimage nand read.e 0x32000000 splash 0x5000\; unzip 0x32000000 0x33d00000 0x96000 saveenv

This is already a part of the U-Boot image received in the phone... however, if you make changes to your splash image, you may need to change the splashimage variable to compensate!

0x5000 is the (maximum) size of the compressed file -- the splash.gz that gets created. If you've made changes to your image you may have increased the compressed size; if it exceeds 0x5000 (20480) bytes, the entire image will not load unless you increase this value in your splashimage U-Boot environment variable.

Note that the framebuffer address on GTA02 is mapped to 0x8800000, not 0x33d00000

See also

This ticket has recent explanations: 1735.

Linux kernel

To Do

psplash

You need to recompile psplash, because the picture is hardcoded. There is a script in the source for psplash for making a new header file. On Ubuntu, you need the libgtk2.0-dev package to run the script.

make-image-header.sh my_image.png HAND mv my_image-img.h psplash-hand-img.h

Then add your custom header to the OpenEmbedded recipe (org.openembedded.dev/packages/psplash/files/openmoko/psplash-hand-img.h), or rebuild psplash by hand.

X splash

The X server accepts a -root-ppm option, which takes a plain old (raw) ppm file. Replace /usr/share/pixmaps/xsplash-vga.ppm on the phone or org.openembedded.dev/packages/xserver-kdrive-common/xserver-kdrive-common/openmoko/xsplash-vga.ppm in OpenEmbedded.

With more gory details, /etc/X11/Xserver ends with the lines:

# start off server in conventional location.                               
                                                               
ARGS="$ARGS -dpi 285 -screen 480x640 -hide-cursor -root-ppm
/usr/share/pixmaps/jsplash-vga.ppm vt1"                                    
   
#ARGS="$ARGS -dpi 285 -screen 480x640 -hide-cursor vt1"                    
                                                               
DISPLAY=':0'                                                               
                                                               
exec xinit /etc/X11/Xsession -- $XSERVER $DISPLAY $ARGS $* >/tmp/x.log 2>&1

The '-root-ppm' is the static splash screen.  

Following that, Xsession starts enlightenment, passing it $E_PROFILE as defined in /etc/enlightenment/default_profile.

E splash

/usr/share/enlightenment/data/init contains one or more .edj files that each define an animated splash init that appears next, and until enlightenment finishes loading.  The .edj file used is determined by $E_PROFILE.  So if default_profile contains E_PROFILE='-profile illume' then enlightenment will try to start up with illume_init.edj for the splash (the 'cylon' animated blip, or various other animations depending on image) and will try to use /usr/share/enlightenment/data/themes/illume.edj as the theme for illume.  If it's E_PROFILE='-profile fso' then it looks for fso_init.edj splash and fso.edj theme, etc.

See also