ZyXEL NWD-211AN USB

Live forum: http://rt2x00.serialmonkey.com/viewtopic.php?t=6132

jesmith

17-03-2011 17:51:03

Great news to share I just tried the ZyXEL NWD-211AN Dual Band Wireless N USB Adapter with the bleeding edge (3/16/2011) compat wireless drivers. It works!!! In AP mode!!!! At 5GHz!!!!!!

I can connect to this AP using an iPad and get to the internet with no difficulty.

As far as I am aware this is the ONLY USB 5Ghz AP (master, infrastructure) solution in existence. I am thrilled.

(For example, Linksys makes a USB stick with the same chipset, and it doesn't work correctly in AP mode. Ditto EnGenius. I have a whole pile of USB WiFi devices that don't work if anyone's interested in taking them off my hands wink )

Anyway, I had to make only one small change to the driver

[code3d0h3ifl]drivers/net/wireless/rt2x00/rt2x00usb.c:
{ USB_DEVICE(0x0586, 0x3418), USB_DEVICE_DATA(&rt2800usb_ops) },
[/code3d0h3ifl]

in the obvious place.

In case anyone wants to reproduce my wild success, here are some details
- I'm running a 2.6.27.8 kernel (SLAX 6.0.9)
- compat-wireless-2011-03-15
- hostapd v0.6.10 (hw_mode=a, ieee80211n=0) [N might work, but I don't need it, so I haven't tried it]
- dnsmasq version 2.52
- iw reg set US
- I'm starting hostapd, killing it, and starting it back up (this makes my PCI-e rt28xx card work more reliably, and I left the code in for this case)
- /lib/firmware/rt*.bin from the ralink web site (grabbed ages ago, not sure what version, sorry)
md5sum rt*.bin
99bce75086ea635a2f8288d9b835f787 rt2561.bin
2878d5eaa4ff907d4df36a834915aa53 rt2561s.bin
9998485bc152cf0f39dd61a33b92ad9b rt2661.bin
66332d7636ee78db31b056aa0e44b097 rt2860.bin
cfc8663dc0c671f1cf022c791b2f1283 rt2870.bin
bd733372ae21a010bf8a5511d7711c2d rt73.bin

Thank you so much for making this possible. I REALLY appreciate it.

jesmith

18-03-2011 20:22:14

Alas, not so great news It seems like this only works until I push it really hard. Regular web surfing is fine, but if I try to stream data at any high rate, I lose the connection. I've reproduced the problem with various clients, so this is definitely a problem on the device (AP) end.

The loss of connectivity is a little weird the machines cannot ping one another, but both of them believe they are still connected.

After a minute or two data will start flowing again.

There aren't any log messages on either end which give me a clue as to what might be going wrong.

I've tried dropping the data rate (using hostpd's conf) to 1200Kbps, and that did not solve it.

Next thing I'll try is getting 802.11n working instead of 802.11a, but I'm not hopeful that will make any difference.

I have CONFIG_RT2X00_LIB_DEBUGFS turned on in my build, so if there is anything I might be able to look at to help diagnose the issue, please let me know!

Thanks in advance for any advice.

-Joshua

jesmith

18-03-2011 20:50:39

Back to happy state! Turns out that 802.11n is robust even at high data rates. (This defies logic The simpler 802.11a doesn't work, but the complex 802.11n does? I suppose there must just be different code paths and the "n" are exercised/debugged more these days.)

Anyway to get back to happy state, just set

[codekfvo79jp]ieee80211n=1
ht_capab=[GF]
[/codekfvo79jp]

In the hostapd.conf, and you'll be in business. The clients I've tested with are an ipad 2 and a Macbook Pro.

Of course, there might be other ht_capab settings that will make things more wonderful, but I'm just happy to have a working system.

If you guys want me to help you diagnose the 802.11a issues, let me know. I can reproduce them easily. But I'm perfectly happy to leave 802.11a in the rearview, and rely on 802.11n from now on.

-Joshua

jesmith

13-05-2011 19:32:33

OK, I've got an issue. It turns out that about 1 in 6 times I boot up, the device is flaky as an AP. The symptoms are that I can connect to the AP from a client, and hostapd thinks everything is great, but there is never any IP-level communication (my client doesn't get a DHCP response, for example). If I run a tcpdump -i wlan0, there are no messages at all going across the interface.

When the system is in this state wlan0's TX Packets counter never increases. But this counter *is* increasing
[code3kikdck6]/sys/kernel/debug/ieee80211/phy0/statistics/transmitted_fragment_count[/code3kikdck6]
(I have all the stuff from kernel/debug if there is something else that might be interesting.)
wlan0's RX Packes counter does increase.

I have found that if I pull out and re-insert the Zyxel USB NIC, it always corrects the problem.

I have tried various soft equivalents of this
[code3kikdck6]echo 1 > /sys/kernel/debug/ieee80211/phy0/reset[/code3kikdck6]
that hangs my machine.
[code3kikdck6]ifconfig wlan0 down ; killall hostapd dnsmasq ; rmmod rt2800usb ; sleep 20 ; modprobe rt2800usb[/code3kikdck6]
that fixes the problem sometimes, but not always.

Questions
- Any theories what might be going on here? To reiterate both ends of the 802.11n connection believe they are connected, but no data is flowing
- Any ideas what I might be able to do to simulate the unplug/plug operation (other than unloading/reloading the driver, which didn't work)? I figure I can probably detect this problem by the presence of a low, non-increasing TX counter, and rattle the dongle's cage if I knew how.

Thanks in advance
-Joshua