Building RTL8821CU module


linoma
 Share

1 1

Recommended Posts

Armbian is a community driven open source project. Do you like to contribute your code?

2 minutes ago, linoma said:

I need the kernel sources.

 

If you are using officially supported armbian, all you need to do is:

armbian-config -> software:
 

image.png
 

If you don't have official Armbian, you will need to do some research ...

 

Best way - adding https://github.com/brektrou/rtl8821CU here https://github.com/armbian/build/blob/master/lib/compilation-prepare.sh#L126-L249

Link to post
Share on other sites

I have same problems during the installation with armbian-config. Anyway I have downloaded the kernel source, Renegade option in compile.sh, and Im using insmod and the 8821cu.ko is loaded. But the kernel freeze with nulla pointer in rtw_os_ndev_register. May Be there Is a bug in halmac routines. Iam already using the driver on x86 Ubuntu 1604 and It works well. Im using old version 4.4.154 on rk3228

Link to post
Share on other sites

22 hours ago, linoma said:

I have same problems during the installation with armbian-config. Anyway I have downloaded the kernel source, Renegade option in compile.sh, and Im using insmod and the 8821cu.ko is loaded. But the kernel freeze with nulla pointer in rtw_os_ndev_register. May Be there Is a bug in halmac routines.


Build image and try:
https://github.com/armbian/build/pull/1690

I don't have this hardware but it doesn't crash on loading:
 

[  119.107213] RTW: module init start
[  119.107222] RTW: rtl8821cu v5.4.1_28754.20180921_COEX20180712-3232
[  119.107225] RTW: build time: Dec 23 2019 21:19:20
[  119.107228] RTW: rtl8821cu BT-Coex version = COEX20180712-3232
[  119.107378] usbcore: registered new interface driver rtl8821cu
[  119.107382] RTW: module init ret=0

Running on Olimex Lime A64 http://ix.io/25kb

Link to post
Share on other sites

I started using armbian yesterday, I am really having fun. So I share my driver experience for rtl8821CU...

 

To get my CUDY  WU650   to work, I had to download   rtl8821CU_rtl8731AU_WiFi_linux_v5.8.1.7_37266.20200929_COEX20200616-4141.tar.gz

from the Cudy support page ( www.cudy.com/download ).  I followed their documentation, but got errors: No such file or directory for /lib/modules/5.10.21-meson64/build.

 

So I installed the kernel headers (linux-headers-current-meson64_21.02.3_arm64.deb)  and

dtb ( not sure if that is needed - linux-dtb-current-meson64)   using synaptic.

 

The make script from cudy  tries to use   arch/aarch64/Makefile, but fails:      No rule to make target 'arch/aarch64/Makefile'.  Stop.

 

So I copied   /lib/modules/5.10.21-meson64/build/arch/arm64  to  /lib/modules/5.10.21-meson64/build/arch/aarch64.

 

sudo make

sudo make install

sudo modprobe -r 8821cu

 

then worked  perfectly...

 

pls enjoy...  

   cic_as

Link to post
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
 Share

1 1