k3tchup
Posts: 12
Joined: Tue Mar 05, 2013 4:56 pm

Wireless N

Tue Mar 05, 2013 5:02 pm

Hi,
so I need to use my Pi with a WiFi adapter. I used my old Pentagram lite N but it didn't work as N, only G and with poor quality...
So I looked up on http://elinux.org/RPi_VerifiedPeripherals that TP-LINK TL-WN823N works out of the box. So I bought it. To my suprise it also didn't sync in N technology and even in iwconfig it shows that the adapter is only b,g capable (Pentagram showed b,g,n... also the TP is 300Mbit).

Does anyone got a working WiFi N network ? Does any of adapters work "out of the box" ? What do I have to do to make it work ?

Cloudcentric
Posts: 1277
Joined: Fri Sep 14, 2012 9:13 am

Re: Wireless N

Tue Mar 05, 2013 6:01 pm

Operating System not known ?

If it is Raspbian "wheezy" then you need the latest Kernel and Updates, I can achieve around 143 N speed with a RTL8188CUS generic Adaptor

On the command line type the following, pressing the enter key after each entry and follow the prompts:

sudo su
apt-get update
apt-get dist-upgrade
sync
reboot

http://debianarmpi.blogspot.co.uk
.
.

k3tchup
Posts: 12
Joined: Tue Mar 05, 2013 4:56 pm

Re: Wireless N

Tue Mar 05, 2013 8:59 pm

Oh yeah I forgot to add that it's Raspbian.
I only updated by apt-get upgrade.

I did as you told, but not many packages were updated.

Code: Select all

The following NEW packages will be installed:
  gnome-accessibility-themes gnome-themes-standard-data libqtdbus4
The following packages will be upgraded:
  binutils cups-bsd cups-client cups-common gnome-themes-standard libcups2
  libcupsimage2 libqt4-dbus libqt4-network libqt4-svg libqt4-xml libqtcore4
  libqtgui4 qdbus
14 upgraded, 3 newly installed, 0 to remove and 0 not upgraded.
Still the adapter in iwconfig is b,g only...

Code: Select all

pi@raspberrypi ~ $ iwconfig
wlan0     IEEE 802.11bg  ESSID:"home"  Nickname:"<WIFI@REALTEK>"
          Mode:Managed  Frequency:2.452 GHz  Access Point: 68:7F:74:30:59:BC
          Bit Rate:54 Mb/s   Sensitivity:0/0
          Retry:off   RTS thr:off   Fragment thr:off
          Power Management:off
          Link Quality=100/100  Signal level=76/100  Noise level=0/100
          Rx invalid nwid:0  Rx invalid crypt:0  Rx invalid frag:0
          Tx excessive retries:0  Invalid misc:0   Missed beacon:0

lo        no wireless extensions.

eth0      no wireless extensions.

Cloudcentric
Posts: 1277
Joined: Fri Sep 14, 2012 9:13 am

Re: Wireless N

Tue Mar 05, 2013 9:17 pm

apt-get dist-upgrade did you use this command ?

What kernel is listed when logged in on command line 3.6.11 ?
.
.

DBryant
Posts: 281
Joined: Sat Feb 02, 2013 12:41 pm
Location: Berkshire, UK

Re: Wireless N

Tue Mar 05, 2013 9:17 pm

Whezzy install in the last week or so

Code: Select all

uname -a
Linux raspberry 3.6.11+ #371 PREEMPT Thu Feb 7 16:31:35 GMT 2013 armv6l GNU/Linux
For the following adapter

Code: Select all

Bus 001 Device 008: ID 0bda:8176 Realtek Semiconductor Corp. RTL8188CUS 802.11n WLAN Adapter
Has M capability:

Code: Select all

$ iwconfig
wlan0     IEEE 802.11bgn  ESSID:"bryant-ap"  Nickname:"<WIFI@REALTEK>"
          Mode:Managed  Frequency:2.437 GHz  Access Point: 00:81:D8:65:5F:32
          Bit Rate:150 Mb/s   Sensitivity:0/0
          Retry:off   RTS thr:off   Fragment thr:off
          Power Management:off
          Link Quality=100/100  Signal level=100/100  Noise level=0/100
          Rx invalid nwid:0  Rx invalid crypt:0  Rx invalid frag:0
          Tx excessive retries:0  Invalid misc:0   Missed beacon:0
