G2-Games / cross-usb

A Rust USB library which works on both native and WASM targets

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Cross USB

A USB library which works seamlessly across most native and WASM targets.

Crates.io

Documentation


Note

Web USB only works in Chromium based browsers for now.

Dependencies

For native USB, the crate utilizies nusb, a pure rust library similar to the very popular libusb.

For WASM, this crate utilizes web-sys which gives access to browser API calls, and in this case is used to interact with WebUSB

TODO

  • Add choice for native backend between libusb wrapper and pure rust nusb
  • Allow platform-specific operations if the user requires them
  • Hot plug support... requires either using libusb as an optional backend or for nusb to implement it

About

A Rust USB library which works on both native and WASM targets

License:GNU Affero General Public License v3.0


Languages

Language:Rust 100.0%