14 votes

What programming/technical projects have you been working on?

This is a recurring post to discuss programming or other technical projects that we've been working on. Tell us about one of your recent projects, either at work or personal projects. What's interesting about it? Are you having trouble with anything?

16 comments

  1. [3]
    ewintr
    (edited )
    Link
    I could list a couple of half-baked going nowhere projects, but let me do something else. For the last two-and-a-half years, I have been working alone on a backend in a remote job. No-one...

    I could list a couple of half-baked going nowhere projects, but let me do something else. For the last two-and-a-half years, I have been working alone on a backend in a remote job. No-one reviewing my work, no learning from the work of others and also not shipping anything because the priorities keep changing. I am starting to feel burned out.

    To remedy this, I have arranged a break for six weeks to two months with the specific goal of participating in projects with others. I have an eye on a few open-source projects that I perhaps could join for the time. But if anyone here needs the help of a seasoned Go developer, or knows of a project that could use the help: I am all ears.

    For a while, I have had the wish to start with Rust, so that would be cool too. But so far, I have not gotten beyond the hello world example, so I would probably not be of much use there. A project that combines the two would be golden though.

    4 votes
    1. [2]
      xk3
      Link Parent
      It might seem a bit scary at first but the fish-shell codebase is fun to mess around in. Cargo makes it very accessible to get compiling and not worry too much about breaking stuff. Here are some...

      It might seem a bit scary at first but the fish-shell codebase is fun to mess around in. Cargo makes it very accessible to get compiling and not worry too much about breaking stuff.

      Here are some interesting Go and Rust projects sorted by least number of GitHub stars

      2 votes
      1. ewintr
        Link Parent
        Fish shell, ha, that is somewhere on my to-do list as well. To try it out, I mean. Messing around is not something I would have thought of myself. Indeed, sounds a bit scary, but I have some time...

        Fish shell, ha, that is somewhere on my to-do list as well. To try it out, I mean. Messing around is not something I would have thought of myself. Indeed, sounds a bit scary, but I have some time to burn. I'll look into that. Thanks!

        1 vote
  2. ConalFisher
    Link
    Have been learning C for about 6 months now, maybe 5-6 hours a week when I can fit it in, mostly just working through exercises in a textbook. It's fun, but it's a lot of stuff to internalise....

    Have been learning C for about 6 months now, maybe 5-6 hours a week when I can fit it in, mostly just working through exercises in a textbook. It's fun, but it's a lot of stuff to internalise. Haven't even gotten to pointers yet. The end goal is to make some kind of GUI music notation application, probably switching over to C++ eventually but you never know! Going to be a long road before I can reach that kind of programming expertise though.

    4 votes
  3. [3]
    IsildursBane
    Link
    I got my audio player that is using a Raspberry Pi and a clickwheel to control Spotify working on the software side, which is really exciting. Currently I am working on cleaning up and documenting...

    I got my audio player that is using a Raspberry Pi and a clickwheel to control Spotify working on the software side, which is really exciting. Currently I am working on cleaning up and documenting the code, to prepare for adding in new features.

    On the hardware side of things I have everything now, but the battery controller appears to be defective so that will need to be returned. It is a bit disappointing that it is defective, as I was about to create a demo video to share of the project in its current state before I put everything into an enclosure. I do have all the hardware at the moment before I return the battery controller, so I am going to take measurements and figure out 3D modelling software to 3D print an enclosure for the project

    4 votes
    1. [2]
      Weldawadyathink
      Link Parent
      It has been really fun to follow along with your project. Thanks for sharing. It sounds like you are very close to a functioning device.

      It has been really fun to follow along with your project. Thanks for sharing. It sounds like you are very close to a functioning device.

      2 votes
      1. IsildursBane
        Link Parent
        I have a functioning device, just not a portable device yet. Sharing has been useful for me as I have had some comments giving me suggestions on the hardware side that I have ended up using as...

        I have a functioning device, just not a portable device yet. Sharing has been useful for me as I have had some comments giving me suggestions on the hardware side that I have ended up using as well as just writing it out has provided me what currently needs to be done when I have been modifying the codebase I started with.

        Once I get it portable, there is still a long list of features that I want to expand the software with. I also am considering some last minute minor hardware modifications to improve the device functionality, but those could also probably be implemented after it is portable.

  4. thereticent
    Link
    I removed all the key caps and scissor switches on my Freewrite Traveler, cleaned them all and the keyboard chassis, then put them back on. I wasn't great at it. I broke about 10 scissor switches....

    I removed all the key caps and scissor switches on my Freewrite Traveler, cleaned them all and the keyboard chassis, then put them back on. I wasn't great at it. I broke about 10 scissor switches. Thankfully, the company is sending replacements for a total of $5. Now I'll just need to be more careful with my inspiration Cabernet.

    I'm even more proud to say that I just finished cleaning and leveling the keys and "hammers" in a Korg Concert 5000 keyboard. This involved:
    -disassembling the piano to remove the keyboard
    -removing each of the 88 flat springs, 88 hammers, and 88 key covers
    -wiping down the keyboard chassis, lubricating all contact points with dielectric grease
    -washing the key covers with detergent
    -wiping down and relubricating the hammers (these were so grungy)
    -lubricating contact points on the key covers
    -reassemble each key complex on the keyboard
    -reassemble the piano
    -(along the way I also had to super glue one of the plastic hooks back on a key cover. These make sure the key cover can't be pulled upward)

    It works! I just have to get the felt strip reglued tomorrow, and it will be as good as new!

    Well, sort of. I bought this thing at a steep discount from a local working musician as a gift for my spouse 13 years ago. It is battered to hell on the outside, but now at least the inside isn't full of bar smoke grease crap from 100s of gigs. But the keys were so sticky after just a few months of use (and some misuse by small children along the way) that we could never stand to play it. Super great mindfulness activity, ending in a feeling of having rejuvenated something.

    3 votes
  5. Akir
    Link
    Honestly for the past few weeks I have been ignoring my project. It’s actually got my anxiety acting up. It’s at the point where I am having a hard time fitting it all in my mind, which is a...

    Honestly for the past few weeks I have been ignoring my project. It’s actually got my anxiety acting up. It’s at the point where I am having a hard time fitting it all in my mind, which is a problem because the point I am trying to work on right now is where all the functionality I have made so far is supposed to fit together.

    2 votes
  6. zestier
    (edited )
    Link
    I've been working on a project to use SDL GPU to render a many-entity simulation, like simulating a million worker ant colony. I started the project because the idea of making the simulation...

    I've been working on a project to use SDL GPU to render a many-entity simulation, like simulating a million worker ant colony. I started the project because the idea of making the simulation itself sounded fun, but I've ended up down a tangential rabbit hole of playing with the graphics stuff. Trying out different shader languages and compilers, trying different approaches to multi threading, hooking shader complication into my CMake build process, and so on. I'm having a surprising amount of fun diving into the weeds of SDL's Vulkan implementation. This has been a problem for making progress because I'm too distracted by using the project as a bit of a Slang/Vulkan/SDL playground.

    Edit: I should've originally added what my favorite multi-threading synchronization structure has been for multi-threading GPU commands from the CPU. This favorite structure has basically been just no synchronization at all. Instead, I'm embedding all the data into a fixed set of GPU buffers, and drawing whatever their latest state is at any given time. So I can do things like change the number of entities being rendered without synchronizing the main rendering thread and the main simulation thread because the simulation thread embeds all that data into the buffer it is writing to. The main rendering thread just makes an identical indirect draw call every frame without needing to know what's in the buffer.

    2 votes
  7. [2]
    Toric
    Link
    A while back I posted about rmk, a rust keyboard firmware based on embassy. I made a configuration for my ferris sweep, but couldnt get the communication between the 2 halves working without...

    A while back I posted about rmk, a rust keyboard firmware based on embassy. I made a configuration for my ferris sweep, but couldnt get the communication between the 2 halves working without lowering the baud rate by 10x. Turns out, this is a limitation of the RP2040, where its internal pull up resistors are somewhat weak, meaning that if you have a longer TRRS cable between your split halves, or even a badly routed trace, it can degrade comms.

    Turns out, QMK (the more popular C-based firmware for keyboards), also had to fight this problem, and came up with a solution to it, essentially by making the receiving side weakly pull the line up to simulate a really strong pull-up resistor. I implemented this solution in rust, and built a breadboard based 'keyboard' with 2 keys and 2 pi picos to test it without risking my expensive keyboard controllers. (Even though QMK uses this solution, I was still wary about making 2 pins pull a line in opposite directions, its the sort of thing that burns out pins.)

    Anyway, the tests went perfectly, and my pull request was just merged!

    2 votes
    1. xk3
      Link Parent
      Fascinating! Thanks for sharing. I love seeing small puzzles like this. I put together a Let's Split before and love QMK. Great idea checking for prior art

      Fascinating! Thanks for sharing. I love seeing small puzzles like this.

      I put together a Let's Split before and love QMK. Great idea checking for prior art

  8. Jao
    Link
    I have been working on making a handwired mechanical keyboard, specifically the ScottoErgo design by the youtuber JoeScotto. It's one of those small ones so it only has 36 switches. Though I...

    I have been working on making a handwired mechanical keyboard, specifically the ScottoErgo design by the youtuber JoeScotto. It's one of those small ones so it only has 36 switches. Though I modified his design to use a USB C connector instead of the aviator connector he used.

    2 votes
  9. xk3
    (edited )
    Link
    The past couple days I've been playing around with cookies and I made a little cookie testing site: https://unli.xyz/cookietest.html And I was wondering why the cookieDisplay wasn't showing up in...

    The past couple days I've been playing around with cookies and I made a little cookie testing site: https://unli.xyz/cookietest.html

    And I was wondering why the cookieDisplay wasn't showing up in Firefox but not in Chromium and it was because of my I don't care about cookies addon which was hiding that div. So that gave me a silent chuckle and only took about 30 seconds to figure out (I renamed cookieDisplay to c: that's good enough for me).

    This next part is more vexing... I'm trying to use the site to check that cookies are maintained across page loads:

    python -m library.lb text --selenium --cookies-from-browser firefox https://unli.xyz/cookietest.html?cookieValue=t https://unli.xyz/cookietest.html?cookieValue=test2 https://unli.xyz/cookietest.html?cookieValue -vv # --manual
    

    https://github.com/chapmanjacobd/library/commit/d9d2488081f6844bcbf7d565d6ad40a871213985

    But the site is behaving differently inside of selenium and outside--it's almost like it can't read the cookie once I set it after the first page load. It's probably something simple but the solution is eluding me for the past 45 mins... I'll take a short break.

    1 vote
  10. milkywayflyinginsect
    Link
    I'm not currently working on it, but planning on soon developing an Obsidian plugin to allow me to recursively copy all headlines and sub-headlines from a file or a folder (all files within that...

    I'm not currently working on it, but planning on soon developing an Obsidian plugin to allow me to recursively copy all headlines and sub-headlines from a file or a folder (all files within that folder). Simple little project but would be incredibly useful for me as I document anything that I'm learning on Obsidian. So like if I encounter some question / pattern and other stuff I make sure to note it down so next time I can quickly look it up. I also sometimes include the material itself (like from a book).

    So it would allow me to quickly copy all headlines from a folder and feed it into an LLM to help me search through what I'm looking for and where it could be for cases when ordinary search doesn't work that well (like if I don't recall precisely how the thing I'm searching for was worded) I'm talking about hundreds or thousands of headlines /sub-headlines here over lots of files here, by the way.

    I haven't found anything on the plugin store that would do that.

    1 vote
  11. Eji1700
    Link
    Been knee deep in a refactor for a bit that's actually gone quite well in the end. I have datasets that have various rules applied to them. I need to remove records that fail some rules ( but...

    Been knee deep in a refactor for a bit that's actually gone quite well in the end. I have datasets that have various rules applied to them. I need to remove records that fail some rules ( but still output them at the end so i can investigate why), and then after those I need to do a cleanup pass to adjust some records.

    Reduced the logic of it all to something easier dealing with ints for feedback but it's probably one of the things i'm happier with. Lots of useage of the things that make F# great, and should be very reusable in my workflows.

    Full code if you'd like to see. You should be able to run this in the F# repl/as an .fsx
    type Data =
        {   GoodRecords: int array
            ErrorRecords: int array
            Modifier: int }
    
    module Remove = 
        let removeTemplate logic record = if logic then Error record else Ok record
        let notEven record = removeTemplate (record % 2 <> 0) record
        let is0 record = removeTemplate (record = 0) record
    
        let rules =
            [|  notEven
                is0 |]
    
    module Clean = 
        let cleanNames record : Result<int,int> =
            Ok record
    
        let doStuff record : Result<int,int>=
            Ok record
    
        let applyModifier modifier record : Result<int,int> =
            let newRecord = modifier + record
            Ok newRecord
    
        let rules modifier =
            [|  cleanNames
                doStuff
                applyModifier modifier |]
    
    let applyRules rules record =
        rules
        |> Array.fold (fun record rule -> Result.bind rule record) record
    
    let unwrapResult r = Result.defaultWith id r
    let allRules modifier =
        Clean.rules modifier
        |> Array.append Remove.rules
    
    let Apply data =
        let good, errors =
            data.GoodRecords
            |> Array.map(fun record -> applyRules (allRules data.Modifier) (Ok record))
            |> Array.partition Result.isOk
    
        { data with 
            GoodRecords = good |> Array.map unwrapResult
            ErrorRecords = errors |> Array.map unwrapResult }
    
    let testData =
        {   GoodRecords = [| 1; 2; 3; 4|]
            ErrorRecords = [||]
            Modifier = 1}
    
    Apply testData
    
    1 vote