Comments (7)
libusb_bulk_transfer & libusb_interrupt_transfer are no longer being used, so this seems to be resolved.
from gousb.
Actually not just yet - transfer() returns 0 on error
from gousb.
but I'm working on it :) I'll update this issue when I think all places are correct and covered by tests.
from gousb.
Sure thing, though looking at the documentation it seems like the status of partial asynchronous transfers will be set to LIBUSB_TRANSFER_COMPLETED:
http://libusb.sourceforge.net/api-1.0/group__asyncio.html#ga9fcb2aa23d342060ebda1d0cf7478856
Is this misleading and LIBUSB_TRANSFER_TIMED_OUT can still be returned with partial xfer data?
from gousb.
I think so. It's still the case that a single transfer might be split up by the host into multiple transactions, and some of them might succeed before the transfer completes. Same with isochronous transfers where some packets are transmitted before the transfer times out. But I'm not really sure and I haven't dig through libusb sources to check. If you want to look for confirmation one way or another in libusb sources, that'd be welcome :)
from gousb.
Skimming through the code, seems that you're right - libusb_bulk_transfer just uses the asynchronous functions, so the two seem to share the same behavior - LIBUSB_TRANSFER_TIMED_OUT may be returned with actual_length != 0.
from gousb.
I believe this is now addressed.
from gousb.
Related Issues (18)
- Using with Homebrew's libusb HOT 12
- GPL use of xbox.go HOT 1
- Paths are hardcoded in usb.go HOT 1
- Writing or copying files to USB devices HOT 5
- Embedded libusb? HOT 7
- Any examples for writing to devices? HOT 3
- read systematic timeouts HOT 9
- Race condition when closing Context
- Link in short description returns a 404 HOT 1
- Flexible array members (in libusb.h) not supported on arm-linux-gnueabihf (Raspberry Pi 3) with gcc 5.4 HOT 21
- xfer_callback panic HOT 5
- Appveyor build HOT 14
- Deprecation notice HOT 1
- Endpoint problem HOT 11
- How to link libusb on mac if I want to release a program without "brew install libusb" HOT 1
- Segfault if more than one usb context created HOT 8
- libusbx HOT 2
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from gousb.