Skip to content

hoangdesu/Bare-metal-OS-RaspberryPi

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

5 Commits
 
 
 
 
 
 
 
 

Repository files navigation

Bare metal OS on Raspberry Pi 3 Model B+

Table of Contents

Project Description

This project includes 2 versions of bare metal operating systems for the Raspberry Pi 3 Model B+. Version 1 is more about interracting with the Rasp using UART and Mailbox, while Version deals more with the graphical interface.

Version 1

This version mainly uses the CLI to interract with the OS using the provided commands. Compile and run the image, type help to see all the available commands

Welcome screen with help command

Welcome screen with help command

Terminal text and background colors

Set terminal text and background colors

Draw graphic on screen

Draw graphic on screen

Version 2

This version concerns more about the Graphical User Interface, allowing the user to control what being displayed on screen, and even play a mini game called "Rescue the Pink-cess". Use the CLI to control the screen

Welcome screen with text display

Welcome screen with text display

Small image

Display small image

Scrollable large image

User can use WASD to scroll with large image

Playing video

Pressing 4 will play this gif on QEMU screen

Scrollable large image

"Rescue the Pink-cess" game

Setting up Development environment for MacOS

Since I am using a Mac computer, my development environment is different from a Windows machine and requires different configurations. I prefer using VSCode as my code editor over other IDEs for its elegance and functionalities. Install the following toolchain for developing ARM on a Mac using Brew (package manager):

  • GNU Embedded Toolchain for ARM (Mac 64-bit): brew tap SergioBenitez/osxct and brew install aarch64-none-elf
  • Make tool: brew install make
  • QEMU: brew install qemu
  • LLVM/Clang: brew install --with-toolchain llvm
  • To run Raspberry Pi OS, install Raspberry Pi Desktop and run image using Parallels Desktop (or other VMs)

How to run project?

You would need a Raspberry Pi 3B+ board to run the OS. However, you can also use QEMU to emulate the Rasp on your PC. You will also need make build tool to compile or run QEMU commands automatically. In every folder, you will find an already built image kernel8.img that you can use make command to run it directly.

Demo video

Version 2:

Watch on Youtube!

Acknowledgement

Connect with me

If you find this project useful, you can let me know. I would love to hear about it! ✌️

About

Bare metal operating system for Raspberry Pi 3 Model B+

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages