Hello,
It seems that you are having issues with the Linux D3xx driver and Windows D3xx driver is OK?
Please check that you are using the latest driver versions:
https://ftdichip.com/drivers/d3xx-drivers/ Please see the following information on Transfer efficiency in D3XX Linux Library:
The D3xx for Linux library allocates a reading queue with 256 of 32Kbytes buffers internally by default at startup, it will keep requesting to the host driver until there is no free buffer in the queue, and the library will not combine returned buffer in the queue.
- When fStopReadingOnURBUnderrun flag is set, the FT_ReadPipe / FT_ReadPipeEx API will return immediately when encountering any buffer with length less then 32Kbytes, even if there are more filled buffers in the queue.
- When fStopReadingOnURBUnderrun is not set, the FT_ReadPipe / FT_ReadPipeEx API will try to satisfy the requested reading size by merging all available filled buffers in the queue, buffer size is ignored.
Transfer efficiency is not determined by the reading size in D3XX for Linux, our tests showing that best performance can be achieved as long as the reading size is >= 3bytes each time.
Non 1K aligned data will cause additional process time on FIFO bus, FT600 bridge chip and USB3 bus, the overhead could cause FPGA master's FIFO buffer overflow, and wrong data will be collected.
Best performance can be achieved when FPGA is sending 1K aligned data as much as possible. If its not feasible to change FPGA's behaviour, try setting: CONFIGURATION_OPTIONAL_FEATURE_DISABLEUNDERRUN_INCHALL flag in chip configuration to remove the latency on USB3 bus.
Also try to avoid doing any heavy processing or calls to printf() from the thread which calls FT_ReadPipe(), otherwise the library's reading queue may be used up. You can use another thread to parse, or simply dump all the content into another file to verify the issue.
Best Regards,
FTDI Community