by ahartmetz
7 subcomments
- > I also thought I’d message the vendor and ask them if they could share any specifications or docs regarding their protocol. To my surprise, Nanoleaf tech support responded to me within 4 hours, with a full description of the protocol that’s used both by the Desk Dock as well as their RGB strips.
How cool is that? Too many vendors still think that they have valuable intellectual property in such relative trivialities. And that handing out the specs freely helps their competitors more than themselves.
- This is awesome!
But it also makes me a little bit sad. The original parallel port and even ISA interface seemed so simple by comparison, with less layers of abstraction. Just run a wire, and write to a port.
I remember when I was a kid, I found a breakout board in an electronics store's random clearance parts bin, with an ISA header on an edge. On a whim I took it home and wire-wrapped a 7-segment LED onto it. Power and ground were easy. Each segment was hooked to a data line, through a simple buffer IC. I cheated and used only a minimal number of address lines to feed the enable port (guessing through a simple AND gate or something). I was amazed when I wrote to that address and it worked the first time!
I look at a protocol like USB, with hundreds of pages, and instead of that curious excitement and enablement I felt back then, I feel a bit overwhelmed.
by ianlevesque
0 subcomment
- It’s a userspace USB HID driver in rust, which is honestly more interesting/applicable to me than a kernel driver, which is what I thought it meant from the title.
- I really enjoyed the way this post was written, i.e. it includes the code, how it was run, the false paths, etc. You almost get to live through the author's journey and how he figured out just enough to get something working.
- The title was misleading because the author wrote a userspace Rust driver and not a Linux kernel driver in C.
by kblissett
2 subcomments
- I enjoyed this post, but I'm eager to hear what the next step would be for a real "production" userspace driver. Are these typically just daemons that are configured to run at start up? And then some configuration GUI communicates with it over a socket or something?
- Love it! I wrote an RTL8139 Ethernet driver in Rust as my undergrad thesis!
With questionable grammar: [https://rajiv256.github.io//projects/ouros/](link)
- Given the title, I'm surprised (in a good way) that it's not about AI coding.
- > Let’s run it again to make sure it was not a fluke!
I understood that reference
- Nice article here, really enjoys the explanation.
As a web developer, system programming or in this case developing a device driver feels like a different world to me. But, after reading this article, I got the impression that it is not that much different to developing a client to an API in web developer's world.
by 0xbadcafebee
3 subcomments
- I want to run FreeBSD on my laptop, but they don't have a [complete] driver for my wifi card. I've thought about diving into AI coding-assistant agents just to see if I could use one to finish throwing together a working driver... but figuring out the AI agents is frictiony enough that I'm leaving it be. (I'm not a VSCode user)
- The author should probably have implemented support in OpenRGB instead to better benefit others, but this is cool nonetheless.
- I wish this was done in C so I didn't have to learn Rust. But maybe it is time to learn Rust.
- This is just so amazing, you've definitely made me want to try this out some day! Brings me back to engineering school days where we'd try to tweak just about anything with an interface!
- This is exactly the kind of simple tutorial I was looking for a few years ago. I forget what the project was that I wanted this for, though, haha. Thank you for the writeup!
by jonnypotty
0 subcomment
- Thanks for this. Good read and also kinda inspiring.
by VTimofeenko
0 subcomment
- Excellent post! I have a Nanoleaf 3d thing that I was hoping to use as an ambilight-like thing for the TV, but the experience was... meh. I know about the Hyperion project and hope to set it up one day, but meanwhile I think I could try to repurpose this code to control the strip from a Linux box.
- Does this provide protection against opening then device from two processes at the same time?
- Recommendations for a tutorial on how to write a formally verified kernel module in C? Rust?
Are VFIO or eBPF sufficient; Does this code need to run in the kernel?
by marsven_422
0 subcomment
- [dead]
- There are many innovative OSes that are killed by the lack of Device Drivers.
As a community we must find a way for tackling this issue.
Micro-Kernels are a solution where one can run different OSes but they will reuse the same device driver servers.
But it requires co-ordination and determination.
Rust can be a solution for sure.