Side Quests

Started by snow, Mar 16, 2025, 11:57 PM

Previous topic - Next topic

snow

Tangential to the typical "yak stack", I have a tendency to get lost in projects that are spurred by (but not necessarily related to) a bigger project. They're typically far enough out of my wheelhouse that they don't fit the usual things I talk about, but I end up learning the most from them.

These projects remind me of side quests in RPGs-- the bits that don't necessarily progress the story, but can make for a fun break from the bigger things. So that's what I'm calling them!

Of course, don't feel obligated to put something here instead of making a new topic. I don't want it to feel like there's an "effort minimum" for topics on F9, and this is just an attempt to break through my own apprehension for Posting. But that said, feel free to use this place to talk about weird and random things you find yourself tinkering with or learning about.



As for my current side quest: A while ago, I was given a USB wireless headset from someone who no longer had a use for it. An especially cool feature is that it can communicate with programs like Microsoft Teams or Slack to mute and unmute the mic both in hardware and software, or to start/end calls by pressing a button on the headset. This isn't done by emulating a keyboard, instead being a separate class of HID device.

Most non-business voice chat programs don't support the functionality, which makes sense: it's a Business Headset for Business Meetings, and I imagine most people wouldn't use it outside of that. There seems to be a standard, if this 3CX document is to be believed, but I've yet to find a spec actually documenting it.

There is a library by people at Google, libhidtelephony, but it relies on WebHID, an API with very little browser support. Also, I'm planning to use this with Mumble, and I'd rather not require a web browser just to bounce commands back and forth with a non-web app.

WebHID parses the binary report descriptors for you, along with the input/output descriptors you use to communicate with the device. I've yet to find a native library that handles that for me, so I'm stuck building my own parsers. I'm basically starting from no knowledge of the low-level USB protocol, so it's been a lot of learning the terminology on top of the actual HID specification.