What's everybody working on?

Still working on my OS (mainly RISC-V, https://codeberg.org/loup-os. Got the framebuffer console working for RISC-V (like some time ago) and made a centralized init system with VTables, now starting USB (xHCI) work. I don’t know how much I’ll curse, but I will. Also, I don’t have a lot of time to work on it right now, so progress is relatively slow.

(below an image of the framebuffer console rendering some text)

image

I love programming in Zig, but that may also just be because I have used it since like three years, and because it got me into systems programming.

8 Likes

working on my on FM synth with more algorithms for crazy whomp-whomp and eliminating the hunting phenomenon. I would like to make it into a clap plugin It’s gonna be fun !

8 Likes

So many cool projects from everyone. This is one reason I love this community, so much talent and so many cool projects.

My main project right now is working on a zig native debugger. I’ve been writing my own Dwarf parsing code, which has been an adventure in the arcane. I don’t have any public code right now or things to show for it, but i do occasionally live stream on youtube.

14 Likes

I still work on Cubyz, a voxel sandbox game inspired by minecraft.
The last bigger things I worked on for it were a decentralized authentication system, and SDF terrain generation, which allowed me to add sky island terrain using some partial spheres:


Currently I’m working on (who could have guessed) the Zig 0.16.0 upgrade to finally get those sweet compile time improvements (hopefully it works more reliably this time around, last time I tried, I had some issues with bool vectors).

29 Likes

I build a logging data store. It’s a time series value log, technically a Loki alternative.

4 Likes

It’s great to see the community growing so much, and the scope and ambition of what everyone is working on.

I am going to put on my grumpy hat for a moment, and issue a plea: please stop naming projects zig-thing and thing.zig. This assumes a mantle you did not ask for permission to wear.

Here’s what happens: after you show off thing (and are silently judged by more people than you seem to be aware of for your presumption), most likely, you lose interest. The code goes into the code graveyard.

But years later, someone is searching for “zig thing” and there it is: zig-thing. But zig-thing is not the Zig thing for the thing, it’s clever-name-thing, the good project we all use. That someone has to wade through the namespace pollution. Perhaps they come on Ziggit and say “does Zig have thing? I found zig-thing but it sucks and it’s years old” and we have to say “oh right. zig-thing, no, we all use good-thing-clever-name.”

It shows a lack of creativity. Please do something else instead.

23 Likes

Hello there,
as you explicitly asked for it, I’m working on (yet another) GameBoy emulator. DiMethylGlycine: Game Boy emulator

Specifics:

  • Rendering using UTF-8 / terminal escape codes
  • NO external libraries (only Zig/std)
  • I do not want to write a port of an emulator → checking other emulators behavior / code only when totally desperate (using tools / test suites / roms from others though and not retro-engineering the hardware myself)
  • NO LLM (I have to use them at work → so I banned at home for coding)

Drawbacks:

  • "Works on my machine"™ → Linux only so far (no external libraries policy; would like to support WASM at some point though)
  • It’s hard to believe how slow I am (I thought the project would take 3 months, so expected 6 but git log says nope, slowly reaching 2 years)
    Concrete example: it took me weeks of debugging / disassembly to understand why somehow I lead Tetris to write to forbidden memory until googling around resulted a painful, ~”yes it’s behaving like this, ignore writes to these addresses”

What seems to work so far: CPU / Graphics (Pixel Processing Unit) and rendering / Input (with controller support)

Next steps:

  • Port to Zig 0.16 :wink:
  • Fix timers (Tetris proto playable but most ROMs just don’t work)
  • Bootrom (will implement a custom one, already roughly know how it will look like but I will need to debug the assembler though and maybe write an image to tiles converter). BTW has https://ziglang.org/zero.svg an official sound? I’m asking for a friend…
  • Proper options parsing (my laziness brought in a lot of build-time defines…)
  • Debug interface
  • Sound (still unsure how to implement it though)

Fun facts:

  • Switched from (doom-)emacs to nvim during the project (using both on a regular basis)
  • The rendering is text, so some integration tests just diff against a file to check for pixel perfect output

Screenshot of rendered text (sounds stupid but I’m proud of being able to display this test correctly; took months to get it right. Source: GitHub - mattcurrie/dmg-acid2: 😀 The Acid2 test, now for the original Game Boy! 😀 · GitHub )

Zig specific Kudos:

  • Of course everyone committing to the core / writing doc / …
  • Before attending Mario Schallner talk, I struggled to find a way to handle utf-8 / braille a fancy way, but no: 60 FPS with square pixels and jaw-dropping graphics are doable https://www.youtube.com/watch?v=xjCv2aZiMWU - check catimg for inspiration GitHub - posva/catimg: 🦦 Insanely fast image printing in your terminal · GitHub
  • This kind of way of seeing mainstream but sub-optimal stuff as simply broken, not as “if it’s widely used, it must be optimal”
  • Thanks to the core team for breaking stuff (this probably sounds stupid but I’m sometimes working in legacy hell so yes, please continue breaking / removing not good enough stuff)
  • Hatting over-kill dishwashers and co. which should just work and be a done topic in 2026

Thank you so much to the whole community. Literally re-discovering the joy of programming in these weird dark age and learning a lot at the same time.

19 Likes

3 posts were split to a new topic: Naming things Zig which are not Zig, the language

Dude I can’t wait to play this game, you have no idea how I’m hyped for this!

1 Like

I’m working on my modbus gateway: https://codeberg.org/intales/giacomo/src/branch/gateway
Still a work in progress, but I hope to have it working by the end of next week!
The modbus library is pretty much done, it manages most of my use cases.

3 Likes
  1. Love. A simple joke utility that does only one thing — after launching, it outputs the phrase “I love you!” to the console. If you pass a parameter with a name, the phrase will include that name. For example: “I love you, Jane!”. GitHub - ktarasov/love: A simple joke utility that does only one thing — after launching, it outputs the phrase "I love you!" to the console. If you pass a parameter with a name, the phrase will include that name. For example: "I love you, Jane!". · GitHub

  2. Zigrep. A file search utility based on the Linux grep utility. GitHub - ktarasov/zigrep: The educational project of the text search utility in files, written in the Zig language. · GitHub

  3. FFI for PHP on Zig. GitHub - ktarasov/zig_php_ffi: Пример реализации FFI для PHP на языке программирования Zig · GitHub

5 Likes

Working on an on-prem spreadsheet for my family and friends collaboration, so the bar is low on tech side, and pretty high on interface side. Targeting Mac and Linux. (Considering upgrade to 0.16.0 as soon as libxev is upgraded.)

14 Likes

So many cool and advanced projects!

Even I use Zig as my main language for 4 months now, Im still learning.

As a goal I want to port my most successful open source project to Zig one day (from Rust). Since its a TUI for managing Biblatex databases, I just started to write a parsing lib for Biblatex files in Zig. Its still very early stage because Im not experienced with lexer/parser stuff, but a lot of fun. Will publish the code soon on codeberg.

Beside that Im contributing much to the S3 lib z3 since managing object storage systems is my daily buisness at work. And if there is a good Zig lib for building stuff, I even can use it there daily :slight_smile:

8 Likes

I’ve been working on a crossplatform but specifically linux native driver for the Azeron Cyborg II controller.

It’s my first project in zig and it’s going slow. But I’m making progress.

https://codeberg.org/Moortu/zigeron

4 Likes

I’m a robotics masters student, and I use ROS 2 (the “Robot Operating System”) constantly. I’m dogfooding a Zig wrapper for RCL (the “ROS Client Library”), along with some surrounding core libraries for a few reasons:

  1. The Zig dev experience makes writing reliable, performant code (the kind needed in robotics) much easier than C++. Zig is a solid foundation, most of what is missing are libraries.
  2. Sidestepping CMake to build packages with Zig instead. The Zig build system is preferable for dependency management compared to centralized package managers. Pip and CMake have burned me too many times when using third-party code.
  3. Zig will be big for robotics when the matrix and GPU features are mature. An RCL library should be ready when that time comes.

Compare Zig to C++ code for an (extremely) basic service and client:

C++ Service vs Zig

C++ Code

//! Demonstrates usage of high-level RCL APIs: executor with service and client

const std = @import("std");
const rcl = @import("rclzig");
const example_interfaces = @import("example_interfaces");
const AddTwoInts = example_interfaces.srv.AddTwoInts;
const AddService = rcl.Service(AddTwoInts);

fn serveAddTwoInts(userdata: ?*anyopaque, request: *const AddTwoInts.Request, response: *AddTwoInts.Response) anyerror!void {
    const node: *rcl.Node = @ptrCast(@alignCast(userdata));
    response.sum = request.a +% request.b;
    node.log(@src(), .info, "Serving request {} + {}", .{request.a, request.b});
}

pub fn main(init: std.process.Init) !void {
    const gpa = init.gpa;
    try rcl.init(gpa, init.io, init.minimal.args);
    defer rcl.shutdown();

    var node = try rcl.initNode("sumservice", "", .{});
    defer node.deinit();

    var service = try AddService.init(&node, "add", .{
        .callback = &serveAddTwoInts,
        .userdata = &node,
    });
    defer service.deinit(&node);

    const executor = try rcl.Executor.create(node.getContext(), .{.threads = null}); // single-threaded
    defer executor.destroy();
    try executor.spinObjects(.{&service}, .{});
}
C++ Client vs Zig

C++ Code

//! Demonstrates usage of high-level RCL APIs: executor with service and client

const std = @import("std");
const rcl = @import("rclzig");
const example_interfaces = @import("example_interfaces");
const AddTwoInts = example_interfaces.srv.AddTwoInts;
const AddClient = rcl.Client(AddTwoInts);

var random = std.Random.DefaultPrng.init(0);

fn requestAddTwoInts(userdata: ?*anyopaque) anyerror!void {
    const client: *AddClient = @ptrCast(@alignCast(userdata));
    var req: AddTwoInts.Request = try client.initRequest();
    req.a = @bitCast(random.next() % 32);
    req.b = @bitCast(random.next() % 32);
    _ = try client.sendRequestOwned(req);
}

fn responseAddTwoInts(userdata: ?*anyopaque, query: *const AddClient.Query) anyerror!void {
    const node: *rcl.Node = @ptrCast(@alignCast(userdata));
    node.log(@src(), .info, "Got sum: {} + {} = {}", .{query.request.a, query.request.b, query.response.sum});
}

pub fn main(init: std.process.Init) !void {
    const gpa = init.gpa;
    try rcl.init(gpa, init.io, init.minimal.args);
    defer rcl.shutdown();

    var node = try rcl.initNode("sumservice", "", .{});
    defer node.deinit();
    
    var client = try AddClient.init(&node, "add", .{
        .callback = &responseAddTwoInts,
        .userdata = &node,
    });
    defer client.deinit(&node);
    
    var clock = try rcl.Clock.init(.steady, .{});
    defer clock.deinit();

    var timer = try rcl.Timer.init(node.getContext(), &clock, rcl.time.hz(100), .{
        .callback = &requestAddTwoInts,
        .userdata = &client,
    });
    defer timer.deinit();

    const executor = try rcl.Executor.create(node.getContext(), .{.threads = null}); // single-threaded
    defer executor.destroy();
    try executor.spinObjects(.{&client, &timer}, .{});
}
CMake vs build.zig

CMake Code

const std = @import("std");
const ros = @import("rclzig"); // import rclzig dependency build script

pub fn build(b: *std.Build) void {
    const target = b.standardTargetOptions(.{});
    const optimize = b.standardOptimizeOption(.{});

    const rclzig_dep = b.dependency("rclzig", .{});
    const rclzig = rclzig_dep.module("rclzig");
    
    // EXAMPLE PACKAGE SETUP
    const sumservice = b.addExecutable(.{
        .name = "sumservice",
        .root_module = b.createModule(.{
            .target = target,
            .optimize = optimize,
            .root_source_file = b.path("sumservice.zig"),
        })
    });
    sumservice.root_module.addImport("rclzig", rclzig);

    const sumclient = b.addExecutable(.{
        .name = "sumclient",
        .root_module = b.createModule(.{
            .target = target,
            .optimize = optimize,
            .root_source_file = b.path("sumclient.zig"),
        })
    });
    sumclient.root_module.addImport("rclzig", rclzig);

    // NOTE: ROS dependency management is still in-progress
    const example_pkg = ros.Package{
        .target = target,
        .optimize = optimize,
        .artifacts = &.{sumservice, sumclient},
        .dependencies = &.{ros.Dependency{
            .package = "example_interfaces",
            .srvs = &.{"AddTwoInts"},
        }},
    };

    ros.installPackage(b, example_pkg);
    // interface with CMake to be compatible with ROS-native build tools
    _ = ros.generateCMakeStep(b, .{});
}

I’ll publish the codebase when my build system and rcl_action interface is more mature, and when my migration to 0.16 is done. I’d love to hear your thoughts on where Zig fits into robotics!

P.S.

I’ve seen several other “rclzig” or “ROS+Zig” libraries online, but they don’t fit my needs:

jacobperron’s rclzig: untouched for a few years, missing integration with key parts of the ROS software ecosystem.

zig-robotics’ zigros: attempts to replace the Colcon+CMake build system for C/C++ with Zig. I see the value, but this will ultimately compete with Colcon instead of working with it. Also, my goal is to write ROS nodes in Zig, which has a different set of requirements.

10 Likes

I though I’d try and share a small project that helped me keep going since New Years. Dromaius A Novel PS1 Emulator. I’ve been using it to practices my debug skills, only relying on limited documentation to build the system. No AI.

It uses DVUI for the debug user interface and a few of my own custom libraries. The interface is kind of rough, but fun seeking this flicker and change. I’m very much just letting myself try things in different ways. It’s been good sitting down and reading some of the standards on CDRoms and getting to learn about the MIPS cpu. Not the best code in the world, but it is working code.

Oh also a few loose tools on the side like a memory card icon dump and a CDRom tree view. Terminal image viewer with Sixels and block ascii (Benchy terminal raster video). Hilbert spirals too.

So far I can play Crash Team Racing on it (CTR Podium Screen Video). Though it is still missing the sound. It’s been a good project so far to work on.

23 Likes

Imo this goes for more than just Zig, but every language.

With one exception: a plain language binding to a library.

But imo that naming should still be done with the “blessing” of the developers of the library.

4 Likes

There’s this mobile rhythm game I like where the gimmick is that it uses your phone’s gyroscope as gameplay input. It’s pretty common for people to like post screen recordings of their high scores, but it’s honestly pretty nauseating to watch without the gameplay being stabilized like it would be in real life (by your hands of course).

Thankfully the devs have an option in the settings for encoding the angle in the RGB channels in the four corners of the screen. There’s an online tool that will extract that angle and stabilize the video which is awesome, but it doesn’t do much other than that and emscripten ffmpeg is crazy slow.

I recently wrote a program that does the stabilization. It’s ““““novel”””” as in its the first to be able to do it real-time. I’ve done a bit of work to make all device recordings look nice. Using ffmpeg, I also leverage hardware de/encoding to make producing something you’d want to upload to YouTube not take forever. Also some nice defaults like the ring and the background blur!

Basically I used ffmpeg to write a video player, nothing that crazy but I hope someone in the community (who is better at the game than me lol) will use it someday.

I also have a DS emulator I’ve put on hold I’d like to pick that up but I have to upgrade that from like v0.14.0 or something :pensive_face:

Here’s an example. I think it took a few minutes on my laptop and this would have been 4K @ 120fps

13 Likes

I have continued working on zigclc the commandline completion program for the Zig compiler (zig) itself (for fish/zsh/bash). I fixed some issues over the last few days. When you now type zig build <TAB> in the compiler source tree itself, it completes the Project Specific options (as welll as the other two “dynamic” options: Steps and System Integrations (-fsys= / -fno-sys=)

Next step will be 0.16 code generation for zigclc.zig and making it compile. I will probably make the zig version a commandline option for cligen (that generates the zigclc.zig source), so I can also still generate 0.15 code.

Example of installing and running in fish:

https://asciinema.org/a/OWvrXObHtdqnkdLp

17 Likes

The release of 0.16.0 motivated me to make lots of small updates to ziglua that I have been meaning to get around to for years now. I’ll do the same for zf soon too. I just integrated zf into my neovim file picker using ziglua which was fun!

I also recently started making a budgeting / financial web app for myself using Zig. It’s all private and I’m unsure if I will ever share it. But I made a simple html templating library, a simple wrapper around sqlite, and it is coming together very well so far. Nothing more than simple html forms right now, and I’ll eventually add htmx when I need it. One idea I’m excited to try is using Lua for designing custom logic around recurring expenses. I’m not sure if that is over complicated or if it will be useful, but I’m excited to see where it goes!

13 Likes