s-matyukevich / raspberry-pi-os
Learning operating system development using Linux kernel and Raspberry Pi
AI Architecture Analysis
This repository is indexed by RepoMind. By analyzing s-matyukevich/raspberry-pi-os in our AI interface, you can instantly generate complete architecture diagrams, visualize control flows, and perform automated security audits across the entire codebase.
Our Agentic Context Augmented Generation (Agentic CAG) engine loads full source files into context, avoiding the fragmentation of traditional RAG systems. Ask questions about the architecture, dependencies, or specific features to see it in action.
Repository Summary (README)
PreviewLearning operating system development using Linux kernel and Raspberry Pi
This repository contains a step-by-step guide that teaches how to create a simple operating system (OS) kernel from scratch. I call this OS Raspberry Pi OS or just RPi OS. The RPi OS source code is largely based on Linux kernel, but the OS has very limited functionality and supports only Raspberry PI 3.
Each lesson is designed in such a way that it first explains how some kernel feature is implemented in the RPi OS, and then it tries to demonstrate how the same functionality works in the Linux kernel. Each lesson has a corresponding folder in the src directory, which contains a snapshot of the OS source code at the time when the lesson had just been completed. This allows the introduction of new concepts gracefully and helps readers to follow the evolution of the RPi OS. Understanding this guide doesn't require any specific OS development skills.
For more information about project goals and history, please read the Introduction. The project is still under active development, if you are willing to participate - please read the Contribution guide.
<p> <a href="https://twitter.com/RPi_OS" target="_blank"> <img src="https://raw.githubusercontent.com/s-matyukevich/raspberry-pi-os/master/images/twitter.png" alt="Follow @RPi_OS on twitter" height="34" > </a> <a href="https://www.facebook.com/groups/251043708976964/" target="_blank"> <img src="https://raw.githubusercontent.com/s-matyukevich/raspberry-pi-os/master/images/facebook.png" alt="Follow Raspberry Pi OS on facebook" height="34" > </a> <a href="https://join.slack.com/t/rpi-os/shared_invite/enQtNDQ1NTg2ODc1MDEwLWVjMTZlZmMyZDE4OGEyYmMzNTY1YjljZjU5YWI1NDllOWEwMjI5YzVkM2RiMzliYjEzN2RlYmUzNzBiYmQyMjY" target="_blank"> <img src="https://raw.githubusercontent.com/s-matyukevich/raspberry-pi-os/master/images/slack.png" alt="Join Raspberry Pi OS in slack" height="34" > </a> <a href="https://www.producthunt.com/upcoming/raspberry-pi-os" target="_blank"> <img src="https://raw.githubusercontent.com/s-matyukevich/raspberry-pi-os/master/images/subscribe.png" alt="Subscribe for updates" height="34" > </a> </p>Table of Contents
- Introduction
- Contribution guide
- Prerequisites
- Lesson 1: Kernel Initialization
- 1.1 Introducing RPi OS, or bare metal "Hello, world!"
- Linux
- 1.2 Project structure
- 1.3 Kernel build system
- 1.4 Startup sequence
- 1.5 Exercises
- Lesson 2: Processor initialization
- Lesson 3: Interrupt handling
- 3.1 RPi OS
- Linux
- 3.2 Low level exception handling
- 3.3 Interrupt controllers
- 3.4 Timers
- 3.5 Exercises
- Lesson 4: Process scheduler
- 4.1 RPi OS
- Linux
- 4.2 Scheduler basic structures
- 4.3 Forking a task
- 4.4 Scheduler
- 4.5 Exercises
- Lesson 5: User processes and system calls
- Lesson 6: Virtual memory management
- Lesson 7: Signals and interrupt waiting (To be done)
- Lesson 8: File systems (To be done)
- Lesson 9: Executable files (ELF) (To be done)
- Lesson 10: Drivers (To be done)
- Lesson 11: Networking (To be done)