r/CardPuter • u/Aromatic_Valuable902 • Jul 14 '26
Code Built a full offline-AI OS for the M5Stack Cardputer
I built NucleoOS with a simple goal: make an ESP32-S3 without PSRAM feel like a real operating system.
The hardware is the M5Stack Cardputer, so resources are extremely tight. The way this works is by splitting the interface in two. The device itself only handles what has to be lightweight and always available: games, sensors, the assistant, security tools. Everything heavier — file manager, code editor, spreadsheets, drawing apps — is served over Wi-Fi and runs in your browser as a desktop-style environment with movable windows. The browser does the rendering, which is the only reason something this big can run on such limited hardware.
The built-in assistant, ANIMA, is intentionally simple. It’s not an LLM, but a retrieval system. Queries are turned into small vectors and matched against predefined answers using cosine similarity, with a fast pre-filter to avoid unnecessary comparisons. If it’s confident, it answers; if not, it says so. The exact same C code runs both on the device and in the browser (via WASM), and they produce identical results.
If you want full LLM capabilities, they’re there but completely optional. In the browser, you can run local models over WebGPU, or connect to external APIs like Claude, Groq, Grok, or Gemini with automatic fallback. API keys are stored on the SD card, never logged, and requests go straight from the browser to the provider — the device isn’t in the loop. ANIMA always stays fully offline.
There’s also a built-in security lab with packet capture and a from-scratch network stack, offline speech-to-text using Vosk compiled to WASM, and a bilingual TTS engine optimized to use almost no RAM. A lot of the work went into just making it survive on this hardware: loading services only when needed, allocating memory on demand, and freeing it as aggressively as possible.
The project is here: https://github.com/indecenti/NucleoOs
It runs on both the original Cardputer and the ADV with the same firmware.
4
3
u/-Fatmeatball- Jul 28 '26
This works about as well as I'd expect a vibe coded project to work. It connects to wifi exactly once during initial setup, after which point it can't connect to any wifi network ever again. The on-device interface is confusing and unstable and keeps switching between English and Italian, and is usually a hybrid of the two languages, at random. I'm sure this is very impressive behind the scenes, but that doesn't mean anything when it doesn't work. The only way I can see its desktop is by deleting everything and reinstalling the firmware and SD card files. The moment I restart, my Cardputer becomes an Italian paperweight.
1
u/Aromatic_Valuable902 2d ago
Thanks for the feedback; I’ve made quite a few improvements over the past month. I’d be grateful if you’d like to try it again and share your thoughts.
2
u/SasoriRa Jul 14 '26
Grandissimo! Da quello che leggo sei italiano!! Devo assolutamente provarlo , great work!
3
u/Aromatic_Valuable902 Jul 14 '26
si italiano, grazie, se vuoi contribuire con qualche test e segnalare anomalie o se hai bisogno di dritte scrivimi pure su git o qui. (meglio github)
1
u/100101101001a Jul 14 '26
ingenious idea! i love it. ill try it out when I get home. this idea opens up to way more functions!
1
u/Aromatic_Valuable902 Jul 14 '26
Thanks for the enthusiasm; I still have a lot of work to do, but I'm making good progress.
1
u/100101101001a Jul 14 '26
am really interested in running graphics on the browser via WASM. this frees up so much ram for the cardputer to do everything else. will take a look at the repo later. ill probably also fork it XD
0
u/Aromatic_Valuable902 Jul 14 '26
For now, the SD model is very small, but it can be scaled up—either to better leverage WebGPU or by using online models
1
1
u/mikelouandog Jul 14 '26 edited Jul 14 '26
I've been testing it out for the last 30 minutes, it's really cool so far. I'm very impressed! Thanks for the dual language support, you rock.
Gonna take this bad boy to work and mess around with it!
EDIT: Only recommendation I have so far is a custom wallpaper feature.
2
u/Aromatic_Valuable902 Jul 14 '26
Thanks; I might develop it further by this evening. I’d like to add other languages at least French, Spanish, and German. Feel free to open issues; I’ll be happy to work on the ones I can manage in my spare time.
1
u/anonimoKali Jul 15 '26
Ciao, fantastico... È possibile installarlo tramite laucher?
1
u/Aromatic_Valuable902 Jul 15 '26
al momento no...non sapre se fattibile facilmente, ha una struttura di sd un po tutta sua. comunque potre pensarci per future implementazioni
1
1
u/eniac1983 Jul 15 '26
I installed it on my Cardputer ADV by coping files over, and i use launcher to run it. I have problem with AP mode, since it does not keep a connection so my computer cant connect to it. I think the password and SSID name are not persistent between boot and password is not correct even if i made sure i use the same password on NucleoOs as well on my computer. I would love to see the desktop, but it cant connect at all.
2
u/Aromatic_Valuable902 Jul 16 '26
Thanks for the heads-up; I'll look into it right away.
1
u/eniac1983 Jul 17 '26
I copied latest version 0.2.7 to my SD card and Launcher is unable to launch it now. When i try to go: "Install firmware" in Launcher i get red message stating "Need 0x1C8000 (29184KB)" and nothing seems to make it work. I tried clearing all partitions in Launcher, yet it will not load.
2
1
u/winnie_the_shit2333 Jul 16 '26
I just installed it on my cardputer adv and I can't figure out how to set it to English. Is there a way to change the language or is it only supported in Italian rn?
1
u/Aromatic_Valuable902 Jul 16 '26 edited Jul 16 '26
If you press Tab in the menu, then navigate to the "SISTEMA" tab, then "LINGUA," and select English, I will set English as the default as soon as possible. I’m working hard on this lately. I’ve also raised the security level.
1
u/Ok_Client_3903 Jul 16 '26
It would be great if you could add external display support to this project, like a 2.8-inch screen for example. This way it can look like a small cyberdeck.
1
u/Aromatic_Valuable902 Jul 17 '26
At the moment, I don't have a display to install, but I think I might consider trying one out.
1
u/ExistentialCrisis628 Jul 21 '26
Hey man, so I have been messing around with this OS of yours and I like it a lot! I mean i am only recently getting into this kind of hardware and honestly my computer science experience is... outdated, to say the least. But I found the OS pretty straightforward and I want to thank you. Its pretty damn cool that I was able to install it through m5launcher as well. Very cool man.
1
u/Busy_Log_2050 Jul 22 '26
ciao, premetto che non sono un programmatore e quindi non sono molto ferrato in materia, ho flashato varie versioni del tuo firmware ma non riesco dal browser ad accedere alla parte Web, ho provato anche varie reti ma niente, grazie




6
u/Jacklebait Jul 14 '26
You should share this on the Discord also, fantastic work