So it can work!

k3tchup
Posts: 12
Joined: Tue Mar 05, 2013 4:56 pm

Re: Wireless N

Wed Mar 06, 2013 8:02 am

Yes I did the dist-upgrade.
I will check what kernel when I get home.

As I said I firstly used a Pentagram card which showed in iwconfig as 802.11bgn, but synced at 36Mbit/s.
And this TP link is supposed to work out of the box.
I will borrow TL-WN722N (N-lite) from a friend of mine and see if there is any difference to TL-WN823N (Full N).

@DBryant
Are you using N lite ? Your getting only 150Mbit/s.

k3tchup
Posts: 12
Joined: Tue Mar 05, 2013 4:56 pm

Re: Wireless N

Wed Mar 06, 2013 4:08 pm

I installed the system from berry boot, don't know what's the rpi-aufs...

Code: Select all

Linux raspberrypi 3.6.11-rpi-aufs #1 PREEMPT Mon Feb 11 22:51:39 CET 2013 armv6l GNU/Linux
Adapter:

Code: Select all

Bus 001 Device 007: ID 0bda:8178 Realtek Semiconductor Corp. RTL8192CU 802.11n WLAN Adapter

Spid
Posts: 525
Joined: Sat Jan 19, 2013 12:47 pm

Re: Wireless N

Wed Mar 06, 2013 4:40 pm

wlan0 IEEE 802.11bgn ESSID:"TALKTALK-58B9C0" Nickname:"<WIFI@REALTEK>"
Mode:Managed Frequency:2.437 GHz Access Point: AC:E2:15:58:B9:C2
Bit Rate:150 Mb/s Sensitivity:0/0
Retry:off RTS thr:off Fragment thr:off
Power Management:off
Link Quality=100/100 Signal level=60/100 Noise level=0/100
Rx invalid nwid:0 Rx invalid crypt:0 Rx invalid frag:0
Tx excessive retries:0 Invalid misc:0 Missed beacon:0
I will always assume you are running Raspbian for desktop and Raspbmc for XMBC !

k3tchup
Posts: 12
Joined: Tue Mar 05, 2013 4:56 pm

Re: Wireless N

Mon Mar 11, 2013 9:38 pm

I don't want you to show me that it works for you, I want you to show me how to make it work !

So I installed Raspbian from webpage (no berry boot)

Code: Select all

Linux raspberrypi 3.6.11+ #371 PREEMPT Thu Feb 7 16:31:35 GMT 2013 armv6l GNU/Linux
I tested on:
  • TP-LINK TL-WN823N
  • TP-LINK TL-WN722N
  • D-Link DWA-140
All are said to be compatible (site I mentioned before) with RPi. Sure they "work" but none of them can connect with N technology... that's pretty sad.
You got any ideas, other than buying more dongles for testing ?

BTW. Why does lsusb say:

Code: Select all

Bus 001 Device 007: ID 0bda:8178 Realtek Semiconductor Corp. RTL8192CU 802.11n WLAN Adapter
And iwconfig (no N technology):

Code: Select all

wlan0     IEEE 802.11bg

Cloudcentric
Posts: 1277
Joined: Fri Sep 14, 2012 9:13 am

Re: Wireless N

Mon Mar 11, 2013 10:12 pm

I get 150 but use a RTL8188CUS http://debianarmpi.blogspot.co.uk

I recently undertook another fresh install, because bought some new SD Cards, and just plugged it in and works. the adapter I have works both in the Pi's USB as well as a Powered Hub.

Bus 001 Device 004: ID 0bda:8176 Realtek Semiconductor Corp. RTL8188CUS 802.11n WLAN Adapter

wlan0 IEEE 802.11bgn ESSID:"TALKTALK-58B9C0" Nickname:"<WIFI@REALTEK>"
Mode:Managed Frequency:2.437 GHz Access Point: AC:E2:15:58:B9:C2
Bit Rate:150 Mb/s Sensitivity:0/0
Retry:off RTS thr:off Fragment thr:off
Power Management:off
Link Quality=100/100 Signal level=97/100 Noise level=0/100
Rx invalid nwid:0 Rx invalid crypt:0 Rx invalid frag:0
Tx excessive retries:0 Invalid misc:0 Missed beacon:0

