FTDI Community

General Category => Discussion - Hardware => Topic started by: Rajesh@sys on August 06, 2019, 02:39:37 PM

Title: ft232h suspend mode
Post by: Rajesh@sys on August 06, 2019, 02:39:37 PM
hi,


i am using ft232h in 245 FIFO synchronous mode.  i am using Hercules to Read data from USB.

after writing few frames of data (1frame= 512bytes) roughly 20 frames.

TXE is going to high state. and when it comes to low state my hardware not writing data.

please let me know how to make ft232h to write continuous data.?



Regards,
Raeshkumar
Title: Re: ft232h suspend mode
Post by: Rajesh@sys on August 07, 2019, 06:21:50 AM
is USB going to suspend mode ?
Title: Re: ft232h suspend mode
Post by: FTDI Community on August 07, 2019, 03:35:19 PM
Hello Rajesh,

USB suspend is controlled by the USB host telling the peripheral device to go to suspend.
The FTDI drivers do not force the FTxxx devices to go to suspend.
If the USB data bus is idle for >3ms the USB host should put the FTxxx into suspend.
To prevent this happening you should ensure there is always data within 3ms.

The 245 FIFO interface should only be written to when the TXE# pin is logic 0.

The TXE# pin will go to logic 1 and back to logic 0 for every byte latched in.

If the application on the PC never reads any data the buffer on the PC (64kbytes) and the buffer on the chip will become full.

When these buffers are full the TXE# line should remain at logic 1 until the application on the PC does a read to free up some space.

Some users report TXE# goes back to logic 0 after a brief period (actually matches latency timer).

This can result in data loss due to overrun.

To prevent this from happening the application on the PC should have set flow control for RTS_CTS flow control.

Although the hardware does not have RTS/CTS pins the driver does not know this, but it is now forced to monitor certain status bits, which allows the TXE# pin to be kept at logic 1 until space is made available.

Best Regards,
FTDI Community
Title: Re: ft232h suspend mode
Post by: Rajesh@sys on August 08, 2019, 08:41:32 AM
thank you so much for reply.



please explain the statement
<Although the hardware does not have RTS/CTS pins the driver does not know this, but it is now forced to monitor certain status bits, which allows the TXE# pin to be kept at logic 1 until space is made available>


how to Implement status bit logic ??


Thanks&Reagrds,
Rajeshkumar Athram


Title: Re: ft232h suspend mode
Post by: FTDI Community on August 09, 2019, 03:31:22 PM
Hello Rajesh,

Please see my previous post:

"The application on the PC should have set flow control for RTS_CTS flow control."

This will then be handled by the IC.

So ensure you have set this in your software:

Code: [Select]
// Set RTS/CTS flow control
ftStatus = FT_SetFlowControl(ftHandle, FT_FLOW_RTS_CTS, NULL, NULL);
if (ftStatus == FT_OK)
{
// FT_SetFlowControl OK
}
else
{
// FT_SetFlowControl Failed
}

Best Regards,
FTDI Community