I'm writing a user interface program for USB device in C++ using Visual Studio 2019. I'm using libusb library. I want to do bulk transfer to the device, and I'm trying to understand the exact function of libusb_bulk_transfer, more specifically - does it add CRC? The definition from the documentation:
int libusb_bulk_transfer(struct libusb_device_handle *devh, unsigned char endpoint, unsigned char *data, int length, int *transferred, unsigned int timeout) Perform an USB bulk transfer. A timeout value of zero means no timeout. The timeout value is given in milliseconds. Returns 0 on success, LIBUSB_ERROR_TIMEOUT if the transfer timed out, LIBUSB_ERROR_PIPE if the control request was not supported, LIBUSB_ERROR_OVERFLOW if the device offered more data, LIBUSB_ERROR_NO_DEVICE if the device has been disconnected and a LIBUSB_ERROR code on other failure.
From what I've understood, the function libusb_bulk_transfer creates the packet and transfers it to the desired endpoint for me, and I only need to supply it the data itself. when this function builds the packet, does it add a CRC?
If it doesn't, is there a different method to do the bulk transfer so I can control whether the CRC is added or not?</div