v0.2.0-beta.1 #136
kevinmehall
announced in
Announcements
Replies: 2 comments 1 reply
-
|
Thanks for work on this - looking good. Minor documentation I noticed is incorrect whilst adapting to changes: Line 31 in 4edb4a4 |
Beta Was this translation helpful? Give feedback.
0 replies
-
Would you like to explain more about this change here? What's the technical benefit? Please tell us. |
Beta Was this translation helpful? Give feedback.
1 reply
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
-
This is a pre-release for anyone interested in testing the new functionality and APIs in v0.2.
New Features
EndpointAPI. (Redesign endpoint and transfer API #117)MaybeFuture. If you are using them asynchronously, you will want to enable thesmolortokiofeatures to defer the blocking syscalls to the corresponding runtime's blocking thread pool. (Make blocking APIs optionally async #100)DeviceInfo::port_chainwith the path of port numbers from the root hub to this device. (Add DeviceInfo::port_chain #71)list_buses()andBusInfofor information on USB buses. (List root hubs function #77)TransferError::Unknown. (TransferError::Unknownshould contain OS error #64)Device::device_descriptorfor access to device details from an opened device. (Add support for getting device information from opened device on Linux #102)RAW_IOfor bulk IN endpoints for improved performance. (Use RAW_IO on Windows for bulk and interrupt IN endpoints #6)Endpoint::allocate. (Linux usbfs zero-copy support #11)Fixes
Breaking Changes
list_devicesDeviceInfo::open,Device::from_fd,Device::set_configuration,Device::reset,Interface::set_alt_setting,Device::claim_interfaceDevice::detach_and_claim_interface, andEndpoint::clear_haltnow returnimpl MaybeFuture. Adduse nusb::MaybeFutureand call.wait()for previous blocking functionality.Queuehas been replaced byEndpoint.Interfacemethods for single bulk and interupt transfers withTransferFuturehave been removed -- useEndpointor upcoming IO wrappers.InterfaceandDevicemethodscontrol_in_blocking/control_out_blockinghave been replaced withcontrol_in/control_outwith.wait()fromMaybeFuture.InterfaceandDevicemethodscontrol_in/control_outnow accept a timeout. Dropping the returnedFutureno longer cancels the transfer.DeviceInfo::bus_number(integer) has been replaced withDeviceInfo::bus_id(string).EndpointTypetoTransferType.NonZeroU8for string descriptor indexes.Optioninstead of panic.TransferError::Unknownhas an integer field for the error code.Minimum Rust version is now 1.79.
Remaining for v0.2
Endpointand managing transfers and buffers to implementBufRead,AsyncBufRead,Write,AsyncWriteto replace removedInterfacemethods for simple use cases.Contributors
@kevinmehall @pgorgon-hem @kirisauce @tuna-f1sh @CCnut @martinling
This discussion was created from the release v0.2.0-beta.1.
Beta Was this translation helpful? Give feedback.
All reactions