4 ms·
I actually prototyped the thing in python the first time around, but performance was too poor to pass through even a single joystick, so Rust it was, lol. As f
by saulrh 3y ago
I actually prototyped the thing in python the first time around, but performance was too poor to pass through even a single joystick, so Rust it was, lol.
As for software translation, that was out early in the design process: I needed Windows and I did not want to write a Windows device driver or fight with code signing. Nor did I want a Windows-only or Linux-only solution. So the only solution was to control the platform the software ran on (-> raspberry pi), then drop down far enough in the stack that everyone agreed on a protocol (-> USB HID). I would have been very very happy if I could have implemented this at a higher level.
- sitkack 3y agoSorry, I re-read my comment and I wasn't trying to argue against you, just how messed up the OSes are and that everything is basically a stack of hacks, even the "good stuff". I like that you prototyped it in Python first. I wonder why it didn't work? Python function call overhead? It would be neat if there was a cross platform USB HID muxing and translation layer that used Wasm for all its logic, then the "fixups" would be portable.
- saulrh 3y agoI didn't do a ton of debugging before giving up and switching away from python, but I think that at least some of it was issues with the event loop and cost of serialization introducing latency. Yeah, I think some of my irritation with the situation bled through there, lol, didn't mean to come off as aggressive. I also lament the absence of a common input standard of some sort. WASM or the like would be a neat common layer; I feel like it's a good target for embedded scripting and module systems these days.