Unable to Communicate with ttyACM devices in CentOS8
CentOSThis forum is for the discussion of CentOS Linux. Note: This forum does not have any official participation.
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
Unable to Communicate with ttyACM devices in CentOS8
We are trying to establish communication between a ttyACMx UART device & a PC which runs CentOS8.
We are using gtkterm to send data to the UART device.
The version of gtkterm is :
[root@localhost arunodaya.s]# gtkterm --help
GTKTerm version 1.0
(c) Julien Schmitt
Kernal version is :
[root@localhost arunodaya.s]# uname -a
Linux localhost.localdomain 4.18.0-147.8.1.el8_1.x86_64 #1 SMP Thu Apr 9 13:49:54 UTC 2020 x86_64 x86_64 x86_64 GNU/Linux
If we connect a loop back device (ttyUSBx), we are able to communicate using gtkterm.
We tried in a machine with fedora 31 & found the same problem.
The same device (UART) is communicating fine in an ubuntu 18 (LTS version).
Distribution: debian, lfs, whatever else i need in qemu
Posts: 268
Rep:
Just to verify, did you also try other ways to communicate, like, other software like minicom, screen? did you also compare the relevant strace output for both working(ubuntu) and not working systems?
We tried with minicom, we had the same issue. We compared the strace output, the difference is this extra line which has timeout for all file descriptors. We are not sure whether this will lead to this behavior.
The root cause of the issue is with auto initialization of Modem(ttyACM) and the way it is handled. We added a sniffer in between the OS and the device & found that, before we send any data, the OS itself sends "AT" command for modem initialization. This was rendering the ttyACM device to go into undefined mode. The device in question is not a modem but is enumerating as one (Virtual COM Port).
We have disabled the ModemManager service and now as it looks like it is working normally. Need to find a more graceful way of handling this.
Distribution: debian, lfs, whatever else i need in qemu
Posts: 268
Rep:
That's very informative, thanks.
Maybe there's a way to disable handling of modems in there by default instead of shutting the whole thing down. There must be.
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.