FTDI Community

Please login or register.

Login with username, password and session length.
Advanced Search  


Welcome to the FTDI Community!

Please read our Welcome Note

Technical Support enquires
please contact the team
@ FTDI Support

New Bridgetek Community is now open

Please note that we have created the Bridgetek Community to discuss all Bridgetek products e.g. EVE, MCU.

Please follow this link and create a new user account to get started.

Bridgetek Community

Author Topic: Unexpected behavior of timeout  (Read 236 times)


  • Newbie
  • *
  • Posts: 1
    • View Profile
Unexpected behavior of timeout
« on: April 24, 2019, 10:25:15 PM »

Hello, I'm working with a device which communicates with a PC using a FTDI chip and I found an unexpected behavior when I set up timeout and then I tried to read data from the device. The device is a Aaronia spectrum analyzer which utilizes a FTDI 232R chip. The PC is a Raspberry Pi 3B+ with Raspbian which I installed the D2XX driver (version 1.4.8 ARMv6). The problem arose when I set up the timeout values and then I tried to read data from the device. I decided to set it up to 10 seconds initially and then reduce it many times up to the minimum possible value which allows a correct operation. With the initial value (10s) I tried to read data from the device and I got error messages which stated no bytes were read. After many tries to solve the problem changing the read timeout, I  managed to solve it adding a call to "usleep" function with 200000 (200ms) as argument before the reading operation, so I found the reading function was not blocking to wait the data during the timeout. I tried the same operation in my notebook HP 14-an020la with Debian 4.9.130-2 and I got the same result.
What could it be the error? Am I correctly understanding the timeout?

FTDI Community

  • Administrator
  • Sr. Member
  • *****
  • Posts: 263
    • View Profile
Re: Unexpected behavior of timeout
« Reply #1 on: April 26, 2019, 03:29:50 PM »


Have a look at our Data Throughput, Latency & Handshaking Application Note where you will find some information:


Our USB Data Transfer Efficiency Technical Note may also be of use as it looks at the factors influencing the efficiency of data transfer for FTDI devices:

In addition have a look at this Application Note on Optimizing D2XX Data Throughput:

FTDI Community