•  

    +91-7902224040

  •  

    info@srishtirobotics.com

Blog

CH341SER_LINUX

In Raspbian for Raspberry Pi

Run the following commands in the CLI/Terminal when using Raspbian on a Raspberry Pi. After updating, the latest CH340 should be installed!

sudo apt-get update
sudo apt-get upgrade

Other Linux Distributions

Here is a list of drivers, In that click Driver Download for Linux.

There are some reported cases of serial communication failure when using the factory drivers in Linux. If you encounter this problem, you can try Installing patched drivers. Here are the steps (to run in the command line):

  • Plug and unplug your CH340 device from the USB port
  • Type dmesg to see what has happened
    • The expected output (shows "ch341") should have the following in the recent log:
[  xxx] ch341-uart ttyUSB0: ch341-uart converter now disconnected from ttyUSB0
[  xxx] ch341 3-2:1.0: device disconnected 
  • Download the Patched Driver and unzip
  • cd into the directory where the files are saved
  • make clean
  • make
  • sudo make load
  • sudo rmmod ch341 to uninstall the broken driver
  • lsmod | grep ch34 to list what modules are currently installed
  • Plug and unplug your CH340 device again on the USB port
  • dmesg
    • Expected output (should show "ch34x" now):
[  xxx] ch34x ttyUSB0: ch34x converter now disconnected from ttyUSB0
[  xxx] ch34x 3-2:1.0: device disconnected

Depending on your root permissions, you may need to configure the serial port with the following two commands. Make sure to adjust the $username with respect to the user ID that is currently logged in.

sudo usermod -a -G dialout $username 
sudo chmod a+rw /dev/ttyUSB0

Depending on how the CH340 enumerated on your computer, the /dev/ttyUSB0 may be different. Try using ls command as explained in the Driver Verification if you have issues configuring the serial port settings and adjusting the port as necessary. 

Checking Driver Working for Linux

Please connect the device with the computer and type the following in the terminal 

ls /dev/ttyUSB*

You should see this if the driver is ok

 

 


Can We Help ?

+91-7902224040