Do you live in UK ?
.
.

k3tchup
Posts: 12
Joined: Tue Mar 05, 2013 4:56 pm

Re: Wireless N

Tue Mar 12, 2013 10:03 am

I live in Poland.
Well I was suggested by the verified peripherials page, but I found a dongle with the same chipset as yours, TP-LINK TL-WN725N (150N only), it's pretty cheap and it's micro size. So I'll probably buy it and hopefully get normal speeds.
Have you ever tried to achieve 300Mb/s ? Or does your router do only 150 ?

k3tchup
Posts: 12
Joined: Tue Mar 05, 2013 4:56 pm

Re: Wireless N

Tue Mar 12, 2013 3:54 pm

OK now I'm really buffled.
So I bought TP-LINK TL-WN725N wich is RTL8188CUS.

Code: Select all

Bus 001 Device 006: ID 0bda:8176 Realtek Semiconductor Corp. RTL8188CUS 802.11n WLAN Adapter
The same as you ! But still it's G only...

Code: Select all

wlan0     IEEE 802.11bg  ESSID:"home"  Nickname:"<WIFI@REALTEK>"
          Mode:Managed  Frequency:2.452 GHz  Access Point: 68:7F:74:30:59:BC
          Bit Rate:54 Mb/s   Sensitivity:0/0
          Retry:off   RTS thr:off   Fragment thr:off
          Power Management:off
          Link Quality=100/100  Signal level=71/100  Noise level=0/100
          Rx invalid nwid:0  Rx invalid crypt:0  Rx invalid frag:0
          Tx excessive retries:0  Invalid misc:0   Missed beacon:0
Are there any configuration files that turn off the N capability ? Are you using other drivers then those in the raspbian ?

User avatar
RaTTuS
Posts: 10828
Joined: Tue Nov 29, 2011 11:12 am
Location: North West UK

Re: Wireless N

Tue Mar 12, 2013 4:06 pm

what power supply are you using - how are you powering the wifi it may be you don't have enough umpth to get the full speed
How To ask Questions :- http://www.catb.org/esr/faqs/smart-questions.html
WARNING - some parts of this post may be erroneous YMMV

1QC43qbL5FySu2Pi51vGqKqxy3UiJgukSX
Covfefe

k3tchup
Posts: 12
Joined: Tue Mar 05, 2013 4:56 pm

Re: Wireless N

Tue Mar 12, 2013 4:30 pm

It's not a power problem.
For Raspberry Pi I'm using the original power adapter which is 1.2 A.
And for any external USB devices I'm using a powered DLink hub with psu with 2.5 A which is plenty...

Right now I'm using a dongle that doesn't even require a powered hub.

User avatar
topguy
Posts: 7313
Joined: Tue Oct 09, 2012 11:46 am
Location: Trondheim, Norway

Re: Wireless N

Tue Mar 12, 2013 4:36 pm

k3tchup wrote: Are there any configuration files that turn off the N capability ? Are you using other drivers then those in the raspbian ?
Maybe its time to look at your wireless router settings.

Do you have other 'N' devices connecting at > 54Mb/s ?

k3tchup
Posts: 12
Joined: Tue Mar 05, 2013 4:56 pm

Re: Wireless N

Tue Mar 12, 2013 6:44 pm

Yes.
On windows machine I get 270Mb/s.
So I know it's a system/driver thing...

watice
Posts: 1
Joined: Mon Apr 15, 2013 1:42 pm

Re: Wireless N

Mon Apr 15, 2013 1:43 pm

As I understood it, a 5V 2A power supply was needed for this. I have not yet tested this myself.

k3tchup
Posts: 12
Joined: Tue Mar 05, 2013 4:56 pm

Re: Wireless N

Thu May 30, 2013 9:38 am

