This is an application written in UEFI that takes a path from user and updates the bootsplash logo.
- Qemu
- UEFI
- EDK2
- ImageMagick
In our main loop, we check the user input. Depending on the command "rename Logo *new_path*" or "Rename *new_logo_path*" we either change the current Logo to the new path the user provides or create the new specified Logo. It's important to note that the user must first change the current Logo to a checkpoint they decide on before choosing a new logo. We decided to give the user the freedom to choose the checkpoint's name so that they have more control over the process and can change the logo to the original logo if needed.
We have some helper functions in order to achieve this goal.
The function below handles how we get the input from the user. We consider the buffer's content and its size to parse the result.
Here we print the options for the user. This way the user can check what options they have to choose from and what name to choose for the previous logo.
Finally, our main method lies in the function below where we rename the specified files to the given paths. (further details in the code folder)
First, download the zip file from the provided link in the Code section and unzip it. Then:
cd edk2
export FIRMWARE=./Build/OvmfX64/RELEASE_GCC5/FV/OVMF.fd
export DRIVE=./MdeModulePkg/Logo
mkdir -p $DRIVE
qemu-system-x86_64 -drive if=pflash,format=raw,readonly,file=Build/OvmfX64/RELEASE_GCC5/FV/OVMF_CODE.fd -drive if=pflash,format=raw,file=Build/OvmfX64/RELEASE_GCC5/FV/OVMF_VARS.fd -drive file=fat:rw:$DRIVE -net none
Now in the qemu environment:
fs0:
OurMess.efi
rename Logo prev.bmp
Rename cat1.bmp
Now build the program again.
build --platform=OvmfPkg/OvmfPkgX64.dsc --arch=X64 --buildtarget=RELEASE --tagname=GCC5
qemu-system-x86_64 -drive if=pflash,format=raw,readonly,file=Build/OvmfX64/RELEASE_GCC5/FV/OVMF_CODE.fd -drive if=pflash,format=raw,file=Build/OvmfX64/RELEASE_GCC5/FV/OVMF_VARS.fd -drive file=fat:rw:$DRIVE -net none
step6.mp4
As explained, now that we rebuild the program, it starts with a new boot splash image.