Setting up Tp-link Wireless N USB Adapter TL-WN821N

I bought a Tp-link USB wireless adapter to connect my desktop computer with my router , but for Linux it’s not a plug-and-play device , so I started to find solutions.

Tp-link solutions

Tp-link has a good support , they have support lines for major countries of America, Asia and Europe.

They have a driver too in their website. But this driver must be compiled in order to work. I will summarize the steps though it didn’t work for me.


  • Find out what is your hardware version . Look at your USB device , in the reverse you’ll find your hardware version , you’ll need it to download the right driver
  • Go to TP-link website and download your driver according to the hardware version (it could be v3 , v4 or v5). You’ll be redirected to the regional Tp-link website for you.
  • There is a Linux driver , download it and unzip it. My USB version is 5 , this is the download link for this driver . Below you can check the driver specifications.
  • Download v5.
  • You’ll need to compile the driver running make , and changing the makefile . It’s not easy. You can download its manual and try.
Installation for Linux driver RTL.pdf

Setting up Tp-link driver – the easy way

I found a third party repository with the driver , and it’s compatible with Ubuntu 16.04 (Ubuntu Xenial).

We only need to add the new repository and install using apt. First ,if you don’t have the following package install it , it is required to acomplish the following step.

sudo apt-get install software-properties-common

Then we need to add the third party repo , update and install the new driver.

sudo add-apt-repository ppa:hanipouspilot/rtlwifi 
sudo apt-get update 
sudo apt-get install rtl8192eu-dkms

Reboot your computer . Now you have the new wireless network adapter ready and working showing WIFI routers around you. In this case I configured it for Deepin 15.4

This is my currents list of working network cards :

If the easy-way fails  Plan-B

sudo apt-get install build-essential linux-headers-generic dkms git
git clone
sudo dkms add ./rtl8192eu-linux-driver
sudo dkms install rtl8192eu/1.0


If you do not have an active internet connection download Transfer the file to the Ubuntu install, then extract it to the desktop. Then in terminal

cd Desktop
sudo dkms add ./rtl8192eu-linux-driver
sudo dkms install rtl8192eu/1.0


EDIT to add:
Now that you have installed it using make, I would suggest
cd Desktop/rtl8192eu-linux-driver
make clean


If you have any suggestions or ideas , do email me. If you like this post please register and comment it or share it! Thanks for reading.–Ari Campos