6 releases

Uses new Rust 2024

0.3.0 Jun 10, 2025
0.2.0 Oct 19, 2024
0.1.3 Nov 19, 2023
0.1.2 Sep 21, 2023
0.1.1 Feb 21, 2023

#549 in Hardware support

Download history 155/week @ 2025-07-09 4/week @ 2025-07-16 15/week @ 2025-07-23 221/week @ 2025-08-06 41/week @ 2025-08-20 5/week @ 2025-08-27 220/week @ 2025-09-03 10/week @ 2025-09-10 222/week @ 2025-09-17 218/week @ 2025-09-24 33/week @ 2025-10-01 8/week @ 2025-10-08 21/week @ 2025-10-15 52/week @ 2025-10-22

116 downloads per month
Used in boardswarm

MIT/Apache

64KB
1.5K SLoC

Rockchip usb protocol host implementation

Rockchip bootroms and early loaders implement an USB protocol to help loader early firmware, flashing persistant storage etc. This crate contains a sans-io implementation of that protocol as well as an optional implementations of IO using libusb or nusb.

Printing chip info using libusb backend:

# #[cfg(feature = "libusb")] {
# fn main() -> anyhow::Result<()> {
let devices = rockusb::libusb::Devices::new()?;
let mut device = devices.iter().next()
    .ok_or_else(|| anyhow::anyhow!("No Device found"))??;
println!("Chip Info: {:0x?}", device.chip_info()?);
Ok(())
# }
# }

Printing chip info using nusb backend:

# #[cfg(feature = "nusb")] {
# #[tokio::main]
# async fn main() -> anyhow::Result<()> {
let mut devices = rockusb::nusb::devices()?;
let info = devices.next()
    .ok_or_else(|| anyhow::anyhow!("No Device found"))?;
let mut device = rockusb::nusb::Device::from_usb_device_info(info)?;
println!("Chip Info: {:0x?}", device.chip_info().await?);
Ok(())
# }
# }

Dependencies

~0.6–14MB
~152K SLoC