Getting wireless rtl8192cu to work

This forum is for topics specific to the Raspberry Pi and Arch Linux ARM

Getting wireless rtl8192cu to work

Postby SamSpade » Tue Oct 14, 2014 6:42 pm

I just got a Raspberry Pi Model B+ and wanted to use it for Wi-Fi Direct (P2P-GO) or as an access point. I bought one of the popular mini Wi-Fi USB dongles that has the Realtek RTL8192CU/RTL8188CUS chipset:
Image

I would have wanted to continue this thread but it's already locked:
Getting wireless rtl8192cu to work on Arch-Rasp 3.10 kernel

So here's what I know so far:
1) The mainline Linux drivers for the RTL8192CU chipset are rtl8192cu, rtl_usb, rtlwifi, rtl8192c_common. They work well on a PC and include other features like AP, monitor mode, P2P-GO. Unfortunately they don't work well on the Raspberry Pi.
2) Because of the incompatibility, the various RPi distros (including Arch Linux ARM) replaced the mainline drivers with the open-source Realtek-supplied drivers. It uses one module called 8192cu.
3) The Realtek-supplied driver (version 4.0.2_9000, 2013/10/29) works extremely well, but is limited to standard Wi-Fi client functionality. It can't do AP, monitor mode or Wi-Fi Direct (P2P).
4) One option to get the added Wi-Fi functionality (e.g. access point) is to use the mainline in-tree rtl8192cu/rtlwifi drivers ... and hope it works. The linux-raspberrypi-latest kernel (currently 3.16.3-1, packaged by moonman I believe ... thanks!) uses the in-tree drivers. Simply install it by 'pacman -S linux-raspberrypi-latest' and the stable kernel will be replaced.

In my case, the in-tree drivers do not work well.

