Remix.run Logo
Show HN: MesaOS – An operating system written from scratch in Rust(github.com)
4 points by crackanimador 4 days ago | 13 comments

Hello! I'm a student from Spain and I'm the creator of MesaOS, an open-source operating system written from scratch in Rust for x86_64.

I've been working on it mostly by myself.

MesaOS currently has:

A hybrid kernel Preemptive multitasking A Linux driver shim with 400+ exported kernel symbols (still in development) HDA audio and WAV streaming A shell with around 82 commands VFS, RamFS and persistent initrd File persistence through automatic folder-to-ISO injection SMP / multicore support xHCI / USB 3.0 support

It works on QEMU and on my HP 15s-eq2xxx laptop.

Some of the things I'm currently working on are USB storage, TCP, Wi-Fi and more hardware support.

Wi-Fi is one of the harder problems for me right now. My laptop uses a Realtek RTL8822CE, and there isn't much information available about it.

The project is still very much a work in progress, but I've reached a point where I would like to have other people working on it with me. I'm especially interested in people who like operating systems, kernels, drivers, networking, Rust or low-level programming.

I'm also transparent about using AI during development. The source code is generated using language models based on my instructions. I handle the architecture design, debugging, hardware testing and integration myself.

There is also an English/Spanish Discord server for the project if anyone wants to discuss development or contribute.

Discord: https://discord.gg/sEaB7KAwtr

softwarewright 4 days ago | parent | next [-]

I have also developed a preemtive-multitasking O/S (and some programming languages to build this and apps) targeted for embedded soft cpu (not x86).

I build tools in Rust, too. I joined your discord but cannot comment anywhere yet (lack of permissions).

Do you use AI coding agents?

crackanimador 4 days ago | parent | next [-]

Yes. But only for the coding. The rest is still done by me (hardware testing, QEMU, debugging, instructions, ideas, and so on).

softwarewright 4 days ago | parent [-]

I have forked, cloned, and built (had to pin a specific nightly Rust for it to build). When I run it, it crashed at login; I reran it with VNC, was able to login as root, issue ls and uptime, but then it crashed. My AI is debugging...

softwarewright 3 days ago | parent | next [-]

In my fork, I've added ./experiments where I hacked together a shell wrapper for a no_std Rust app to implement head -<n>.

help > help.txt <script path>/head -2 help.txt

works. This shows how I can cross-compile code to run in the MesaOS shell. This is a workaround until I have better libraries/APIs for argc/argv handling, file I/O, etc. Fun!

softwarewright 4 days ago | parent | prev | next [-]

so the built-in nano helps a lot, since the help output scrolled off the screen. I tried to use head, less, and more. I could redirect help output to a file (but until I found nano, could not page that). I also looked for dd.

The VNC UI seems generally stable, I was able to log in as all three users, and issue many commands.

Is there a bundled assembler or compiler. How can I write apps for this? Do you have a way to cross-compile and mount a shared folder or scp binaries in?

crackanimador 3 days ago | parent [-]

Hey. Sorry I couldn't reply sooner (I was asleep). Here's how it works: you put your files directly from your main OS into the "inyect" folder (where the `bin` folder and other items are located). You add your binaries there and then rebuild the ISO. That way, when you boot up MesaOS, your file(s) should be inside.

softwarewright 4 days ago | parent | prev [-]

My AI wrote scripts to launch and attach. I was able to do a lot login in as root. One bug: when I run the ring3 demo, the shell stops accepting input.

crackanimador 4 days ago | parent | prev [-]

And by the way, I think I've fixed the Discord issue. Try testing it when you can.

softwarewright 4 days ago | parent [-]

yes, works now, thanks

drivingmenuts 4 days ago | parent | prev | next [-]

You might need to either rename (or sue for the name) as MesaOS is in use by a Restaurant POS software.

https://mesaos.com/

crackanimador 3 days ago | parent [-]

Wow. That's true. I think I should do it. But sometime in the future (it would just be a small name change, nothing major).

tbrntbqm 4 days ago | parent | prev [-]

In one of his interviews, Linus suggested that next-gen OS would be written in Rust. You picked an interesting track, starred your repo!

crackanimador 3 days ago | parent [-]

I’m pretty sure work is already underway to port Linux to Rust in upcoming versions. And thanks for the star!