USB-Serial Port adapter (RS-232) in Ubuntu Linux

USB DriverThere are two other articles on a serial port adapter for Windows or Linux usb serial. Below is the instructions for Linux and how to connect your serial adapter while using Linux. This should work for most people using Linux and a serial adapter or usb to rs232 driver which is being discussed.

USB-Serial Port adapter (RS-232) in Ubuntu LinuxUSB to RS 232 driver Linux

1.  Log into Linux under the root account;

2.  Plug the USB-Serial adapter into the computer;

3. Give it a minute to discover the USB-Serial adpater;

4. Type in this command dmesg

5. The dmesg command will echo back the most recent few lines of the system message console, and you should see something like this:

  • usb 2.0: new full speed USB device using uhci and address 2
  • See also usb 2.0: configuration #1 chosen from 1 choice

6. Unplug the USB-Serial adapter to see a list of USB devices without it being plugged in.

 

Installing the USB-Serial Port adapter (RS-232)

 

7. Type this command to list the USB devices: lsusb

8. In addition you should see a list of USB devices that looks like this:

  • Bus 001 Device 001: ID 0000:0000
  • Bus 002 Device 007: ID 03f0:4f11 Hewlett-Packard
  • See also – Bus 002 Device 006: ID 05e3:1205 Genesys Logic, Inc. Afilias Optical Mouse H3003
  • Bus 002 Device 004: ID 15d9:0a33  Logitec-mouse

9. Then plug the USB into our device Then use the lsusb command again and observe the changes

  • Bus 001 Device 001: ID 0000:0000
  • Bus 002 Device 007: ID 03f0:4f11 Hewlett-Packard
  • See also – Bus 002 Device 003: ID 018a:3754 Unknown device
  • Bus 002 Device 006: ID 05e3:1205 Genesys Logic, Inc. Afilias Optical Mouse H3003
  • Bus 002 Device 004: ID 15d9:0a33  Logitec-mouse
See also  Panasonic PV-DV121 USB Driver

 

Vendor ID Check

10. Likewise to determine the vendor ID and the product ID by inspecting this additional line. In this example they are 018a and 3754. For a Trip•Lite USB-Serial adapter, they are 2303 and 067B. In this example it is a Minicom USB-Serial device. The first numbers identifies the vendor and the second numbers identifies the product.

11. Now use the following command to load the kernel module called usb serial and pass the vendor and product ID values to it. Likewise the driver can then associate itself with the correct hardware device on the USB bus.

  • sudo modprobe usbserial vendor=018a product=3754

12. Likewise now check whether the new Serial Port device is available

  • sudo dmesg | grep ttyUSB

13. In addition you should now see something  like this

  • usbserial_generic 1-1:1.0: generic converter detected
  • usb 1-1: generic converter now attached to ttyUSB0
  • usbcore: registered new interface driver usbserial_generic

14. Likewise this tells you that the serial device has now been mapped to the /dev/ttyUSBO serial port

15. Now we want to list the devices under the /dev/ path to see if the interface is visible with this command:

  • ls /dev/

 

Loading the module

18. Likewise instruct Ubuntu to load this module automatically by including the following line in the /etc/modules file. Substitute your own vendor and product ID if they are different.

  • usbserial vendor=018a product=3754

That should be about it however if you have not installed the driver then you would have to install it now. If you are installing a Minicom serial device then you would do the following:

  • sudo  apt-get install minicom
  • sudo minicom -s
See also  Aten USB to Serial Driver (UC232A / UC232A1) Install

Press A and then edit to / dev / ttyUSB 0  ( this value, see dmesg | grep ttyUSB )

Press E  and then edit to 9600 8N1

Press F and the value will change from Yes   to   No

Once set up and finish off mode serial port setup.

Likewise save setup as df1 finished off. Settings by Exit from Minicom

 

Other Issues:

This is for Ubuntu Linux for Red Hat the drivers should be in your OS however Triplite does have Red Hat drivers on their website if you do not have them on your system.

Likewise if you are trying to connect a Zigbee through this serial port you can do the following:

Additionally make a symbolic link between ttyUSB0 and com2 by typing in terminal: (assuming you are using com2)

  • ln -s /dev/ttyUSB0 /home/your_home/.wine/dosdevices/com2

Then Add com2 port to X-CTU