Remix.run Logo
hpscript 4 hours ago

Hi HN,

I’ve been working on a tiny RTOS as a personal project to better understand how operating systems and schedulers work internally.

This project includes: - Basic task scheduler - Context switching - Simple memory management - Runs on (your target hardware or environment)

Motivation: I wanted to learn OS internals by building everything from scratch rather than relying on existing frameworks.

Challenges: - Implementing context switching correctly - Designing a minimal but usable scheduler - Keeping the codebase simple and readable

I’d really appreciate feedback, especially on: - Architecture design - Scheduler implementation - Code structure

GitHub: https://github.com/cmc-labo/tinyos-rtos

bahmboo 3 hours ago | parent | next [-]

Impressive! Very complete on first glance. You might want to soften or qualify the RTOS statement so people focus on its compactness and low latency. As you are already seeing in the comments the RTOS aspect has a lot of opinions depending on what one is trying to accomplish.

peteforde 2 hours ago | parent | prev [-]

Very cool! Thanks for sharing.

I would appreciate an honest comparison with FreeRTOS. Building something like this is an excellent learning exercise for the coder, but someone who has to balance the risks, learning curve and feature set has to justify the adventure in a different way.

One thing that would be interesting to hear more about would be your own recounting of the places where you made opinionated decisions about how things should work.