Skip to content

khaledh/axiom

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Axiom OS

This is my attempt at creating a modern 64-bit kernel in Nim.

Axiom OS

Requirements

  • Nim 1.9.3
  • MinGW-w64
  • QEMU
  • UEFI BIOS image:
    • Arch: sudo pacman -S edk2-ovmf
    • Ubuntu: sudo apt install ovmf

Compile and run

$ nim c --os:any --out:fatimg/EFI/BOOT/BOOTX64.EFI src/boot/boot.nim
$ qemu-system-x86_64 \
    -bios /usr/share/edk2-ovmf/x64/OVMF_CODE.fd \
    -drive format=raw,file.driver=vvfat,file.rw=on,file.dir=fatimg \
    -nic none \
    -machine q35 \
    -debugcon stdio -global isa-debugcon.iobase=0x402

Note that the above path for OVMF_CODE.fd is the default install path on Arch Linux. For Ubuntu use the path /usr/share/OVMF/OVMF_CODE.fd instead.

Features

  • UEFI bootloader
    • Simple Text Protocol
    • Graphics Output Protocol (GOP)
    • Kernel loader
  • Hardware Detection
    • UEFI Memory Map
    • ACPI: I/O APIC
    • ACPI: Local APICs
    • PCI bus enumeratoin
    • VGA
    • AHCI storage controller
    • SMBIOS information
  • Graphics Output
    • Bochs Graphics Adaptor (BGA)
    • Framebuffer
    • Font rendering
  • Segment Descriptors
    • Global Descriptor Table (GDT)
    • 64-bit flat memory model
  • Interrupts
    • Interrupt Descriptor Table (IDT)
    • Fault and Trap handlers
  • Memory Management
    • Page frame allocator
    • Paging (Virtual Memory)
    • Kernel memory allocator
  • Preemptive Multitasking
    • Kernel threads
    • User threads
    • Timer IRQ handler
    • Scheduler
  • Multiprocessor Support
    • SMP
    • Scheduler
  • Keyboard Input
    • Keyboard IRQ handler
    • Scancode conversion
    • Key event packet
    • Buffering
  • Storage
    • SATA ACHI driver
  • File System
    • TBD
  • System Calls
    • TBD

License

MIT

About

A 64-bit kernel implemented in Nim

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published