Hi. I have tried many ways to install drivers for RTL8811 for my RPI3 but none of them was succeed.
I can say I’m a beginner but able to make some changes in terminal and know moreless how to move there, but still getting errors while trying to compile(make) or install kernel headers.
These are the sources that I was trying to use:
https://github.com/brektrou/rtl8821CU/issues/30
https://thepihut.com/blogs/raspberry-pi-tutorials/how-to-setup-a-rtl881cu-usb-wifi-adapter-with-the-raspberry-pi-4
If you could help me I would be very gratefull
You’ll need to install the OSMC kernel headers (rbp2-headers-4.19.122-2-osmc
) and run the ln
command shown in this post: Driver support for Archer T2U Plus (wireless usb adapter)? - #11 by dillthedog.
Unfortunately, DKMS isn’t currently supported in OSMC, so you’ll need to make the module manually. If the build fails, it might be because of an ongoing problem with the headers package. See Has anybody tried to install Wireguard? - #28 by dillthedog for a workaround.
I have tried to do make again, and this is what showing me…
ln returns me that: File exists
I even followed steps from here: https://discourse.osmc.tv/t/usb-wifi-5ghz-rtl8811au-rtl8811cu/87143
and until include/linux copy etc it was fine, but still cant do “make”…
After I changed /include/linux/ from kernel “linux-4.19.162”, realtek ID changed to:
“0bda:b711”
Unfortunately, I don’t know what steps you have followed but I followed the steps mentioned here and it works to the point where you’ll need to apply the headers workaround I mentioned above.
osmc@osmc:~/rtl8821CU-5.8.1$ sudo vi /lib/modules/$(uname -r)/build/arch/arm/Makefile
osmc@osmc:~/rtl8821CU-5.8.1$ sudo ln -s /lib/modules/$(uname -r)/build/arch/arm /lib/modules/$(uname -r)/build/arch/armv7l
osmc@osmc:~/rtl8821CU-5.8.1$ make
make ARCH=armv7l CROSS_COMPILE= -C /lib/modules/4.19.122-2-osmc/build M=/home/osmc/rtl8821CU-5.8.1 modules
make[1]: Entering directory '/usr/src/rbp2-headers-4.19.122-2-osmc'
CC [M] /home/osmc/rtl8821CU-5.8.1/core/rtw_cmd.o
In file included from ./include/linux/compat.h:16,
from ./include/linux/ethtool.h:17,
from ./include/linux/netdevice.h:41,
from /home/osmc/rtl8821CU-5.8.1/include/osdep_service_linux.h:31,
from /home/osmc/rtl8821CU-5.8.1/include/osdep_service.h:53,
from /home/osmc/rtl8821CU-5.8.1/include/drv_types.h:27,
from /home/osmc/rtl8821CU-5.8.1/core/rtw_cmd.c:17:
./include/linux/if.h:28:10: fatal error: sys/socket.h: No such file or directory
#include <sys/socket.h> /* for struct sockaddr. */
^~~~~~~~~~~~~~
compilation terminated.
make[2]: *** [scripts/Makefile.build:304: /home/osmc/rtl8821CU-5.8.1/core/rtw_cmd.o] Error 1
make[1]: *** [Makefile:1522: _module_/home/osmc/rtl8821CU-5.8.1] Error 2
make[1]: Leaving directory '/usr/src/rbp2-headers-4.19.122-2-osmc'
make: *** [Makefile:2327: modules] Error 2
1 Like
Thank you for your help!
I need to take a break for now, because seller send me adapter with chip 8188GU wich doesn’t even support 5GHz that I wanted to have, I need to wait for another one
Maybe you have something to recommend with 5GHz that will work for sure
Hi again. I would like to partially try to solve my problem for the future with installing headers and understand what and why it is causing so many issues to me
If you have any advice or source how to install or point to osmc where the headers are located let me know, for now I’m out of ideas…
I’ve already given you the answer. Which part don’t you get?
I tried to do all the steps to install at least headers, trying to copy new one and switch them with the one from kernel.org…
As a workaround for now, you can remove all dodgy headers in the include/linux directory, then re-copy from the kernel.org 35 source:
sudo rm -r /usr/src/rbp2-headers-4.14.78-4-osmc/include/linux/*
sudo cp -ar ./linux-4.14.78/include/linux/* /usr/src/rbp2-headers-4.14.78-4-osmc/include/linux/
unless you mean that i need to somehow install wireguard?
The post I linked to was from January 2019 when the Pi version of OSMC was on kernel version 4.14.78-4. It’s now on version 4.19.122-2, so you should change commands appropriately.
Yes of course and I did it…I even changed the name rbp2-headers to linux-headers, because I was getting error that rbp2…headers couldn’t be found, but still getting errors
In computing it’s all about details, details and details. I have no way of knowing what you did or didn’t do because your post was lacking such detailed information. Descriptions in the abstract can accompany the details but we need to know exactly what commands you ran and what the output was.
I have four OSMC RPi installs around the house all using the Realtek RTL8811CU USB dongle which failed to be recognised but swapping them all out for another brand was not on - this worked for me here but I had to go through every step including all the failure point instructions and voila!