working with CY7C65215 on linux at 3M baudrate with flow control

Tip / Sign in to post questions, reply, level up, and achieve exciting badges. Know more

cross mob
orin_3228621
Level 1
Level 1
First like given Welcome!

i'm working with CY7C65215 on linux and i'm trying to get it to work with 3M baud rate and flow control enabled.

i'm trying to read from the UART /dev/ttyACM0 to a file using the socat application.

sudo socat -u /dev/ttyACM0,b3000000,crtscts=1,echo=0,raw,ignoreeof CREATE:uart.bin

what I see that I get a lot of missing characters on the data (+lots of garbage).

i'm using Ubuntu 18.04.4 LTS with 5.3.0-42-generic kernel

on windows with the lastest driver there is no issue - all data arrives without any garbage.

on linux it uses the default cdc_acm driver - and i suspect there might be an issue with either the high baud rate or with flow control.

is there any way to debug this ?

0 Likes
1 Solution
YatheeshD_36
Moderator
Moderator
Moderator
750 replies posted 500 replies posted 250 solutions authored

Hello,

Flow control is custom implementation by cypress in cyusb3 driver for windows and the libcyusbserial on top of libusb for Linux.

Native Windows and Linux drivers will not support Flow control on USB-Serial.

Please disable flow control.

Thanks,

Yatheesh

View solution in original post

6 Replies
YatheeshD_36
Moderator
Moderator
Moderator
750 replies posted 500 replies posted 250 solutions authored

Hello,

Flow control is custom implementation by cypress in cyusb3 driver for windows and the libcyusbserial on top of libusb for Linux.

Native Windows and Linux drivers will not support Flow control on USB-Serial.

Please disable flow control.

Thanks,

Yatheesh

Hi Yatheesh.

thank you for the important information.

I will move to use libcyusbserial in linux.

the only problem is the libcyusbserial only works for me if I change the SCB Protocol from CDC to VENDOR using the Windows Cypress USB-Serial configuration Utility.

I have two questions

1. can the libcyusbserial (CyOpen fails) can work in CDC mode on Linux somehow (it does work on Windows with cyusb3)? maybe i need the Kernel not to load the cdc_acm driver somehow?

2. if not - can I program the CY7C65215 on Linux without needing a Windows machine to change the mode from CDC to VENDOR?

Thank you.

Ori Inbar

0 Likes

Hello,

Please see my comments below:

1. Cypress CyAPI.lib in windows and the libcyusbserial in linux works only when the device is configured as a vendor device.

When device is configured in CDC mode, it will not bind to cypress driver, hence the libraries cannot be used.

2. We do not have a USB-Serial configuration utility for Linux.

Thanks,

Yatheesh

Hi Yatheesh.

thank you for the reply.

i just wanted to clarify that on windows - I use the cypress 3.13.0.84 USB driver - and it does support flow control with no issues in CDC mode.

i work on both OSs simultaneously

is there a way to patch the linux cdc_acm to also support flow control? or maybe there is a propriety driver for linux as well that can support flow control over CDC mode?

I did manage to use the VENDOR mode in linux with flow control but the problem is whenever I switch my device from windows to linux I have to re-program to VENDOR using the windows USB-Serial configuration utility.

and when i switch back to windows i have to re-program again to CDC.

thank you

Ori Inbar

0 Likes

Hello Ori Inbar,

I am afraid there is no known way to support flow control in linux apart from using the vendor class. I have tried this as well.

Thanks,

Yatheesh

Thank you for the information.

0 Likes