Changing the Boot Logo

Come hack your nest!
Post Reply
operator
Android 1.0
Posts: 3
Joined: Tue Jul 08, 2014 10:06 am

Changing the Boot Logo

Post by operator » Thu Jul 10, 2014 12:38 pm

So the GTVHacker logo is pretty sweet and these guys clearly deserve credit for the work that was done.

Maybe you want to display your own custom boot logo though? Here's how:

Since the build environment to date is Ubuntu 12.04, we'll assume this as a starting point. Other Linux distros may work just as well and perhaps someone can modify these instructions of Cygwin but I haven't touched a Windows box in years so I really can't be of much help there.

Let's start by getting some software we'll need moving forward.

Code: Select all

sudo apt-get install netpbm gimp
We'll use Gimp to create our new boot logo, so go ahead and fire it up. I'll wait.... Good.
Here's a png you can use as a template to create your logo
http://i.imgur.com/tETSXMx.png

I'm sure you're a regular Jackson Pollock, but hey, keep the colors simple and this will go much smoother.
After you've created your masterpiece, you may need to export it from Gimp as a png. Save it somewhere easy to find.

Fire up a terminal and navigate the directory you just saved your png to.
Run the following command:

Code: Select all

pngtopnm YourBadassNestLogo.png | ppmquant -fs 223 | pnmtoplainpnm > logo_badass_clut244.ppm
Did that work? Then, nice job bro. If it didn't maybe check here for a bit more info: http://www.gentoo-wiki.info/HOWTO_Linux_Logo_Hack

I'm assuming you've already cloned the git repo for the DFU Attack. If you haven't, you can find it over here: https://github.com/gtvhacker/NestDFUAttack
If you're not a git uber-expert, join the club. Cloning a repo isn't hard but I'm not going to explain it here. Here's a resource that might help: http://githowto.com/
Worse case scenario you can probably just download the ZIP from the aforementioned GTVHacker github page and work from there.

We'll want to place our newly created pretty-pretty-masterpiece (pretty sure that's what the ppm extension is short for) in a very specific location.
From within the NestDFUAttack directory, navigate to /Dev/linux/drivers/video/logo
Place your image here. You'll notice lots of other logos, including the GTVHacker logo.
If you have already run the build script, you might also notice that there are .c and .o files associated with each of the images.
Either way, these will get generated when we build/rebuild, though we must first ensure we tell our compiler to do so.

Open up the Makefile in the /Dev/linux/drivers/video/logo directory with your favorite text editor. I like sublime or vim; feel free to hate me for that if you like.
You'll notice a large list right at the beginning of the Makefile, ending with the line:

Code: Select all

obj-$(CONFIG_LOGO_GTVHACKER_CLUT224)	+= logo_gtvhacker_clut224.o
Go ahead and append a line under this with the info for your own logo. Something like:

Code: Select all

obj-$(CONFIG_LOGO_BADASS_CLUT224)	+= logo_badass_clut224.o
Save that [stuff].

Now open up logo.c in the same directory.
Way down at the bottom you'll notice:

Code: Select all

#ifdef CONFIG_LOGO_GTVHACKER_CLUT224
		/* GTVHACKER logo */
		logo = &logo_gtvhacker_clut224;
#endif
Copy that block and paste it below.
Edit it to include the info you added to the Makefile, such as:

Code: Select all

#ifdef CONFIG_LOGO_BADASS_CLUT224
		/* BADASS logo */
		logo = &logo_badass_clut224;
#endif
Save that [stuff].

Similarly, we're going to edit Kconfig in the same direcotry:

Code: Select all

config LOGO_GTVHACKER_CLUT224
	bool "224-color GTVHACKER logo"
	depends on MACH_DIAMOND || MACH_J49
	default y
Copy, paste, edit, save that [stuff].

Code: Select all

config LOGO_SAIFE_CLUT224
	bool "224-color SAIFE logo"
	depends on MACH_DIAMOND || MACH_J49
	default y
Now navigate to /Dev/linux/arch/arm/configs and open gtvhacker_defconfig
Do a search, or scroll waaaaayyyyyy down to the Console display driver support section.
You'll notice the following un-commented line:

Code: Select all

CONFIG_LOGO_GTVHACKER_CLUT224=y
Change that to your own stuff, just as we did in logo.c

Code: Select all

CONFIG_LOGO_BADASS_CLUT224=y
Finally, navigate to /Dev/linux/include/linux and open linux_logo.h
Find

Code: Select all

extern const struct linux_logo logo_gtvhacker_clut224;
and append your logo's information below it.

Code: Select all

extern const struct linux_logo logo_badass_clut224;
Save that [stuff].

Sweet. Now when we run build or new fancy image will be included at the boot logo.

Post Reply
 

 

cron

Login  •  Register