Hacker News new | ask | show | jobs
by gregsadetsky 1152 days ago
I’ve been curious for a while - would it make sense for some USB drivers to be adapted / recompiled to WASM and used via web pages? (Chrome can allow JS code to access USB devices)

Like in this case, would it have made sense to recreate the driver in this way so that other owners of the same camera could have immediately tried it out in their browsers regardless of their operating system?

How OS-specific are most USB devices?

1 comments

Don't know about webcams - usually (unlike in OP's case) those already have good OS-level support, but I did port gphoto2 to Wasm+WebUSB for access to DSLRs & mirrorless cameras: https://github.com/GoogleChromeLabs/web-gphoto2
Amazing, thanks for sharing

And really great write up too!

https://web.dev/porting-libusb-to-webusb/

Thanks, be sure to check out the part 2 as well :)