This software repository represents initial efforts to learn about bare metal
programming using C and ARM assembly with the Raspberry Pi Zero as the target
hardware. The binary produced is a kernel image that is intended to replace the
kernel.img
file that is shipped with the current Raspberry Pi firmware.
This is a work in progress and is intended as a learning exercise more than
anything. Presently, the kernel initializes a 1920x1080, 32-bit depth frame
buffer and then outputs Hello, world!
.
The code contained is intended to be cross-compiled for ARM using the GNU
Embedded Toolchain for ARM, arm-none-eabi
and the GNU C Compiler, gcc
.
The default make target will compile a kernel image at dist/kernel.img
The kernel image produced is intended to replace the kernel.img
distributed
with the Raspberry Pi. Assuming the Raspberry Pi firmware is already installed
on a storage medium, installation only consists of replacing the kernel.img
file with the new copy compiled from this code.
Working in an environment without an operating system is totally new for me and I would not have been able to get very far at all without the wealth of resources available online. The resources below were invaluable for me and hopefully will be to anyone viewing this who wants to learn more about bare metal programming on the pi:
University of Cambridge - Baking Pi