nOS is a from-scratch x86 (32-bit i386) operating system.
nOS is primarily developed as an exercise and for the purposes of education of the author. Nevertheless, it can be used as a high-quality example code-base and for code samples.
nOS running in qemu-system-i386
on Mac OS Mojave, displaying:
- The arguments to
kmain
- Lines indicating successful load of the kernel and the partition table
- A dump of the partition table
- A dump of the BIOS memory map
- A set of key-press events
- PIC support
- Physical memory manager
- Memory virtualization. So far a flat physical memory model is used
- Virtual memory manager
- Kernel console
- IRQ support
- Kernel and bootloader debugging functionality
- ?Load time relocation support
- System shell
- Inter-process communication
- Kernel stripping
- Does not enable the A20 line upon boot, relying on it being on by default.
- Kernel overrides the bootloader's GDTR to point to an equivalent GDT
- Driver API makes it easy for the consumer to write buggy code
nOS uses Shake.
- NASM
- clang++ capable of targeting i386
- lld capable of linking ELF
- compiler-rt targetting the
x86-none-elf
triplet
After installing the dependencies, simply run ./build.sh
from the project folder.
Use ./run.sh
to run the application once built.