Hi all, Not sure if this is the right place to post it -- about 6 years ago I put together a module which displays an ASCII splash screen on boot (rather than the graphical splash_pcx and splash_bmp modules). We have been running it in production since that time without issue. With the the code slush for 9.0 on the horizon, I thought it might again be worth trying to see if someone is prepared to get this into the tree so others can benefit from it. I have a PR open, kern/143370, which includes the patch for the module; it is against 7.0 but has been used largely unmodified since 4.x days. It currently builds on 8.x still fine as we are running it in production on 8.x for $WORK. Summary of instructions from my previous post about this from ~18mths ago: In case the list eats the patch, you can grab a copy of it here: http://www.mawer.org/freebsd/splash_txt.patch To give you an idea of what it looks like, here is a screenshot of a quick generic FreeBSD splash screen I put together: http://www.mawer.org/freebsd/splash_txt_1.png http://www.mawer.org/freebsd/splash_txt_2.png If you'd like to try it for yourself then the process to build it should be something like this: 1. Download the attached patch 2. Create the required folders before applying the patch -- cd /usr/src && mkdir sys/modules/splash/txt 3. Apply the patch -- patch < splash_txt.patch 4. Build the module -- cd sys/modules/splash/txt && make && make install Once that's completed, you can configure it by adding the following to loader.conf: splash_txt_load="YES" bitmap_load="YES" bitmap_name="/boot/freebsd.bin" I have uploaded two sample boot splash screens at http://www.mawer.org/freebsd/freebsd1.bin and http://www.mawer.org/freebsd/freebsd2.bin . The files can be produced using TheDraw and saving in its Binary file format, which consists of a sequence of 2 byte pairs. The first byte in a pair is the character to draw on the screen, and the second is the colour/display attributes to draw the character with. If anyone else would like to try this out and has any feedback, or if someone thinks it may be of interest to integrate into the tree please let me know ... Otherwise if anyone would like to help push this into the tree in time for 9.0 would be great. It should be safe to MFC to 8.x as well -- as I said we've been running it ever since 4.x days. I am sure others out there would gain at least some (cosmetic) benefits from this! -- Antony
Torfinn Ingolfsen
2011-Jun-29 17:04 UTC
kern/143370: splash_txt ASCII splash screen module
On Wed, 29 Jun 2011 22:50:15 +1000 Antony Mawer <lists@mawer.org> wrote:> Hi all, > > Not sure if this is the right place to post it -- about 6 years ago I > put together a module which displays an ASCII splash screen on boot > (rather than the graphical splash_pcx and splash_bmp modules). We have > been running it in production since that time without issue.So, the difference between this and loader.conf's loader_logo construct is that a) this is a proper splash screen module b) you can / must design your splash screen with a separate program (compared to write / modify Forth code) Is my understanding correct? -- Torfinn
Antony Mawer wrote:> Not sure if this is the right place to post it -- about 6 years ago I > put together a module which displays an ASCII splash screen on boot > (rather than the graphical splash_pcx and splash_bmp modules).As a user, I think this is rather cool; at least it is more useful for me than bmp/pcx splash modules, as I don't want to load vesa. Hm... Can you center the image if the display size is other than 80x25? Or try to temporarily change the video mode? It looks a bit misplaced in 80x50. Also, this would be 2x as cool if you could animate the splash. For example, if the supplied bitmap is 80x50, you could treat that as 2 frames, and cycle through them periodically (I assume that splash modules work the same way as saved modules do: the main function is called a few times per second, so you can update the screen there). BTW, in txt_init you currently check for data_size <= 0; you should also check for data_size < BIN_IMAGE_WIDTH * BIN_IMAGE_HEIGHT * 2, since if the bitmap is smaller, you'll draw garbage on the screen.> I have uploaded two sample boot splash screens at > http://www.mawer.org/freebsd/freebsd1.bin and > http://www.mawer.org/freebsd/freebsd2.bin . The files can be produced > using TheDraw and saving in its Binary file format, which consists of > a sequence of 2 byte pairs. The first byte in a pair is the character > to draw on the screen, and the second is the colour/display attributes > to draw the character with.As a side note, these images can also be made from video buffer dumps that vidcontrol produces like this: vidcontrol -p < /dev/ttyv0 | tail -c +13 > screenshot.bin (Substitute ttyv0 for the tty you want to take a picture of; the tty should be in 80x25 mode).