FTDI Community

Please login or register.

Login with username, password and session length.
Advanced Search  

News:

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: FT230xs USB basic UART converter dropping frames  (Read 16562 times)

asusrog

  • Newbie
  • *
  • Posts: 3
    • View Profile
FT230xs USB basic UART converter dropping frames
« on: November 21, 2019, 11:54:09 AM »

I'm working with a custom STM32F429 board, I am using serial-USB port (USART1-PA9,PA10) for debug output and diagnostics. When I connect the board the FTDI chip is recognized and proper kernel modules are loaded.

dmesg output:

[  260.406486] usb 2-1.1: new full-speed USB device number 7 using ehci-pci
[  260.526558] usb 2-1.1: New USB device found, idVendor=0403, idProduct=6015
[  260.526563] usb 2-1.1: New USB device strings: Mfr=1, Product=2, SerialNumber=3
[  260.526567] usb 2-1.1: Product: FT230X Basic UART
[  260.526569] usb 2-1.1: Manufacturer: FTDI
[  260.526571] usb 2-1.1: SerialNumber: DN4934JQ
[  261.545819] usbcore: registered new interface driver usbserial_generic
[  261.545829] usbserial: USB Serial support registered for generic
[  261.552062] usbcore: registered new interface driver ftdi_sio
[  261.552086] usbserial: USB Serial support registered for FTDI USB Serial Device
[  261.552266] ftdi_sio 2-1.1:1.0: FTDI USB Serial Device converter detected
[  261.552341] usb 2-1.1: Detected FT-X
[  261.552891] usb 2-1.1: FTDI USB Serial Device converter now attached to ttyUSB0

The problem is that when I use GTK terminal, putty, or moserial to view the datastream, the data is always jumbled up and has missing fields. For example Helloworld\r\n turns to ellwold\r\n. Inited Can Bus at bitrate 125000 bps turns to Initd aus a birate 500 ps. I have attached the relevant schematic here. I have basically copy-pasted the self-powered USB design from the datasheet for FT230XS.


You might notice that there are no decoupling caps on the VCC pin as shown in the datasheet. Connecting 2x 100nF and 1x 4µF caps on this pin was causing an error where the chip couldn't be read by the Linux kernel.

[ 4135.146806] usb 2-1.1: new full-speed USB device number 45 using ehci-pci
[ 4135.226834] usb 2-1.1: device descriptor read/64, error -32
[ 4136.187078] usb 2-1-port1: Cannot enable. Maybe the USB cable is bad?

Also I have configured the CBUS0 pin for VBUS_SENSE via the FT_PROG utility. Any suggestions or tips would be greatly helpful as this is my first project with any FTDI chip.



I have experimented with different baud rates and tried various combinations of decoupling caps on the vcc to check if this is a power stability of signal integrity issue. I have tried removing the microcontroller out of the picture by doing a hardwired loopback but i dont get any echo. I have replaced the ic to rule out the possibility of a faulty chip.
Logged

FTDI Community

  • Administrator
  • Hero Member
  • *****
  • Posts: 891
    • View Profile
Re: FT230xs USB basic UART converter dropping frames
« Reply #1 on: November 26, 2019, 02:01:54 PM »

Hello,

The schematic generally looks ok.

Is the behaviour the same on a Windows PC?

Please test in a loopback fashion to rule out any issue with the communication to the MCU.

Simply connect TXD to RXD and use a terminal program like PuTTY to send/receive characters.
Note that PuTTY will only show received characters unless your force ON the sent characters.

Please also test with our known good hardware which you can also use for reference:

https://www.ftdichip.com/Products/Modules/DevelopmentModules.htm

Best Regards,
FTDI Community
Logged

asusrog

  • Newbie
  • *
  • Posts: 3
    • View Profile
Re: FT230xs USB basic UART converter dropping frames
« Reply #2 on: November 28, 2019, 09:34:12 AM »

Yeah so i tested the hardwired loopback method again on linux and windows and it works fine without any issues. The MCU uart works fine when connected to an FT232RL module but drops frames with FT230xs. Is there anything peculiar about 230xs that is perhaps causing this issue. Does it require connections to RTS and CTS in order to function properly?
Logged

FTDI Community

  • Administrator
  • Hero Member
  • *****
  • Posts: 891
    • View Profile
Re: FT230xs USB basic UART converter dropping frames
« Reply #3 on: November 29, 2019, 03:32:10 PM »

Hello,

There is nothing in particular with FT230X (vs FT232R) which would cause this issue.
So there must be some issue with your custom PCB.

CTS/RTS flow control signals are used to avoid data loss at high speeds but would probably not avoid data corruption like you are seeing.
Have you wired them up as a test case anyway?

Best Regards,
FTDI Community
Logged

cioma

  • Newbie
  • *
  • Posts: 17
    • View Profile
Re: FT230xs USB basic UART converter dropping frames
« Reply #4 on: December 10, 2019, 03:46:08 PM »

Did you configure FT230X as self-powered device using FT_Prog?
Logged

asusrog

  • Newbie
  • *
  • Posts: 3
    • View Profile
Re: FT230xs USB basic UART converter dropping frames
« Reply #5 on: May 15, 2020, 10:52:56 PM »

sorry for the late reply. I got busy with other projects. Yes, i did configure the device to self-powered. But the issue isnt resolved yet
Logged

FTDI Community

  • Administrator
  • Hero Member
  • *****
  • Posts: 891
    • View Profile
Re: FT230xs USB basic UART converter dropping frames
« Reply #6 on: May 20, 2020, 04:34:31 PM »

Hello,

Please test in a loopback fashion.

Simply connect TXD to RXD and use a terminal program like PuTTY to send/receive characters.

Note that PuTTY will only show received characters unless your force ON the sent characters (in the settings).

Please also test with our known good hardware which you can also use for reference:

https://www.ftdichip.com/Products/Modules/DevelopmentModules.htm

Best Regards,
FTDI Community
Logged