7 个版本 (稳定)
| 1.2.0 | 2023年2月17日 | 
|---|---|
| 1.1.4 | 2022年10月11日 | 
| 1.1.3 | 2022年8月19日 | 
| 0.1.1 | 2022年8月11日 | 
在 硬件支持 中排名 1245
每月下载量 22
31KB
752 代码行
pirate-midi-rs
描述
Rust 库,用于向 Pirate MIDI 中继桥设备发送串行命令
用法
在运行命令之前,请确保您的中继设备已通过 USB 连接。
    // create our test device
    let device = PirateMIDIDevice::new();
    // get device details
    let response = device.send(Command::Check).unwrap(); // use a `match` instead of `.unwrap()`
    // enter the bootloader
    // the device will detach and then reattach in bootloader mode, and the serial port will no longer be available.
    // will return `ok`, but any subsequent commands will throw an error
    match PirateMIDIDevice::new().send(Command::Control(ControlArgs::EnterBootloader)) {
        Ok(_) => Ok(()),
        Err(err) => panic!("unable to enter bootloader: {}", err),
    }
依赖项
~3.5–5MB
~102K SLoC