libusb_transfer_flags enum
\ingroup libusb_asyncio libusb_transfer.flags values
Values
- LIBUSB_TRANSFER_SHORT_NOT_OK → const libusb_transfer_flags
-
Report short frames as errors
const libusb_transfer_flags(1)
- LIBUSB_TRANSFER_FREE_BUFFER → const libusb_transfer_flags
-
Automatically free() transfer buffer during libusb_free_transfer(). Note that buffers allocated with libusb_dev_mem_alloc() should not be attempted freed in this way, since free() is not an appropriate way to release such memory.
const libusb_transfer_flags(2)
- LIBUSB_TRANSFER_FREE_TRANSFER → const libusb_transfer_flags
-
Automatically call libusb_free_transfer() after callback returns. If this flag is set, it is illegal to call libusb_free_transfer() from your transfer callback, as this will result in a double-free when this flag is acted upon.
const libusb_transfer_flags(4)
- LIBUSB_TRANSFER_ADD_ZERO_PACKET → const libusb_transfer_flags
-
Terminate transfers that are a multiple of the endpoint's wMaxPacketSize with an extra zero length packet. This is useful when a device protocol mandates that each logical request is terminated by an incomplete packet (i.e. the logical requests are not separated by other means).
This flag only affects host-to-device transfers to bulk and interrupt endpoints. In other situations, it is ignored.
This flag only affects transfers with a length that is a multiple of the endpoint's wMaxPacketSize. On transfers of other lengths, this flag has no effect. Therefore, if you are working with a device that needs a ZLP whenever the end of the logical request falls on a packet boundary, then it is sensible to set this flag on every transfer (you do not have to worry about only setting it on transfers that end on the boundary).
This flag is currently only supported on Linux. On other systems, libusb_submit_transfer() will return \ref LIBUSB_ERROR_NOT_SUPPORTED for every transfer where this flag is set.
Available since libusb-1.0.9.
const libusb_transfer_flags(8)
Properties
- hashCode → int
-
The hash code for this object.
no setterinherited
- index → int
-
A numeric identifier for the enumerated value.
no setterinherited
- name → String
-
Available on Enum, provided by the EnumName extension
The name of the enum value.no setter - runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
- value → int
-
final
Methods
-
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
toString(
) → String -
A string representation of this object.
inherited
Operators
-
operator ==(
Object other) → bool -
The equality operator.
inherited
Static Methods
-
fromValue(
int value) → libusb_transfer_flags
Constants
-
values
→ const List<
libusb_transfer_flags> - A constant List of the values in this enum, in order of their declaration.