![Buzz Logo Buzz Logo](https://private-user-images.githubusercontent.com/67273282/335952898-22e46b24-26ef-4a0d-930f-22e857af5d55.png?jwt=eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpc3MiOiJnaXRodWIuY29tIiwiYXVkIjoicmF3LmdpdGh1YnVzZXJjb250ZW50LmNvbSIsImtleSI6ImtleTUiLCJleHAiOjE3MjQ4MDI0NDAsIm5iZiI6MTcyNDgwMjE0MCwicGF0aCI6Ii82NzI3MzI4Mi8zMzU5NTI4OTgtMjJlNDZiMjQtMjZlZi00YTBkLTkzMGYtMjJlODU3YWY1ZDU1LnBuZz9YLUFtei1BbGdvcml0aG09QVdTNC1ITUFDLVNIQTI1NiZYLUFtei1DcmVkZW50aWFsPUFLSUFWQ09EWUxTQTUzUFFLNFpBJTJGMjAyNDA4MjclMkZ1cy1lYXN0LTElMkZzMyUyRmF3czRfcmVxdWVzdCZYLUFtei1EYXRlPTIwMjQwODI3VDIzNDIyMFomWC1BbXotRXhwaXJlcz0zMDAmWC1BbXotU2lnbmF0dXJlPWNmNzBhYmIyOTI2NWVmNjNmNjJhZDk5OWNmZmI3YTgzYmQ3NTg0MTIyZjM1NmNlZDQ5NDA5OWJjOTUxZGU0YTQmWC1BbXotU2lnbmVkSGVhZGVycz1ob3N0JmFjdG9yX2lkPTAma2V5X2lkPTAmcmVwb19pZD0wIn0.9WPnE0AqEpQLwkVZkvGlc7L8wSbYVMliJuTtPVU41MI)
![Buzz Demo Buzz Demo](https://private-user-images.githubusercontent.com/67273282/343907291-92ede007-b87f-4993-b111-982da3ac916e.gif?jwt=eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpc3MiOiJnaXRodWIuY29tIiwiYXVkIjoicmF3LmdpdGh1YnVzZXJjb250ZW50LmNvbSIsImtleSI6ImtleTUiLCJleHAiOjE3MjQ4MDI0NDAsIm5iZiI6MTcyNDgwMjE0MCwicGF0aCI6Ii82NzI3MzI4Mi8zNDM5MDcyOTEtOTJlZGUwMDctYjg3Zi00OTkzLWIxMTEtOTgyZGEzYWM5MTZlLmdpZj9YLUFtei1BbGdvcml0aG09QVdTNC1ITUFDLVNIQTI1NiZYLUFtei1DcmVkZW50aWFsPUFLSUFWQ09EWUxTQTUzUFFLNFpBJTJGMjAyNDA4MjclMkZ1cy1lYXN0LTElMkZzMyUyRmF3czRfcmVxdWVzdCZYLUFtei1EYXRlPTIwMjQwODI3VDIzNDIyMFomWC1BbXotRXhwaXJlcz0zMDAmWC1BbXotU2lnbmF0dXJlPThjMGVhYWM4N2EwNzgyMjhmNjBhOGU2M2UzNjc5N2QxYmM2YWNkNWM5ZDM5NzU5ZTA2YzVmYTAyMWU1MzI5OTMmWC1BbXotU2lnbmVkSGVhZGVycz1ob3N0JmFjdG9yX2lkPTAma2V5X2lkPTAmcmVwb19pZD0wIn0.y2ysTd0ggQT14Cc-iZsCps64gUF-EOQX44vziYkKYjU)
The operating system can only be compiled on Unix machines. If you happen to be using a different system, you can download the binary from here.
Make sure you have all of the listed bellow installed before continuing to the next step.
Requirement | Installation |
---|---|
Qemu | sudo apt install qemu-system |
GCC | sudo apt install build-essential |
Make | sudo apt install build-essential |
Python3 | sudo apt install python3 |
Clone the repository into your machine and compile with Make.
git clone https://github.com/eylon-44/Buzz-OS
cd Buzz-OS
make
Inside the project's root directory, enter make run
. The system will boot up and greet you with a terminal program.
Quick Tips
β’ Use thehelp
command to get information about available commands β’ Execute a program by inputing its path β’ Open a tab withCtrl+Shift+T
, close it withCtrl+Shift+W
, and switch to a different one withAlt+[tab index]
β’
In the terminal, use the help
command to list available commands. For more details on a specific command, use help
followed by the command's name.
![Help Command Help Command](https://private-user-images.githubusercontent.com/67273282/343931366-1fac0d76-ed27-4129-b6c2-99dbdabc00c9.gif?jwt=eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpc3MiOiJnaXRodWIuY29tIiwiYXVkIjoicmF3LmdpdGh1YnVzZXJjb250ZW50LmNvbSIsImtleSI6ImtleTUiLCJleHAiOjE3MjQ4MDI0NDAsIm5iZiI6MTcyNDgwMjE0MCwicGF0aCI6Ii82NzI3MzI4Mi8zNDM5MzEzNjYtMWZhYzBkNzYtZWQyNy00MTI5LWI2YzItOTlkYmRhYmMwMGM5LmdpZj9YLUFtei1BbGdvcml0aG09QVdTNC1ITUFDLVNIQTI1NiZYLUFtei1DcmVkZW50aWFsPUFLSUFWQ09EWUxTQTUzUFFLNFpBJTJGMjAyNDA4MjclMkZ1cy1lYXN0LTElMkZzMyUyRmF3czRfcmVxdWVzdCZYLUFtei1EYXRlPTIwMjQwODI3VDIzNDIyMFomWC1BbXotRXhwaXJlcz0zMDAmWC1BbXotU2lnbmF0dXJlPWViZDEzM2VhMmVhYzdiNjI3NTFjY2UxZjhlMWE0NDdhZWRkYjBmNGY0MDA4ZTdjMmVhMzFiNDg1MThiMDIxNWUmWC1BbXotU2lnbmVkSGVhZGVycz1ob3N0JmFjdG9yX2lkPTAma2V5X2lkPTAmcmVwb19pZD0wIn0.VwKg3HAa24FCXPF4J1cRcVibfQNokW8K0nQca5bxr18)
Execute a program by inputting its path. Use the ls
command followed by a file name to check if it's executable.
![Execute Programs Execute Programs](https://private-user-images.githubusercontent.com/67273282/343935662-48dd48be-56bf-4742-aac2-8c0a13fde116.gif?jwt=eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpc3MiOiJnaXRodWIuY29tIiwiYXVkIjoicmF3LmdpdGh1YnVzZXJjb250ZW50LmNvbSIsImtleSI6ImtleTUiLCJleHAiOjE3MjQ4MDI0NDAsIm5iZiI6MTcyNDgwMjE0MCwicGF0aCI6Ii82NzI3MzI4Mi8zNDM5MzU2NjItNDhkZDQ4YmUtNTZiZi00NzQyLWFhYzItOGMwYTEzZmRlMTE2LmdpZj9YLUFtei1BbGdvcml0aG09QVdTNC1ITUFDLVNIQTI1NiZYLUFtei1DcmVkZW50aWFsPUFLSUFWQ09EWUxTQTUzUFFLNFpBJTJGMjAyNDA4MjclMkZ1cy1lYXN0LTElMkZzMyUyRmF3czRfcmVxdWVzdCZYLUFtei1EYXRlPTIwMjQwODI3VDIzNDIyMFomWC1BbXotRXhwaXJlcz0zMDAmWC1BbXotU2lnbmF0dXJlPWU2MDI5NGFiZmFiZThjMjRjYjM0NWQwY2NlNjQ5NzgxNTFmM2I4N2NlYzA3ZTBlYjg5ODRlMzZkOTJjNGQ0ZGYmWC1BbXotU2lnbmVkSGVhZGVycz1ob3N0JmFjdG9yX2lkPTAma2V5X2lkPTAmcmVwb19pZD0wIn0.SL0UJEWF75KM2JF-kHFipKA6mvhvetEGjdbukRvR-YE)
Open a tab with Ctrl+Shift+T
, close it with Ctrl+Shift+W
, and switch to a different one with Alt+[tab index]
.
![Tab Manipulation Tab Manipulation](https://private-user-images.githubusercontent.com/67273282/343940020-fb7ae4a7-8f5b-42cd-bbee-1eafc33aee8c.gif?jwt=eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpc3MiOiJnaXRodWIuY29tIiwiYXVkIjoicmF3LmdpdGh1YnVzZXJjb250ZW50LmNvbSIsImtleSI6ImtleTUiLCJleHAiOjE3MjQ4MDI0NDAsIm5iZiI6MTcyNDgwMjE0MCwicGF0aCI6Ii82NzI3MzI4Mi8zNDM5NDAwMjAtZmI3YWU0YTctOGY1Yi00MmNkLWJiZWUtMWVhZmMzM2FlZThjLmdpZj9YLUFtei1BbGdvcml0aG09QVdTNC1ITUFDLVNIQTI1NiZYLUFtei1DcmVkZW50aWFsPUFLSUFWQ09EWUxTQTUzUFFLNFpBJTJGMjAyNDA4MjclMkZ1cy1lYXN0LTElMkZzMyUyRmF3czRfcmVxdWVzdCZYLUFtei1EYXRlPTIwMjQwODI3VDIzNDIyMFomWC1BbXotRXhwaXJlcz0zMDAmWC1BbXotU2lnbmF0dXJlPWM2YTQ5ZWVkMWQ4ODVkZDc4ZDM4OGYwZmE0NTIwMmQ4YTBmOGU0NDkxN2MyYjIwODQxNGJkZDdkYmRjYmQxZDImWC1BbXotU2lnbmVkSGVhZGVycz1ob3N0JmFjdG9yX2lkPTAma2V5X2lkPTAmcmVwb19pZD0wIn0.xRVZ9D-nc2YpiiX12608mK4GhtayH5iz6jVt6b-JsKI)
Buzz supplies an easy interface for writing your own user programs in C and Assembly languages.
A custom build system and C standard library is provided, so you can focus on writing awesome code. The Buzz C standard library implements more than 70 functions you can use to write your code better and faster, and the Buzz user Makefile allows you to build Buzz compatible programs with a single command.
All user programs reside in the usr/exe
directory within the project. Each program is a directory containing a Makefile, a .path
file, a source code directory, and an include directory. The most basic user program structure can be defined as follows:
βββ inc
βββ makefile
βββ .path
βββ src
βββ main.c
You can easily generate it by copying the _busy
process.
cd usr/exe
cp -r _busy MyCoolProgram
cd MyCoolProgram
mkdir inc # _busy doesn't have an include directory
You can now write your code under the src
directory and your header files under the inc
directory.
When it's time to compile, enter make
. The build system will compile all .c
and .S
files under the src
directory, include the inc
directory, and link the program with the Buzz C standard library.
Note that in each user program, a .path
file can be found. This file defines the path that will lead to your program once in the system. Make sure to set this file with a valid path before compiling.
echo /home/apps/MyCoolProgram.elf > .path
For available functions and header files from the C standard library, check out the library's interface.
Buzz allows you to configure the file system already at compile time.
The usr/file
directory within the project acts as the file system's root directory. Any file placed in this directory will later appear in the operating system's file system at the same relative location.
![Creating Files Creating Files](https://private-user-images.githubusercontent.com/67273282/343741801-1d4ad551-a39c-43ba-80cc-d84c9df35711.gif?jwt=eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpc3MiOiJnaXRodWIuY29tIiwiYXVkIjoicmF3LmdpdGh1YnVzZXJjb250ZW50LmNvbSIsImtleSI6ImtleTUiLCJleHAiOjE3MjQ4MDI0NDAsIm5iZiI6MTcyNDgwMjE0MCwicGF0aCI6Ii82NzI3MzI4Mi8zNDM3NDE4MDEtMWQ0YWQ1NTEtYTM5Yy00M2JhLTgwY2MtZDg0YzlkZjM1NzExLmdpZj9YLUFtei1BbGdvcml0aG09QVdTNC1ITUFDLVNIQTI1NiZYLUFtei1DcmVkZW50aWFsPUFLSUFWQ09EWUxTQTUzUFFLNFpBJTJGMjAyNDA4MjclMkZ1cy1lYXN0LTElMkZzMyUyRmF3czRfcmVxdWVzdCZYLUFtei1EYXRlPTIwMjQwODI3VDIzNDIyMFomWC1BbXotRXhwaXJlcz0zMDAmWC1BbXotU2lnbmF0dXJlPTZiMjQ2YThkYTY4MjVjOTAzZjUyOTY1N2VlODNmNzQ4YTQ5MzY5ZjMyYjkwYzNkOTBkN2NiNTUyMWQ3N2IyODcmWC1BbXotU2lnbmVkSGVhZGVycz1ob3N0JmFjdG9yX2lkPTAma2V5X2lkPTAmcmVwb19pZD0wIn0.Jw0rWAe6SpKCHRvRYGHpjQ5byyVW7WrqP4tHRAHrNr0)
The terminal allows you to add your own custom commands.
Any executable placed in the /bin
directory within the operating system's file system can be used as a terminal command. Please note that the terminal must be restarted for the changes to take effect.
![Creating New Commands Creating New Commands](https://private-user-images.githubusercontent.com/67273282/344390764-bc99ddea-6b90-4f94-bfcf-abf8cca4dbd0.gif?jwt=eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpc3MiOiJnaXRodWIuY29tIiwiYXVkIjoicmF3LmdpdGh1YnVzZXJjb250ZW50LmNvbSIsImtleSI6ImtleTUiLCJleHAiOjE3MjQ4MDI0NDAsIm5iZiI6MTcyNDgwMjE0MCwicGF0aCI6Ii82NzI3MzI4Mi8zNDQzOTA3NjQtYmM5OWRkZWEtNmI5MC00Zjk0LWJmY2YtYWJmOGNjYTRkYmQwLmdpZj9YLUFtei1BbGdvcml0aG09QVdTNC1ITUFDLVNIQTI1NiZYLUFtei1DcmVkZW50aWFsPUFLSUFWQ09EWUxTQTUzUFFLNFpBJTJGMjAyNDA4MjclMkZ1cy1lYXN0LTElMkZzMyUyRmF3czRfcmVxdWVzdCZYLUFtei1EYXRlPTIwMjQwODI3VDIzNDIyMFomWC1BbXotRXhwaXJlcz0zMDAmWC1BbXotU2lnbmF0dXJlPTJmNDQxNTAyZjg5N2YzNmZlZTNjYTBhMmE1NTkwYzQ1MjkzMjE1YzQwMDRjMjFmNDBmZTExZWE5MTNiMTY5MjkmWC1BbXotU2lnbmVkSGVhZGVycz1ob3N0JmFjdG9yX2lkPTAma2V5X2lkPTAmcmVwb19pZD0wIn0.nH-83Pi_85zIIvami8LGssUeFCrOGn-YjB_YrwcWUtM)
- First-stage bootloader that sets up the environment, loads the second stage bootloader and jumps to it
- Second-stage bootloader that loads the kernel from the file system and jumps to it
- Hardware, exception, and software interrupt handling
- Protected memory management
- Process management
- Priority-based multiprocessing scheduling
- File system
- Standard streams and multi-tab textual display implementation
- More than 25 system call
- Keyboard driver
- Timer driver
- Screen driver (VGA)
- Hard disk driver (PATA)
- Custom C standard library with more than 70 functions
- Custom build system for user programs
- More than 15 user programs and commands included
If my code sucks, please open an issuse and let me know!
Consider giving the repository a star π