I have bought this external usb wifi antenna for my raspberry pi 3B+ that I would like to use instead the default one.

I see it is based on the realtek chipset as shown in dmesg

158816.385007] usb 1-1.1.3: new high-speed USB device number 7 using dwc_otg
[158816.515745] usb 1-1.1.3: New USB device found, idVendor=0bda, idProduct=0811
[158816.515762] usb 1-1.1.3: New USB device strings: Mfr=1, Product=2, SerialNumber=3
[158816.515772] usb 1-1.1.3: Product: 802.11ac WLAN Adapter 
[158816.515780] usb 1-1.1.3: Manufacturer: Realtek 
[158816.515790] usb 1-1.1.3: SerialNumber: 00e04c000001

I have followed the instruction of these forum posts ( post1 and post2) to install the module for my adapter, but when I am trying to insert the module I get an error in the pi saying that the module cannot be inserted

Are those instruction still valid for my rapbian kernel 4.14.79-v7+ or ? Or it should be easy just to update the raspian in the pi with sudo rpi-update and sudo install-wifi -u rpi-update?

Thanks in advance,



After using the script given by @jake I got this

pi@gf4:~ $ sudo git clone https://github.com/aircrack-ng/rtl8812au -b v5.2.20
Cloning into 'rtl8812au'...
remote: Enumerating objects: 6289, done.
remote: Total 6289 (delta 0), reused 0 (delta 0), pack-reused 6289
Receiving objects: 100% (6289/6289), 19.77 MiB | 3.31 MiB/s, done.
Resolving deltas: 100% (4307/4307), done.
pi@gf4:~ $ cd rtl*
pi@gf4:~/rtl8812au $ sudo sed -i 's/CONFIG_PLATFORM_I386_PC = y/CONFIG_PLATFORM_I386_PC = n/g' Makefile
pi@gf4:~/rtl8812au $ sudo sed -i 's/CONFIG_PLATFORM_ARM64_RPI = n/CONFIG_PLATFORM_ARM64_RPI = y/g' Makefile
pi@gf4:~/rtl8812au $ make
make ARCH=arm64 CROSS_COMPILE= -C /lib/modules/4.14.94-v7+/build M=/home/pi/rtl8812au  modules
make[1]: *** /lib/modules/4.14.94-v7+/build: Permission denied.  Stop.
Makefile:1550: recipe for target 'modules' failed
make: *** [modules] Error 2
pi@gf4:~/rtl8812au $ sudo make
make ARCH=arm64 CROSS_COMPILE= -C /lib/modules/4.14.94-v7+/build M=/home/pi/rtl8812au  modules
make[1]: Entering directory '/root/linux-049e03d71027297051bc19499082194ce64cdc91'
  CC [M]  /home/pi/rtl8812au/core/rtw_cmd.o
gcc: error: unrecognized command line option ‘-mgeneral-regs-only’
scripts/Makefile.build:326: recipe for target '/home/pi/rtl8812au/core/rtw_cmd.o' failed
make[2]: *** [/home/pi/rtl8812au/core/rtw_cmd.o] Error 1
Makefile:1535: recipe for target '_module_/home/pi/rtl8812au' failed
make[1]: *** [_module_/home/pi/rtl8812au] Error 2
make[1]: Leaving directory '/root/linux-049e03d71027297051bc19499082194ce64cdc91'
Makefile:1550: recipe for target 'modules' failed
make: *** [modules] Error 2
  • 1
    look at the accepted answer in those posts, not the repeated answer that seems to have zero upvotes - i.e. the answer you seem to have used because that's the only place that has this sudo install-wifi -c rpi-update rubbish – Jaromanda X Jan 30 at 9:15
  • I use github.com/aircrack-ng/rtl8812au.git with the actual kernel. Did any errors occur while installing (building) the drivers? – jake Jan 30 at 9:15
  • What is ? No such thing - the latest supported kernel is 4.14.79-v7+ – Milliways Jan 30 at 11:05
  • Don't use rpi-update except you really know what you are doing. It will install untested developer versions and may make your system unstable. – Ingo Jan 31 at 1:04

This worked fine for my, so u suggest doing this step by step and then tell us, where it went wrong:

sudo apt-get install build-essential raspberrypi-kernel-headers bc

sudo wget "https://raw.githubusercontent.com/notro/rpi-source/master/rpi-source" -O /usr/bin/rpi-source
sudo chmod 755 /usr/bin/rpi-source
sudo rpi-source 

git clone https://github.com/aircrack-ng/rtl8812au -b v5.2.20
cd rtl*
sed -i 's/CONFIG_PLATFORM_I386_PC = y/CONFIG_PLATFORM_I386_PC = n/g' Makefile
sudo cp 8812au.ko /lib/modules/`uname -r`/kernel/drivers/net/wireless
sudo depmod -a
sudo modprobe 88XXau

Source: https://github.com/aircrack-ng/rtl8812au.

  • I tried as you said and I got an error while invoking make, see edited post thanks! – ndarkness Feb 1 at 16:30

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.