/RetrOS-32

32bit Hobby Operatingsystem with graphics, multitasking and networking on i386 architecture.

Primary LanguageCMIT LicenseMIT


RetrOS 32bit

Build

Hobby 32bit operatingsystem project focusing on networking on i386 architecture.
Explore the docs »

View Demo · Report Bug · Request Feature

Table of Contents
  1. About The Project
  2. Getting Started
  3. Usage
  4. Roadmap
  5. Contributing
  6. License
  7. Contact
  8. Acknowledgments

About The Project

32bit Hobby Operatingsystem with graphics, multitasking and networking!

Started: 12.05.2022

(back to top)

Built With

This project is built with C & Assembly for the kernel, utilities and build system. C++ for userspace applications and Make for compilation. Docker used for crossplatform compilation.

Docker

(back to top)

Hardware

Tested on: Lenovo x240, Asus Eee PC series, Dell Optiplex 780, Samsung N150 Plus, Samsung NP-NC10, IBM Thinkpad a21p

Getting Started

Prerequisites

Crossplatform: Docker to compile the .iso file and QEMU for emulation.
For native compilation you will need:

  • i386-elf-gcc, i386-elf-ld and i386-elf-g++ for MacOS.
  • build-essential and gcc-multilib for Linux / WSL (ubuntu)
  • Also need: grub2, xorriso and xxd (for using Grub as bootloader)

Installation

To compile the kernel and its needed programs you simply need to run make img and make qemu to open QEMU

Linux

  1. Clone the repo

    git clone https://github.com/joexbayer/RetrOS-32.git
  2. Compile the kernel and create .img file

    make img

    Note: needs sudo to mount the .img file and copy over files!

  3. Launch QEMU

    make qemu
  4. Use GRUB (Optional)

    make grub

MacOS

MacOS can compile the kernel but not the needed tools.
  1. Clone the repo

    git clone https://github.com/joexbayer/RetrOS-32.git
  2. Compile the kernel / OS

    Docker:

    sudo docker-compose up
  3. Launch QEMU

    make qemu
  4. Use GRUB (Optional)

    make grub

Windows

Using Docker (can also compile in WSL)

  1. Clone the repo

    git clone https://github.com/joexbayer/RetrOS-32.git
  2. Compile and Launch QEMU

    ./make.cmd run

(back to top)

Usage

To run RetrOS-32:

  • http://copy.sh/v86/ : Upload .img file as Hard disk image.
  • QEMU: make qemu or qemu-system-i386 <image name>
  • Real hardware: Burn .iso file to USB or CD (Use a GRUB iso)

(back to top)

<<<<<<< HEAD

Hardware

Tested on: Lenovo x240, Asus Eee PC series, Dell Optiplex 780, Samsung N150 Plus, Samsung NP-NC10, IBM Thinkpad a21p

=======

26e4e17bf04130ec26fc6176f7d3d05259fc6796

Project Structure (TBD)

NETOS - Project
├── Dockerfile 
├── LICENSE.txt
├── Makefile
├── apps (userspace applications)
│   ├── Makefile
│   ├── <app>
│   ├── libcore.a
│   ├── libgraphic.a
│   ├── libnet.a
│   ├── readme.md
│   └── utils
│       └── *.cpp
├── bin 
│   └── *.o
├── boot (custom bootloader)
│   ├── bootloader.s
│   └── multiboot.ld
├── docker-compose.yml
├── docs (documentation)
│   ├── *.md
├── drivers (kernel drivers)
│   └── *.c
├── fs (filesystem)
│   ├── Makefile
│   ├── bin
│   └── *.c
├── graphics
│   └── *.c
├── include
│   ├── arch
│   │   └── *.h
│   ├── fs
│   │   └── *.h
│   ├── gfx
│   │   └── *.h
│   ├── lib
│   │   └── *.h
│   ├── net
│   │   └── *.h
│   └── *.h
├── kernel (main kernel source files)
│   ├── arch
│   │   └── *.c
│   ├── kthreads
│   │   └── *.c
│   └── *.c
├── legacy (old code)
├── lib (libraries)
│   └── *.c
├── net (networking code)
│   └── *.c
├── readme.md
├── rootfs (root filesystem for the OS)
├── tests (testing code)
│   ├── Makefile
│   ├── bin
│   ├── *_test.c
│   └── readme.md
└── tools (build tools)
    ├── scripts
    └── bin
        └── *.c

Roadmap

  • Custom Bootloader & GRUB compatible
  • Stage 2 bootloader
  • Wallpapers
  • Mountable image
  • Multi-threaded pre-emptive scheduling
  • GDT & TSS kernel / userspace separation
  • Interrupt handling
  • PS/2 Keyboard & Mouse, PIT, VESA (640x480x8), RTC, Serial drivers, E1000
  • PCI.
  • 8Bit RGB to 8Bit VGA
  • Filesystem
  • Textmode VGA only
  • Networkstack
    • Ethernet, IP, ARP, UDP
    • Socket API
    • Interfaces
      • Loopback
    • DHCP
    • DNS
    • TCP
    • Netcat style commands
    • Telnet
    • HTTP
    • HTML
  • ATA IDE Driver
    • Ext2 (like) Filesystem
    • FAT16, support for up to 32mb files.
    • read / write
    • Atapi
  • Memory
    • 32bit Virtual Memory
    • kalloc / kfree (kernel)
    • malloc / free (userspace)
  • Graphics
    • Window Manager
    • GFXLib
    • Double framebuffer rendering
    • Mouse events
    • Dynamic resize
    • Fullscreen
  • Terminal, Window Server, Process Informtaion, Finder.
  • Library (printf, memcpy, etc)
  • IPC
  • System calls
  • C Compiler / interpreter to bytecode
  • Custom VM to run bytecode.
  • Editor with Syntax Highlighting
  • Calculator
  • 3D Game
  • Snake game (Textmode only)
  • Userspace threads (shared virtual memory)
  • Remote virtual terminal over TCP
  • Tools
    • Build
    • Sync / Migration Took
    • mkfs
    • Testing
    • Create & Encode icons and wallpapers

See the open issues for a full list of proposed features (and known issues).

(back to top)

License

Distributed under the MIT License. See LICENSE.txt for more information.

(back to top)

Contact

Joe Bayer - joeba@uio.no

Project Link: https://github.com/joexbayer/RetrOS-32

(back to top)

Acknowledgments

Use this space to list resources you find helpful and would like to give credit to. I've included a few of my favorites to kick things off!

(back to top)