❯ Xtremly Basic Calculator
Built with the tools and technologies:
- Overview
- Features
- Project Structure
- Getting Started
- Project Roadmap
- Contributing
- License
- Acknowledgments
This Project is a 32-Bit x86 Operating system running a calculator that performs basic arithmetic operations. It consists of a custom bootloader written in NASM assembly that loads kernel and firmware from the disk and calls the kernel entry. The kernel then intializes Screen and Keyboard aswell as other basic things and runs the firmware containing the calculator code. The Firmware is written purely in C mostly without standard librarys and converts input into Reverse Polish Notation using the Shunting Yard Algorithm
- Custom Bootloader
- 32-Bit protected mode
- VGA and Keyboard Drivers
- Arithmetic Calculator
└── os/
├── .github
│ └── workflows
├── README.md
├── build
│ ├── boot.bin
│ ├── cpu
│ ├── drivers
│ ├── firmware
│ ├── kernel
│ ├── kernel.bin
├── makefile
├── output
│ └── image.bin
├── setup-gcc-debian.sh
└── src
├── boot
├── cpu
├── drivers
├── firmware
└── kernelXBC-89-OS/
setup-gcc-debian.sh ❯ Setup Code for installing cross-compiler chain on Debianmakefile ❯ Makefile to build and run the project
src
kernel
kernel_entry.asm ❯ Kernel entry code calling main functionkernel.c ❯ Kernel sourcekernel.h ❯ kernel headerutil.c ❯ Utility sourceutil.h ❯ Utility headerfirmware
eval.c ❯ Evaluation and Shunting sourceeval.h ❯ Evaluation and Shunting headerxbc.c ❯ Calculator sourcexbc.h ❯ Calculator headertokenize.c ❯ Tokenizer sourcetokenize.h ❯ Tokenizer headerutil.c ❯ Firmware utilities sourceutil.h ❯ Firmware utilities headercpu
low_level.c ❯ Low Level source for communication with external deviceslow_level.h ❯ Low Level headerinterrupt.asm ❯ Assembly file redefining interrupt service routines (ISRs)idt.c ❯ Interrupt Descriptor Table (IDT) sourceidt.h ❯ IDT headerisr.c ❯ ISR definitions and init sourceisr.h ❯ ISR headerdrivers
libscreen.c ❯ VGA Display driver sourcelibscreen.h ❯ VGA Display driver headerlibkey.c ❯ PS/2 Keyboard driver sourcelibkey.h ❯ PS/2 Keyboard driver sourceboot
boot.asm ❯ Bootloaderinclude
disk.asm ❯ Routines for disk loadingprint.asm ❯ Print routine for real modeswitch_to_pm.asm ❯ Routines for switching to 32-Bit PMgdt.asm ❯ Global Descriptor Table (GDT)
Before getting started with os, ensure your runtime environment meets the following requirements:
- Programming Language: C and Assembly
- Emulator: Qemu or similar
Install os using one of the following methods:
Build from source:
- Clone the os repository:
❯ git clone https://github.com/crwntec/XBC-89-OS.git- Navigate to the project directory:
❯ cd XBC-89-OS- Install the project dependencies:
echo './setup-gcc-debian.sh'
Run os using the following command: echo 'make run'
-
Task 1:Implement working operating system. -
Task 2:Implement calculator. -
Task 3: Extend calculator functionality.
- 💬 Join the Discussions: Share your insights, provide feedback, or ask questions.
- 🐛 Report Issues: Submit bugs found or log feature requests for the
osproject.
Contributing Guidelines
- Fork the Repository: Start by forking the project repository to your LOCAL account.
- Clone Locally: Clone the forked repository to your local machine using a git client.
git clone https://github.com/crwntec/XBC-89-OS.git
- Create a New Branch: Always work on a new branch, giving it a descriptive name.
git checkout -b new-feature-x
- Make Your Changes: Develop and test your changes locally.
- Commit Your Changes: Commit with a clear message describing your updates.
git commit -m 'Implemented new feature x.' - Push to LOCAL: Push the changes to your forked repository.
git push origin new-feature-x
- Submit a Pull Request: Create a PR against the original project repository. Clearly describe the changes and their motivations.
- Review: Once your PR is reviewed and approved, it will be merged into the main branch. Congratulations on your contribution!
- Writing a Simple Operating System - from Scratch by Nick Blundell Link (sadly incomplete :( )
- Making an OS (x86) series by Daedalus Community Link