To end up the thread.
I bought Access Point TP-Link TL-WA801N. It works as a client and is always connected to the router on 300Mbit/s.
So now my workstation, raspberry and access point is connected by ethernet switch (100Mbit/s MAX for raspberry).
I'm getting great transfer rates. 10Mbyte/s on upload/download to raspberry, so LAN is maxed out :P
So it's a great solution if you build a torrent box and your internet connection is wireless.

pbanders
Posts: 8
Joined: Thu Feb 07, 2013 9:35 pm

Re: Wireless N

Tue Feb 18, 2014 7:00 pm

I had a similar problem (i.e. only could connect at 54 mbps), and found this topic. I tried various Realtek and other adapters, always 54 mbps. I tried all of the fixes suggested here, still 54 mbps. Eventually, I figure out what was happening and how to fix it, at least for my setup, YMMV. The problem for my systems is that like many people, my router (Linksys/Cisco E3000) can operate in "mixed mode", where it can connect with 802.11B, G, and N systems (A as well). When operating in mixed mode, the router has to offer both TKIP and CCMP (a.k.a. AES) encryption protocols, as G used TKIP. When 802.11n came along, it was decided that TKIP wasn't secure enough, so it was implemented with CCMP. However, you can still use TKIP with 802.11n, but if you do so, YOU ARE RESTRICTED TO 54 mbps! See the following wikipedia entry:

http://en.wikipedia.org/wiki/Wi-Fi_Prot ... n_protocol

The problem is when you use the GUI wireless tool on the Raspi, and your router is operating in mixed mode, when you first connect to the AP the configuration screen lists TKIP first, and CCMP second. If you don't click the drop-down and select CCMP, you get TKIP, and are restricted to 54 mbps. All that you have to do to fix the problem is to edit your AP's encryption to be CCMP, and you can connect with 802.11n, as verified by iwconfig. Note that even after doing this, I did notice that some of the adapters I have will connect at a full 150 mbps, while others (like the Adafruit model 814) will only connect at 72.2 mpbs. Still working on that one. Hope this info is helpful to some of you out there.

pbanders
Posts: 8
Joined: Thu Feb 07, 2013 9:35 pm

Re: Wireless N

Sun Mar 09, 2014 2:46 am

