1
0

Write README
All checks were successful
CI / Typos (push) Successful in 10s
CI / Clippy (push) Successful in 31s
CI / Build (push) Successful in 1m17s

This commit is contained in:
Mark 2025-03-02 21:00:16 -08:00
parent 1b401b46b2
commit cbf6c48b22
Signed by: Mark
GPG Key ID: C6D63995FE72FD80

View File

@ -1,2 +1,36 @@
- fix asm loader
- document everything
# TetrOS: bare-metal tetris
## TODO:
- Fix stage 1 loader
## Features
- Compiles to a standalone disk image
- Written from scratch using only Nasm and Rust
- Custom BIOS bootloader
- 32-bit x86 OS
- 🌟 Detailed comments. Read the [makefile](./Makefile), then start in [`./bios/main.asm`](./bios/main.asm).
## Non-Features
- Never tested on real hardware
- Minimal gameplay and graphics. These features aren't hard to implement, but also don't present any interesting challenges. I have other things to do.
## 🚀 Building and Running
- All scripts are in the [makefile](./Makefile).
- To build and run, use `make qemu`.
- Dependencies: `nasm`, `cargo`, GNU `binutils`, `qemu`
- This will NOT work on MacOS. BSD `ld` does not work like GNU `ld`.
- Alternatively, a compiled disk image for the latest commit is [here](https://git.betalupi.com/api/packages/Mark/generic/tetros/latest/disk.img). This is the same file produced by `make`.
- Download it and run `qemu-system-i386 -d cpu_reset -no-reboot -smp 1 -m 2048 -machine q35 -net none -serial stdio -fda "disk.img"`
## 📜 Resources
**Used directly:**
- [jdh's video](https://www.youtube.com/watch?v=FaILnmUYS_U)
- [The OSDev wiki](https://wiki.osdev.org/Main_Page)
- [RedoxOS bootloader](https://gitlab.redox-os.org/redox-os/bootloader)
**Useful background knowledge:**
- [Writing an OS in Rust](https://os.phil-opp.com)
- [Operating Systems: From 0 to 1](https://github.com/tuhdo/os01)