Hi to All, one desperate soul here. I need to install this driver and I followed the instructions in Aperepel's page. One minute how-to didn't work because I have different kernel. So if I try to do insmod i receive error stating that Invalid module format - that was expected. So I prepared everything for make command (linux headers, updates etc.) but I am still receiving this error about invalid datapointers:
pi@raspberrypi:~/Downloads/CH341SER_LINUX $ make make -C /lib/modules/5.15.61-v7+/build M=/home/pi/Downloads/CH341SER_LINUX make[1]: Entering directory '/home/pi/linux-5b775d7293eb75d6dfc9c5ffcb95c5012cd0c3f8' CC [M] /home/pi/Downloads/CH341SER_LINUX/ch34x.o /home/pi/Downloads/CH341SER_LINUX/ch34x.c: In function ‘ch34x_close’: /home/pi/Downloads/CH341SER_LINUX/ch34x.c:590:7: warning: unused variable ‘timeout’ [-Wunused-variable] 590 | long timeout; | ^~~~~~~ /home/pi/Downloads/CH341SER_LINUX/ch34x.c:589:6: warning: unused variable ‘bps’ [-Wunused-variable] 589 | int bps; | ^~~ /home/pi/Downloads/CH341SER_LINUX/ch34x.c: At top level: /home/pi/Downloads/CH341SER_LINUX/ch34x.c:1297:20: error: initialization of ‘unsigned int (*)(struct tty_struct *)’ from incompatible pointer type ‘ssize_t (*)(struct tty_struct *)’ {aka ‘int (*)(struct tty_struct *)’} [-Werror=incompatible-pointer-types] 1297 | .write_room = ch34x_write_room, | ^~~~~~~~~~~~~~~~ /home/pi/Downloads/CH341SER_LINUX/ch34x.c:1297:20: note: (near initialization for ‘ch34x_device.write_room’) /home/pi/Downloads/CH341SER_LINUX/ch34x.c:1298:21: error: initialization of ‘unsigned int (*)(struct tty_struct *)’ from incompatible pointer type ‘int (*)(struct tty_struct *)’ [-Werror=incompatible-pointer-types] 1298 | .chars_in_buffer = ch34x_chars_in_buffer, | ^~~~~~~~~~~~~~~~~~~~~ /home/pi/Downloads/CH341SER_LINUX/ch34x.c:1298:21: note: (near initialization for ‘ch34x_device.chars_in_buffer’) cc1: some warnings being treated as errors make[2]: *** [scripts/Makefile.build:289: /home/pi/Downloads/CH341SER_LINUX/ch34x.o] Error 1 make[1]: *** [Makefile:1898: /home/pi/Downloads/CH341SER_LINUX] Error 2 make[1]: Leaving directory '/home/pi/linux-5b775d7293eb75d6dfc9c5ffcb95c5012cd0c3f8' make: *** [Makefile:5: default] Error 2
C is way above my programming skills, so I am looking for help everywhere but without any luck. Any help would be highly appreciated...
Hi to All, one desperate soul here. I need to install this driver and I followed the instructions in Aperepel's page. One minute how-to didn't work because I have different kernel. So if I try to do insmod i receive error stating that Invalid module format - that was expected. So I prepared everything for make command (linux headers, updates etc.) but I am still receiving this error about invalid datapointers:
pi@raspberrypi:~/Downloads/CH341SER_LINUX $ make make -C /lib/modules/5.15.61-v7+/build M=/home/pi/Downloads/CH341SER_LINUX make[1]: Entering directory '/home/pi/linux-5b775d7293eb75d6dfc9c5ffcb95c5012cd0c3f8' CC [M] /home/pi/Downloads/CH341SER_LINUX/ch34x.o /home/pi/Downloads/CH341SER_LINUX/ch34x.c: In function ‘ch34x_close’: /home/pi/Downloads/CH341SER_LINUX/ch34x.c:590:7: warning: unused variable ‘timeout’ [-Wunused-variable] 590 | long timeout; | ^~~~~~~ /home/pi/Downloads/CH341SER_LINUX/ch34x.c:589:6: warning: unused variable ‘bps’ [-Wunused-variable] 589 | int bps; | ^~~ /home/pi/Downloads/CH341SER_LINUX/ch34x.c: At top level: /home/pi/Downloads/CH341SER_LINUX/ch34x.c:1297:20: error: initialization of ‘unsigned int (*)(struct tty_struct *)’ from incompatible pointer type ‘ssize_t (*)(struct tty_struct *)’ {aka ‘int (*)(struct tty_struct *)’} [-Werror=incompatible-pointer-types] 1297 | .write_room = ch34x_write_room, | ^~~~~~~~~~~~~~~~ /home/pi/Downloads/CH341SER_LINUX/ch34x.c:1297:20: note: (near initialization for ‘ch34x_device.write_room’) /home/pi/Downloads/CH341SER_LINUX/ch34x.c:1298:21: error: initialization of ‘unsigned int (*)(struct tty_struct *)’ from incompatible pointer type ‘int (*)(struct tty_struct *)’ [-Werror=incompatible-pointer-types] 1298 | .chars_in_buffer = ch34x_chars_in_buffer, | ^~~~~~~~~~~~~~~~~~~~~ /home/pi/Downloads/CH341SER_LINUX/ch34x.c:1298:21: note: (near initialization for ‘ch34x_device.chars_in_buffer’) cc1: some warnings being treated as errors make[2]: *** [scripts/Makefile.build:289: /home/pi/Downloads/CH341SER_LINUX/ch34x.o] Error 1 make[1]: *** [Makefile:1898: /home/pi/Downloads/CH341SER_LINUX] Error 2 make[1]: Leaving directory '/home/pi/linux-5b775d7293eb75d6dfc9c5ffcb95c5012cd0c3f8' make: *** [Makefile:5: default] Error 2
C is way above my programming skills, so I am looking for help everywhere but without any luck. Any help would be highly appreciated...
THanks!!!