USB-serial RS232 adapters on Linux

Author: Peter Apian-Bennewitz, page updated: 8.7.2023
my list of other hardware bits, personal home page

This text is about USB adapters that offer serial connections on Linux, see also Wikipedia USB_adapter. Serial connections are also known as the frequently found RS232 interface or more generally as UARTs.

error "pl2303_get_line_request - failed"

Some USB-serial RS232 adapters fail after some time. The user program gets a timeout while reading from the device and the syslog shows:


Jan 22 20:24:30 luna kernel: [107148.076443] usb 1-2: new full-speed USB device number 7 using uhci_hcd
Jan 22 20:24:30 luna kernel: [107148.254264] usb 1-2: New USB device found, idVendor=067b, idProduct=2303, bcdDevice= 4.00
Jan 22 20:24:30 luna kernel: [107148.254269] usb 1-2: New USB device strings: Mfr=1, Product=2, SerialNumber=0
Jan 22 20:24:30 luna kernel: [107148.254273] usb 1-2: Product: USB-Serial Controller
Jan 22 20:24:30 luna kernel: [107148.254277] usb 1-2: Manufacturer: Prolific Technology Inc.
Jan 22 20:24:30 luna kernel: [107148.269380] usb 1-2: pl2303 converter now attached to ttyUSB0
Jan 22 20:24:30 luna mtp-probe: checking bus 1, device 7: "/sys/devices/pci0000:00/0000:00:1d.0/usb1/1-2"
Jan 22 20:24:30 luna mtp-probe: checking bus 1, device 7: "/sys/devices/pci0000:00/0000:00:1d.0/usb1/1-2"
Jan 22 20:25:37 luna kernel: [107215.122292] pl2303 ttyUSB0: pl2303_get_line_request - failed: -32
Jan 22 20:25:37 luna kernel: [107215.126290] pl2303 ttyUSB0: pl2303_get_line_request - failed: -32
Jan 22 20:25:39 luna kernel: [107217.443295] pl2303 ttyUSB0: error sending break = -32
Jan 22 20:25:42 luna kernel: [107220.678293] pl2303 ttyUSB0: pl2303_get_line_request - failed: -32
Jan 22 20:25:45 luna kernel: [107222.979296] pl2303 ttyUSB0: error sending break = -32
Jan 22 20:34:44 luna kernel: [107761.930496] pl2303 ttyUSB0: pl2303_get_line_request - failed: -32
Jan 22 20:34:46 luna kernel: [107764.248489] pl2303 ttyUSB0: error sending break = -32
Jan 22 20:34:48 luna kernel: [107766.500487] pl2303 ttyUSB0: pl2303_get_line_request - failed: -32
Jan 22 20:34:51 luna kernel: [107768.824489] pl2303 ttyUSB0: error sending break = -32
Jan 22 20:35:59 luna kernel: [107837.478504] usb 1-2: USB disconnect, device number 7
Jan 22 20:35:59 luna kernel: [107837.478752] pl2303 ttyUSB0: pl2303 converter now disconnected from ttyUSB0

Other parameters: Debian 10, Linux kernel 4.19.0-13-686-pae

There are numerous pages on the web with similar problems. However, like so often , many comments are added by folks who mean well, but aren't very knowledgeable about Linux. For example, this problem is not related to access rights on the device file: The user program is able to open the device, it works at first, but fails after a while. The machine is otherwise completely idle, it is not running on a VM emulator, and nothing changed on the USB bus. It is not caused by a faulty or permuted wiring of the RS232 hardware-handshake signals (DTR-DSR, RTS-CTS, DCD).

hardware, firmware and version identification - or the lack of it

By my experience, this is provable a problem with the firmware on some low-end adapters (see table below). However, the main problem is the lack of identification of a specific USB-serial converter: The packaging doesn't show the chip that is used and/or the firmware version in it. In most cases the only way is to buy an adapter and hope for the best.
Even lsusb -v shows only a subtle difference between an adapter that works and one of the same manufacturer that does not. Apparently adapters for the consumer market don't bother about listing the firmware version or a serial number. - Which is essential for debugging and reporting a bug. Hence some adapters have to be regarded as sub-optimal, over-priced hardware crap for consumer kiddies.
On the subject of counterfeit FTDI adapters, see FTDI Wikipedia entry.
There are manufacturers of adapters which do show a serial number or version info (e.g. the FTDI product below).

comparison of adapters

photo purchase date state lsusb lsusb -v kernel driver module activity LED
FTDI USB serial adapter ca 2004 works ID 0403:6001 Future Technology Devices International, Ltd FT232 Serial (UART) IC idVendor 0x0403 Future Technology Devices International, Ltd idProduct 0x6001 FT232 Serial (UART) IC bcdDevice 4.00 iManufacturer 1 FIDI iProduct 2 USB Serial converter iSerial 3 FTBSC3NZ bNumConfigurations 1 pl2303 yes
Prolific USB serial adapter 2019 fails after about 200 reads ID 067b:2303 Prolific Technology, Inc. PL2303 Serial Port idVendor 0x067b Prolific Technology, Inc. idProduct 0x2303 PL2303 Serial Port bcdDevice 4.00 iManufacturer 1 (error) iProduct 2 USB-Serial Controllernc iSerial 0 bNumConfigurations 1 pl2303 no
Prolific USB serial adapter 2021 works ID 067b:2303 Prolific Technology, Inc. PL2303 Serial Port idVendor 0x067b Prolific Technology, Inc. idProduct 0x2303 PL2303 Serial Port bcdDevice 4.00 iManufacturer 1 Prolific Technology Inc. iProduct 2 USB-Serial Controller D iSerial 0 bNumConfigurations 1 pl2303 no

robust RS232 alternatives to pluggable USB adapters

A more robust and sound solution for industrial applications are PCI or PCIe cards with RS232 I/O chip-sets. Even better for professional work are industrial motherboards which still feature the legacy RS232 chip-sets on board: And, as of June 2023, surprisingly, the latter are still available (e.g. by manufacturer "ASrock"), even with the latest Intel CPUs (currently the "Raptor Lake" generation).

copyright

Peter Apian-Bennewitz, info[AT]pab-opto.de, Text written, Images taken by me.
Copyright GNU_Free_Documentation_License.
Reference to this text is appreciated and mandatory, if content is used elsewhere.

Valid HTML 4.01 Transitional


/icos/en-flag.png 
web address of this page: http://www.pab-opto.de?d=/pers/hwtests/usb-serial
Datenschutzerklärung , Impressum
page contents © pab