Open satech-domo opened 8 years ago
same problem here
same problem raspberry pi 3
Same error on my Raspberry Pi 2 with Raspbian Jessie.
Unfortunately, same here. RPI3
same here raspberry 2 jessie
For recent kernel, you need to compile from source this specifically fixed driver: https://github.com/skyrocknroll/CH341SER_LINUX. First, update to the last kernel and prepare the env. Then, download, make and insert this CH341SER. It worked well on my RPi3, thanks to @aperepel and @skyrocknroll great works.
1) download pi@raspberrypi:~ $ wget https://github.com/aperepel/raspberrypi-ch340-driver/releases/download/4.4.11-v7/ch34x.ko
2) check pi@raspberrypi:~ $ lsmod Module Size Used by bnep 12051 2 hci_uart 20020 1 btbcm 7916 1 hci_uart bluetooth 365511 22 hci_uart,bnep,btbcm brcmfmac 222874 0 brcmutil 9092 1 brcmfmac cfg80211 543027 1 brcmfmac rfkill 20851 4 bluetooth,cfg80211 snd_bcm2835 24427 1 snd_pcm 98501 1 snd_bcm2835 snd_timer 23968 1 snd_pcm snd 70032 5 snd_timer,snd_bcm2835,snd_pcm bcm2835_gpiomem 3940 0 evdev 12423 6 joydev 9988 0 uio_pdrv_genirq 3923 0 uio 10204 1 uio_pdrv_genirq fixed 3285 0 i2c_dev 6913 0 fuse 99603 3 ipv6 408971 70
3) go towards pi@raspberrypi:~ $ cd /lib/modules/$(uname -r)/kernel/drivers/usb/serial
4) Install first pi@raspberrypi:/lib/modules/4.9.35-v7+/kernel/drivers/usb/serial $ sudo insmod usbserial.ko
5) Check once again pi@raspberrypi:/lib/modules/4.9.35-v7+/kernel/drivers/usb/serial $ lsmod Module Size Used by usbserial 29943 0 <===== Need be installed FIRST bnep 12051 2 hci_uart 20020 1 btbcm 7916 1 hci_uart bluetooth 365511 22 hci_uart,bnep,btbcm brcmfmac 222874 0 brcmutil 9092 1 brcmfmac cfg80211 543027 1 brcmfmac rfkill 20851 4 bluetooth,cfg80211 snd_bcm2835 24427 1 snd_pcm 98501 1 snd_bcm2835 snd_timer 23968 1 snd_pcm snd 70032 5 snd_timer,snd_bcm2835,snd_pcm bcm2835_gpiomem 3940 0 evdev 12423 6 joydev 9988 0 uio_pdrv_genirq 3923 0 uio 10204 1 uio_pdrv_genirq fixed 3285 0 i2c_dev 6913 0 fuse 99603 3 ipv6 408971 68
6) NOW, install ch341.ko pi@raspberrypi:/lib/modules/4.9.35-v7+/kernel/drivers/usb/serial $ sudo insmod ch341.ko
7) Voilá !!! pi@raspberrypi:/lib/modules/4.9.35-v7+/kernel/drivers/usb/serial $ lsmod Module Size Used by ch341 6086 0 <==== Must be here first usbserial 29943 1 ch341 <==== Can you see me now ? bnep 12051 2 hci_uart 20020 1 btbcm 7916 1 hci_uart bluetooth 365511 22 hci_uart,bnep,btbcm brcmfmac 222874 0 brcmutil 9092 1 brcmfmac cfg80211 543027 1 brcmfmac rfkill 20851 4 bluetooth,cfg80211 snd_bcm2835 24427 1 snd_pcm 98501 1 snd_bcm2835 snd_timer 23968 1 snd_pcm snd 70032 5 snd_timer,snd_bcm2835,snd_pcm bcm2835_gpiomem 3940 0 evdev 12423 6 joydev 9988 0 uio_pdrv_genirq 3923 0 uio 10204 1 uio_pdrv_genirq fixed 3285 0 i2c_dev 6913 0 fuse 99603 3 ipv6 408971 68
Greetings Alexandre Toledo alex_cefet_rj@yahoo.com.br
And everytime you need, you will have to recharge them, like that:
pi@raspberrypi:~ $ cd /lib/modules/$(uname -r)/kernel/drivers/usb/serial pi@raspberrypi:/lib/modules/4.9.35-v7+/kernel/drivers/usb/serial $ sudo insmod usbserial.ko pi@raspberrypi:/lib/modules/4.9.35-v7+/kernel/drivers/usb/serial $ sudo insmod ch341.ko pi@raspberrypi:/lib/modules/4.9.35-v7+/kernel/drivers/usb/serial $ lsmod
First of all thank you very much for this manual how to get it running. I´ve done it step by step and the last lsmod shows me that everything should be fine. The problem is, that the Arduino IDE (2.1.0.5) doesnt show me a serial port. I have connected an Arduino Uno with CH34x to my Rasp3B. The weird thing: only one time it was working, but I tried different times after that and it never showed a serial port again. I also checked with lsmod before every time, but shows the two lines correctly. So do you have any suggestion or is there maybe a common mistake i made? Thanks in advance!
How do you get it to show up in lsusb? it is showing up now under usbserial.
Sry, didn't get you point. I am not an english native speaker. Think I mentioned the way I tried to get it running. See my comments to the picture.
Unfortunately I am on a headless raspberry pi lite “Sketch”. I decided to plug in the UNO I have and it’s recgonized no problem
I have compiled the driver for the latest rpi kernel version.
wget https://dl.dropboxusercontent.com/s/nkglyp57i2vl7ao/ch34x.ko
sudo insmod ch34x.ko
Thanks a lot, man!
Enviado do Yahoo Mail no Android
I have compiled the driver for the latest rpi kernel version. wget https://dl.dropboxusercontent.com/s/nkglyp57i2vl7ao/ch34x.ko sudo insmod ch34x.ko
— You are receiving this because you commented. Reply to this email directly, view it on GitHub, or mute the thread.
1. download pi@raspberrypi:~ $ wget https://github.com/aperepel/raspberrypi-ch340-driver/releases/download/4.4.11-v7/ch34x.ko 2. check pi@raspberrypi:~ $ lsmod Module Size Used by bnep 12051 2 hci_uart 20020 1 btbcm 7916 1 hci_uart bluetooth 365511 22 hci_uart,bnep,btbcm brcmfmac 222874 0 brcmutil 9092 1 brcmfmac cfg80211 543027 1 brcmfmac rfkill 20851 4 bluetooth,cfg80211 snd_bcm2835 24427 1 snd_pcm 98501 1 snd_bcm2835 snd_timer 23968 1 snd_pcm snd 70032 5 snd_timer,snd_bcm2835,snd_pcm bcm2835_gpiomem 3940 0 evdev 12423 6 joydev 9988 0 uio_pdrv_genirq 3923 0 uio 10204 1 uio_pdrv_genirq fixed 3285 0 i2c_dev 6913 0 fuse 99603 3 ipv6 408971 70 3. go towards pi@raspberrypi:~ $ cd /lib/modules/$(uname -r)/kernel/drivers/usb/serial 4. Install first pi@raspberrypi:/lib/modules/4.9.35-v7+/kernel/drivers/usb/serial $ sudo insmod usbserial.ko 5. Check once again pi@raspberrypi:/lib/modules/4.9.35-v7+/kernel/drivers/usb/serial $ lsmod Module Size Used by usbserial 29943 0 <===== Need be installed FIRST bnep 12051 2 hci_uart 20020 1 btbcm 7916 1 hci_uart bluetooth 365511 22 hci_uart,bnep,btbcm brcmfmac 222874 0 brcmutil 9092 1 brcmfmac cfg80211 543027 1 brcmfmac rfkill 20851 4 bluetooth,cfg80211 snd_bcm2835 24427 1 snd_pcm 98501 1 snd_bcm2835 snd_timer 23968 1 snd_pcm snd 70032 5 snd_timer,snd_bcm2835,snd_pcm bcm2835_gpiomem 3940 0 evdev 12423 6 joydev 9988 0 uio_pdrv_genirq 3923 0 uio 10204 1 uio_pdrv_genirq fixed 3285 0 i2c_dev 6913 0 fuse 99603 3 ipv6 408971 68 6. NOW, install ch341.ko pi@raspberrypi:/lib/modules/4.9.35-v7+/kernel/drivers/usb/serial $ sudo insmod ch341.ko 7. Voilá !!! pi@raspberrypi:/lib/modules/4.9.35-v7+/kernel/drivers/usb/serial $ lsmod Module Size Used by ch341 6086 0 <==== Must be here first usbserial 29943 1 ch341 <==== Can you see me now ? bnep 12051 2 hci_uart 20020 1 btbcm 7916 1 hci_uart bluetooth 365511 22 hci_uart,bnep,btbcm brcmfmac 222874 0 brcmutil 9092 1 brcmfmac cfg80211 543027 1 brcmfmac rfkill 20851 4 bluetooth,cfg80211 snd_bcm2835 24427 1 snd_pcm 98501 1 snd_bcm2835 snd_timer 23968 1 snd_pcm snd 70032 5 snd_timer,snd_bcm2835,snd_pcm bcm2835_gpiomem 3940 0 evdev 12423 6 joydev 9988 0 uio_pdrv_genirq 3923 0 uio 10204 1 uio_pdrv_genirq fixed 3285 0 i2c_dev 6913 0 fuse 99603 3 ipv6 408971 68
Greetings Alexandre Toledo alex_cefet_rj@yahoo.com.br
full of thanks sir,,, step by step as u describe was really help me... i just followed exactly as it is, now i could say "viola" also,,, thanks again,,,
Or use the mainline driver
Thanks so much, this thread got me sorted connecting my nodeMCU board to Rasberry pi, never been so happy to see a simple LED flashing
That's nice, friend! The intention was help with a quite approach, ease and objective. CheersAlex
Enviado do Yahoo Mail no Android
download pi@raspberrypi:~ $ wget https://github.com/aperepel/raspberrypi-ch340-driver/releases/download/4.4.11-v7/ch34x.ko
check pi@raspberrypi:~ $ lsmod Module Size Used by bnep 12051 2 hci_uart 20020 1 btbcm 7916 1 hci_uart bluetooth 365511 22 hci_uart,bnep,btbcm brcmfmac 222874 0 brcmutil 9092 1 brcmfmac cfg80211 543027 1 brcmfmac rfkill 20851 4 bluetooth,cfg80211 snd_bcm2835 24427 1 snd_pcm 98501 1 snd_bcm2835 snd_timer 23968 1 snd_pcm snd 70032 5 snd_timer,snd_bcm2835,snd_pcm bcm2835_gpiomem 3940 0 evdev 12423 6 joydev 9988 0 uio_pdrv_genirq 3923 0 uio 10204 1 uio_pdrv_genirq fixed 3285 0 i2c_dev 6913 0 fuse 99603 3 ipv6 408971 70
go towards pi@raspberrypi:~ $ cd /lib/modules/$(uname -r)/kernel/drivers/usb/serial
Install first pi@raspberrypi:/lib/modules/4.9.35-v7+/kernel/drivers/usb/serial $ sudo insmod usbserial.ko
Check once again pi@raspberrypi:/lib/modules/4.9.35-v7+/kernel/drivers/usb/serial $ lsmod Module Size Used by usbserial 29943 0 <===== Need be installed FIRST bnep 12051 2 hci_uart 20020 1 btbcm 7916 1 hci_uart bluetooth 365511 22 hci_uart,bnep,btbcm brcmfmac 222874 0 brcmutil 9092 1 brcmfmac cfg80211 543027 1 brcmfmac rfkill 20851 4 bluetooth,cfg80211 snd_bcm2835 24427 1 snd_pcm 98501 1 snd_bcm2835 snd_timer 23968 1 snd_pcm snd 70032 5 snd_timer,snd_bcm2835,snd_pcm bcm2835_gpiomem 3940 0 evdev 12423 6 joydev 9988 0 uio_pdrv_genirq 3923 0 uio 10204 1 uio_pdrv_genirq fixed 3285 0 i2c_dev 6913 0 fuse 99603 3 ipv6 408971 68
NOW, install ch341.ko pi@raspberrypi:/lib/modules/4.9.35-v7+/kernel/drivers/usb/serial $ sudo insmod ch341.ko
Voilá !!! pi@raspberrypi:/lib/modules/4.9.35-v7+/kernel/drivers/usb/serial $ lsmod Module Size Used by ch341 6086 0 <==== Must be here first usbserial 29943 1 ch341 <==== Can you see me now ? bnep 12051 2 hci_uart 20020 1 btbcm 7916 1 hci_uart bluetooth 365511 22 hci_uart,bnep,btbcm brcmfmac 222874 0 brcmutil 9092 1 brcmfmac cfg80211 543027 1 brcmfmac rfkill 20851 4 bluetooth,cfg80211 snd_bcm2835 24427 1 snd_pcm 98501 1 snd_bcm2835 snd_timer 23968 1 snd_pcm snd 70032 5 snd_timer,snd_bcm2835,snd_pcm bcm2835_gpiomem 3940 0 evdev 12423 6 joydev 9988 0 uio_pdrv_genirq 3923 0 uio 10204 1 uio_pdrv_genirq fixed 3285 0 i2c_dev 6913 0 fuse 99603 3 ipv6 408971 68
Greetings Alexandre Toledo alex_cefet_rj@yahoo.com.br
full of thanks sir,,, step by step as u describe was really help me... i just followed exactly as it is, now i could say "viola" also,,, thanks again,,,
— You are receiving this because you commented. Reply to this email directly, view it on GitHub, or mute the thread.
That's nice, friend! The intention was help with a quite approach, ease and objective. CheersAlex Enviado do Yahoo Mail no Android
download pi@raspberrypi:~ $ wget https://github.com/aperepel/raspberrypi-ch340-driver/releases/download/4.4.11-v7/ch34x.ko
check pi@raspberrypi:~ $ lsmod Module Size Used by bnep 12051 2 hci_uart 20020 1 btbcm 7916 1 hci_uart bluetooth 365511 22 hci_uart,bnep,btbcm brcmfmac 222874 0 brcmutil 9092 1 brcmfmac cfg80211 543027 1 brcmfmac rfkill 20851 4 bluetooth,cfg80211 snd_bcm2835 24427 1 snd_pcm 98501 1 snd_bcm2835 snd_timer 23968 1 snd_pcm snd 70032 5 snd_timer,snd_bcm2835,snd_pcm bcm2835_gpiomem 3940 0 evdev 12423 6 joydev 9988 0 uio_pdrv_genirq 3923 0 uio 10204 1 uio_pdrv_genirq fixed 3285 0 i2c_dev 6913 0 fuse 99603 3 ipv6 408971 70
go towards pi@raspberrypi:~ $ cd /lib/modules/$(uname -r)/kernel/drivers/usb/serial
Install first pi@raspberrypi:/lib/modules/4.9.35-v7+/kernel/drivers/usb/serial $ sudo insmod usbserial.ko
Check once again pi@raspberrypi:/lib/modules/4.9.35-v7+/kernel/drivers/usb/serial $ lsmod Module Size Used by usbserial 29943 0 <===== Need be installed FIRST bnep 12051 2 hci_uart 20020 1 btbcm 7916 1 hci_uart bluetooth 365511 22 hci_uart,bnep,btbcm brcmfmac 222874 0 brcmutil 9092 1 brcmfmac cfg80211 543027 1 brcmfmac rfkill 20851 4 bluetooth,cfg80211 snd_bcm2835 24427 1 snd_pcm 98501 1 snd_bcm2835 snd_timer 23968 1 snd_pcm snd 70032 5 snd_timer,snd_bcm2835,snd_pcm bcm2835_gpiomem 3940 0 evdev 12423 6 joydev 9988 0 uio_pdrv_genirq 3923 0 uio 10204 1 uio_pdrv_genirq fixed 3285 0 i2c_dev 6913 0 fuse 99603 3 ipv6 408971 68
NOW, install ch341.ko pi@raspberrypi:/lib/modules/4.9.35-v7+/kernel/drivers/usb/serial $ sudo insmod ch341.ko
Voilá !!! pi@raspberrypi:/lib/modules/4.9.35-v7+/kernel/drivers/usb/serial $ lsmod Module Size Used by ch341 6086 0 <==== Must be here first usbserial 29943 1 ch341 <==== Can you see me now ? bnep 12051 2 hci_uart 20020 1 btbcm 7916 1 hci_uart bluetooth 365511 22 hci_uart,bnep,btbcm brcmfmac 222874 0 brcmutil 9092 1 brcmfmac cfg80211 543027 1 brcmfmac rfkill 20851 4 bluetooth,cfg80211 snd_bcm2835 24427 1 snd_pcm 98501 1 snd_bcm2835 snd_timer 23968 1 snd_pcm snd 70032 5 snd_timer,snd_bcm2835,snd_pcm bcm2835_gpiomem 3940 0 evdev 12423 6 joydev 9988 0 uio_pdrv_genirq 3923 0 uio 10204 1 uio_pdrv_genirq fixed 3285 0 i2c_dev 6913 0 fuse 99603 3 ipv6 408971 68
Greetings Alexandre Toledo alex_cefet_rj@yahoo.com.br
full of thanks sir,,, step by step as u describe was really help me... i just followed exactly as it is, now i could say "viola" also,,, thanks again,,,
— You are receiving this because you commented. Reply to this email directly, view it on GitHub, or mute the thread.
First of all thank you very much for this manual how to get it running. I´ve done it step by step and the last lsmod shows me that everything should be fine. The problem is, that the Arduino IDE (2.1.0.5) doesnt show me a serial port. I have connected an Arduino Uno with CH34x to my Rasp3B. The weird thing: only one time it was working, but I tried different times after that and it never showed a serial port again. I also checked with lsmod before every time, but shows the two lines correctly. So do you have any suggestion or is there maybe a common mistake i made? Thanks in advance!
Hi!
Try starting your Arduino pre-connect to your RPi BEFORE powering both.
root@raspberrypi:/home/pi/Downloads/CH340_LINUX# cd CH341SER_LINUX/
root@raspberrypi:/home/pi/Downloads/CH340_LINUX/CH341SER_LINUX# make
make -C /lib/modules/5.4.51-v8+/build M=/home/pi/Downloads/CH340_LINUX/CH341SER_LINUX
make[1]: Entering directory '/root/linux-f2f7e4b23d8788e96f81a7522b2f703e51c53e70'
CC [M] /home/pi/Downloads/CH340_LINUX/CH341SER_LINUX/ch34x.o
/home/pi/Downloads/CH340_LINUX/CH341SER_LINUX/ch34x.c: In function ‘ch34x_close’:
/home/pi/Downloads/CH340_LINUX/CH341SER_LINUX/ch34x.c:562:2: error: unknown type name ‘wait_queue_t’; did you mean ‘wait_event’?
wait_queue_t wait;
^~~~
wait_event
/home/pi/Downloads/CH340_LINUX/CH341SER_LINUX/ch34x.c:573:24: error: passing argument 1 of ‘init_waitqueue_entry’ from incompatible pointer type [-Werror=incompatible-pointer-types]
init_waitqueue_entry( &wait, current );
^~~~~
In file included from ./include/linux/mmzone.h:10,
from ./include/linux/gfp.h:6,
from ./include/linux/slab.h:15,
from /home/pi/Downloads/CH340_LINUX/CH341SER_LINUX/ch34x.c:21:
./include/linux/wait.h:79:66: note: expected ‘struct wait_queue_entry ’ but argument is of type ‘int ’
static inline void init_waitqueue_entry(struct wait_queue_entry wq_entry, struct task_struct p)
/home/pi/Downloads/CH340_LINUX/CH341SER_LINUX/ch34x.c:574:36: error: passing argument 2 of ‘add_wait_queue’ from incompatible pointer type [-Werror=incompatible-pointer-types]
add_wait_queue( &tty->write_wait, &wait );
^~~~~
In file included from ./include/linux/mmzone.h:10,
from ./include/linux/gfp.h:6,
from ./include/linux/slab.h:15,
from /home/pi/Downloads/CH340_LINUX/CH341SER_LINUX/ch34x.c:21:
./include/linux/wait.h:163:86: note: expected ‘struct wait_queue_entry *’ but argument is of type ‘int *’
wait_queue(struct wait_queue_head *wq_head, struct wait_queue_entry *wq_entry);
~~~~~~~~~~~~~~~~~~~~~~~~~^~~~~~~~
/home/pi/Downloads/CH340_LINUX/CH341SER_LINUX/ch34x.c:578:5: error: implicit declaration of function ‘signal_pending’; did you mean ‘timer_pending’? [-Werror=implicit-function-declaration]
signal_pending(current) || port->serial->disconnected )
^~~~~~~~~~~~~~
timer_pending
/home/pi/Downloads/CH340_LINUX/CH341SER_LINUX/ch34x.c:585:39: error: passing argument 2 of ‘remove_wait_queue’ from incompatible pointer type [-Werror=incompatible-pointer-types]
remove_wait_queue( &tty->write_wait, &wait );
^~~~~
In file included from ./include/linux/mmzone.h:10,
from ./include/linux/gfp.h:6,
from ./include/linux/slab.h:15,
from /home/pi/Downloads/CH340_LINUX/CH341SER_LINUX/ch34x.c:21:
./include/linux/wait.h:165:89: note: expected ‘struct wait_queue_entry *’ but argument is of type ‘int *’
wait_queue(struct wait_queue_head *wq_head, struct wait_queue_entry *wq_entry);
~~~~~~~~~~~~~~~~~~~~~~~~~^~~~~~~~
/home/pi/Downloads/CH340_LINUX/CH341SER_LINUX/ch34x.c: In function ‘wait_modem_info’:
/home/pi/Downloads/CH340_LINUX/CH341SER_LINUX/ch34x.c:756:3: error: implicit declaration of function ‘interruptible_sleep_on’; did you mean ‘interrupts_enabled’? [-Werror=implicit-function-declaration]
interruptible_sleep_on( &priv->delta_msr_wait );
^~~~~~~~~~~~~~~~~~~~~~
interrupts_enabled
cc1: some warnings being treated as errors
make[2]: *** [scripts/Makefile.build:266: /home/pi/Downloads/CH340_LINUX/CH341SER_LINUX/ch34x.o] Error 1
make[1]: *** [Makefile:1709: /home/pi/Downloads/CH340_LINUX/CH341SER_LINUX] Error 2
make[1]: Leaving directory '/root/linux-f2f7e4b23d8788e96f81a7522b2f703e51c53e70'
make: *** [Makefile:5: default] Error 2
root@raspberrypi:/home/pi/Downloads/CH340_LINUX/CH341SER_LINUX# uname -a
Linux raspberrypi 5.4.51-v8+ #1333 SMP PREEMPT Mon Aug 10 16:58:35 BST 2020 aarch64 GNU/Linux
root@raspberrypi:/home/pi/Downloads/CH340_LINUX/CH341SER_LINUX# gcc --version
gcc (Debian 8.3.0-6) 8.3.0
Copyright (C) 2018 Free Software Foundation, Inc.
This is free software; see the source for copying conditions. There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
I have this same issue with a new Pi 5 on a clean install. I am trying to use a recently bought ch384 hub board.
Raspberry pi3 with NOOBS Debian installed 2016 oct 19 did a reboot, show "ch341 4932 0 at lsmod, show "ch341.ko" at ls /lib/modules/$(uname -r)/kernel/drivers/usb/serial nothing at sudo depmod -a
previously installed libusb-1.0.0-dev, mochad-0.1.15, usbutils but got at command $ Isusb bash: Isusb: command not found
Salutations
here the terminal output for ch34x
_> pi@raspberrypi:~ $ sudo insmod ch34x.ko
_