Here's an iperf of the Realtek-supplied 8192cu driver:
$this->bbcode_second_pass_code('', '
iperf with default Realtek-supplied 8192cu driver (linux-raspberrypi 3.12.29-1)
UPLOAD speed
[ ID] Interval Transfer Bandwidth
[ 5] 0.0- 1.0 sec 6.75 MBytes 56.6 Mbits/sec
[ 5] 1.0- 2.0 sec 7.50 MBytes 62.9 Mbits/sec
[ 5] 2.0- 3.0 sec 7.75 MBytes 65.0 Mbits/sec
[ 5] 3.0- 4.0 sec 7.25 MBytes 60.8 Mbits/sec
[ 5] 4.0- 5.0 sec 7.12 MBytes 59.8 Mbits/sec
[ 5] 5.0- 6.0 sec 8.25 MBytes 69.2 Mbits/sec
[ 5] 6.0- 7.0 sec 7.62 MBytes 64.0 Mbits/sec
[ 5] 7.0- 8.0 sec 7.50 MBytes 62.9 Mbits/sec
[ 5] 8.0- 9.0 sec 6.88 MBytes 57.7 Mbits/sec
[ 5] 9.0-10.0 sec 7.88 MBytes 66.1 Mbits/sec
[ 5] 0.0-10.1 sec 74.6 MBytes 62.1 Mbits/sec
DOWNLOAD speed
[ 3] 0.0- 1.0 sec 7.43 MBytes 62.3 Mbits/sec
[ 3] 1.0- 2.0 sec 7.77 MBytes 65.2 Mbits/sec
[ 3] 2.0- 3.0 sec 7.93 MBytes 66.5 Mbits/sec
[ 3] 3.0- 4.0 sec 8.11 MBytes 68.1 Mbits/sec
[ 3] 4.0- 5.0 sec 8.21 MBytes 68.8 Mbits/sec
[ 3] 5.0- 6.0 sec 8.26 MBytes 69.3 Mbits/sec
[ 3] 6.0- 7.0 sec 8.03 MBytes 67.4 Mbits/sec
[ 3] 7.0- 8.0 sec 8.14 MBytes 68.3 Mbits/sec
[ 3] 8.0- 9.0 sec 8.09 MBytes 67.8 Mbits/sec
[ 3] 9.0-10.0 sec 8.15 MBytes 68.4 Mbits/sec
[ 3] 0.0-10.4 sec 83.2 MBytes 67.4 Mbits/sec
')

... and here's the iperf with mainline rtl8192cu/rtlwifi drivers (linux-raspberrypi-latest 3.16.3-1)
$this->bbcode_second_pass_code('', '
UPLOAD speed
[ ID] Interval Transfer Bandwidth
[ 3] 0.0- 1.0 sec 2.75 MBytes 23.1 Mbits/sec
[ 3] 1.0- 2.0 sec 0.00 Bytes 0.00 bits/sec
[ 3] 2.0- 3.0 sec 512 KBytes 4.19 Mbits/sec
[ 3] 3.0- 4.0 sec 128 KBytes 1.05 Mbits/sec
[ 3] 4.0- 5.0 sec 0.00 Bytes 0.00 bits/sec
[ 3] 5.0- 6.0 sec 2.62 MBytes 22.0 Mbits/sec
[ 3] 6.0- 7.0 sec 896 KBytes 7.34 Mbits/sec
[ 3] 7.0- 8.0 sec 0.00 Bytes 0.00 bits/sec
[ 3] 8.0- 9.0 sec 1.00 MBytes 8.39 Mbits/sec
[ 3] 9.0-10.0 sec 0.00 Bytes 0.00 bits/sec
[ 3] 0.0-10.7 sec 8.00 MBytes 6.28 Mbits/sec
DOWNLOAD speed
[ 5] 0.0- 1.0 sec 894 KBytes 7.32 Mbits/sec
[ 5] 1.0- 2.0 sec 307 KBytes 2.51 Mbits/sec
[ 5] 2.0- 3.0 sec 0.00 Bytes 0.00 bits/sec
[ 5] 3.0- 4.0 sec 0.00 Bytes 0.00 bits/sec
[ 5] 4.0- 5.0 sec 1.59 MBytes 13.3 Mbits/sec
[ 5] 5.0- 6.0 sec 0.00 Bytes 0.00 bits/sec
[ 5] 6.0- 7.0 sec 1.23 MBytes 10.3 Mbits/sec
[ 5] 7.0- 8.0 sec 60.8 KBytes 498 Kbits/sec
[ 5] 8.0- 9.0 sec 304 KBytes 2.49 Mbits/sec
[ 5] 9.0-10.0 sec 0.00 Bytes 0.00 bits/sec
[ 5] 0.0-10.5 sec 5.38 MBytes 4.30 Mbits/sec
')

The Realtek 8192cu driver (62 Mbps/67Mbps) is almost as fast as eth0, while the rtl8192cu driver (6 Mbps/4 Mbps) is intermittent and unusable.

A few have toyed around with recompiling hostapd (for AP function):
http://decryption.wordpress.com/2014/05 ... i-chipset/

... or patching rtlwifi but with unsatisfactory results:
http://www.raspberrypi.org/forums/viewtopic.php?t=24951

Question:
Has anyone found a way to make the mainline drivers work as well as the Realtek-supplied 8192cu driver, with the added functionalities like AP, monitor mode, P2P? Are there any patches we can use to update the mainline drivers?
SamSpade
 
Posts: 1
Joined: Tue Oct 14, 2014 4:31 pm

Re: Getting wireless rtl8192cu to work

Postby WarheadsSE » Wed Oct 15, 2014 2:31 pm

This is a question to take up with the maintainer(s) of the rtlwifi driver(s) -- Larry W Finger.
Core Developer
Remember: Arch Linux ARM is entirely community donation supported!
WarheadsSE
Developer
 
Posts: 6807
Joined: Mon Oct 18, 2010 2:12 pm


Return to Raspberry Pi

Who is online

Users browsing this forum: No registered users and 100 guests