OK, so a bit more about the 72.2 mbps vs 150 mbps connections. The issue seems to be channel width on the 2.4 GHz band. If the channel width is the standard 20 MHz, the "150 mbps" labeled adapters (like the typical ones we're using with the Pi) are restricted to 72.2 mbps. To get 150 mbps, you have to channel bond on the router, which bonds two adjacent channels into one, so that you get a 40 MHz wide channel. Your ability to do this depends upon the type of router you have, the channels your neighbors are using and how much interference they're generating (as well as interference from any other 2.6 GHz devices in your house). You should use a tool like Amped Wireless's WiFi Analytics Tool on a PC to look at the 2.6 GHz band and see what channels are used and what the signal levels are. You may find there are no good options and are stuck with a 20 MHz channel width. You also may find that your router won't permit you to force a 40 MHz wide channel on the 2.6 GHz band (e.g. Linksys E3000).

I poked around with my router and eventually got it to give me a 40 MHz wide channel on the 2.6 GHz band, and lo and behold, all of my Pi's that were previously connected at 72.2 mbps were now connected at 150 mpbs. Note that adapters (not usually the ones we use with the Pi) that are single band (2.6 GHz) and labeled "300 mbps" can connect at 150 mbps on a single 20 MHz channel. An example of this kind of adapter is a Hawking HWDN1. Note that to get 300 mbps with the HWDN1, I had to have channel bonding to 40 MHz, as you might expect.

pbanders
Posts: 8
Joined: Thu Feb 07, 2013 9:35 pm

Re: Wireless N

Sun Mar 09, 2014 2:02 pm

More - this is a very useful document that explains 802.11n networking:

http://www.lmi.net/wp-content/uploads/O ... 02.11n.pdf

It explains the issues with 72.2 vs 150 mbps connections in more detail. Look at the table on page 5. which shows antenna configurations vs connection speeds, as a function of channel width. Between the router and the wireless adapter, the lowest number of antennas determines the connection speed. All of the simple 802.11n dongles we use for the Pi have 1x1 antenna configuration, so even if you have a 2x2 or 3x3 router, you only get 1x1 performance. The table clearly shows that if you are connecting with a single 20 MHz channel width, you will only get 72 mbps at a max. To get 150 mbps with a 1x1 antenna, you router needs to supply a 40 MHz channel width.

The table also explains how that some "300 mbps" adapters are able to use a 20 MHz channel width and connect at 150 mpbs - it's because they have a 2x2 antenna configuration. And, if you'll notice, it's not really 150 mpbs - it's 144 mbps. Always wondered why, now I know.

The document referenced is full of other useful info I haven't seen elsewhere, worth a read.

User avatar
holdmyheadwhileipuke
Posts: 11
Joined: Thu Apr 03, 2014 8:33 pm
Location: Somewhere out west.

Re: Wireless N

Fri Apr 25, 2014 4:07 am

pbanders wrote:OK, so a bit more about the 72.2 mbps vs 150 mbps connections. The issue seems to be channel width on the 2.4 GHz band. If the channel width is the standard 20 MHz, the "150 mbps" labeled adapters (like the typical ones we're using with the Pi) are restricted to 72.2 mbps. To get 150 mbps, you have to channel bond on the router, which bonds two adjacent channels into one, so that you get a 40 MHz wide channel. Your ability to do this depends upon the type of router you have, the channels your neighbors are using and how much interference they're generating (as well as interference from any other 2.6 GHz devices in your house). You should use a tool like Amped Wireless's WiFi Analytics Tool on a PC to look at the 2.6 GHz band and see what channels are used and what the signal levels are. You may find there are no good options and are stuck with a 20 MHz channel width. You also may find that your router won't permit you to force a 40 MHz wide channel on the 2.6 GHz band (e.g. Linksys E3000).

I poked around with my router and eventually got it to give me a 40 MHz wide channel on the 2.6 GHz band, and lo and behold, all of my Pi's that were previously connected at 72.2 mbps were now connected at 150 mpbs. Note that adapters (not usually the ones we use with the Pi) that are single band (2.6 GHz) and labeled "300 mbps" can connect at 150 mbps on a single 20 MHz channel. An example of this kind of adapter is a Hawking HWDN1. Note that to get 300 mbps with the HWDN1, I had to have channel bonding to 40 MHz, as you might expect.
Dude, thanks for the awesome info! I have been having flakiness issues with my adapters for a while now. I am using RT5370's with external 7db gain dlink antennas. I always wondered why this thing connected at such slow speeds and had such horrid performance. Both of my home networks were already using the 40mhz bonding but I was set for TKIP+AES. Stupid me did not think that the key pair would cause a slower connection speed. I didn't have to change a thing except my config then boom

Code: Select all

sudo ifdown wlan0;sudo ifup wlan0
Now getting 150. Any ideas to reduce the Tx excessive retries? I have power management disabled but still seem to have a few of these.

J

ecarter
Posts: 1
Joined: Wed Dec 24, 2014 10:22 am

Re: Wireless N

Wed Dec 24, 2014 10:24 am

Thanks a lot for this I really learnt something today

User avatar
mahjongg
Forum Moderator
Forum Moderator
Posts: 14831
Joined: Sun Mar 11, 2012 12:19 am
Location: South Holland, The Netherlands

Re: Wireless N

Wed Dec 24, 2014 12:06 pm

The PI is a very tiny device, it doesn't have a lot of "groundplane" for a WiFi antenna to work effectively.
One way the WiFi radio might be improved is to connect the PI's ground to something electrically conductive that has a larger area/mass than just the PI itself.
Perhaps a 10x10cm sheet of aluminum foil, connected to one of the metal shells of the connectors (USB/Ethernet/HDMI) will improve reception and transmission.

Its about the capacitive coupling to earth.

Also moving the adapter 10cm away from the interference of the SoC might approve reception.

cil8
Posts: 180
Joined: Tue Feb 14, 2012 10:47 am

Re: Wireless N

Tue Mar 03, 2015 10:15 am

Hi all!

TP-LINK TL-WN823N works well directly plugged into Raspberry model B (I don't care about 5Ghz)? Is it able to act as access point?

thanks!

Return to “Beginners”