ar9170 atheros driver install (tl-wn821n usb AR9170+AR9102)

Forums Network Management ZeroShell ar9170 atheros driver install (tl-wn821n usb AR9170+AR9102)

  • This topic is empty.
Viewing 8 posts - 1 through 8 (of 8 total)
  • Author
  • #42596

    So I’ve had this project of mine for the longest time.

    Get my wifi usb to work in zeroshell.

    I’ve been doing a lot of homework.

    First I was lead down the path of wifi support added with madwifi, but that was in 07, yet when I boot with zeroshell, it doesn’t find any athero’s chipsets of notice.

    Anyways, the problem seems to be chipset support in the kernel.

    This is what I’ve found digging around.

    To load usb nic
    told me to insmod a .ko file associated with the driver

    So I looked for a matching .ko file, of which I did not find.

    I ran into this site when looking for how to load drivers


    then check if the corresponding module is loaded.

    then check if the interface is working
    ifconfig -a

    If you cannot find something
    dmesg | grep ETH

    I found this device id for my device

    Then I found a matching ko file on this site


    Course it uses a newer kernel. I couldn’t find the file itself, but I did some more research.

    led me to this site

    Which has instructions on loading the drivers with the kernel that beta13 uses , but I’m a bit lost on the header instructions.

    Please be very sure you have your kernel headers installed before reporting any sort of build issues with this package. This usually will mean having this symlink point to a valid directory with kernel headers in it:

    /lib/modules/`uname -r`/build

    Also found out how debian loads it.

    Anyone know using the last two url’s how I might get it accomplished in zeroshell?

    Thanks a bunch!

    I did some more research
    I kept running out of space when I was trying to wget packages.

    Realized I’m in read only environment
    So it’s a huge long process to get all this working

    To install headers
    I have to get a writeable copy of zeroshell

    Then I have to follow this pdf to setup a developer environment

    Then I can load headers

    Then I can probably setup the wifi drivers.


    just to let you guys know. I’ve finished setting up the environment.

    I basically did everything up to the point of actually installing the drivers.

    I’ll fill you guys in. It took me a week to figure out the writeable copy of zeroshell, learning how to mount a partition in fstab and setting up paths in the /etc/profile, but now I’m pretty much there.

    also, another possible way to get wifi n support is by having a kernel that has the modules already supported, so update the kernel.


    apt-get needed more space on / 🙁

    Maybe I can download the precompiled kernel and work with that to build my environment.


    well, I got zeroshell to boot from a hard drive following the instructions on how to make a writeable copy.

    I was able to do it without using a ramdrive. I had enough free space to extract apt.bin; however, on subsequent reboot, it wouldn’t boot, got a message about a bunch of files not found in /etc.

    Maybe my hd is corrupt. will try again with an ssd flash card I have.

    To make matters worse, my profile got corrupt.

    So in theory, if I get it up and running I should be able to get those linux drivers (cross fingers), and then compile the compat wireless drivers.


    openwrt has a x86 version. It’s a bit of a pain to get to work right from the getgo, but it has a webgui. It’s not like zeroshell, you do have to use the shell prompt, but not necessarily.

    This distribution already has support for some linux wifi n drivers, primarily the one in this thread, but also the 5008 athero’s chipset.

    I haven’t gotten it to work with x86 yet, but I have seen it working on my wnr854t router.

    Installing packages is pretty easy
    opkg install http:\www.alsjdflksajdflkjdsaflkjdsa.opk is how you install stuff.

    be wary, don’t uninstall busybox (tried to do so to install bash), and when you do, all commands seem to not work anymore (except opkg), so I advice you to not use opkg install on all your packages, at the very least have busybox’s opk on your drive before uninstalling it


    If you want an easy working copy of openwrt backfire on your hd.

    I had to do these steps.
    (I don’t know the parameters to dd the ext-2-combined file, so I took the root and extracted it manually to a formatted partition (using a partition tool), and then installed grub via zeroshell (grub install –root-directory /hd /dev/hda), then put the vmlinuz file in the /boot/ dir and then used the grub console to boot to the openwrt.

    I had to find what nic openwrt used as default to http into, but I was able to use the webgui from there to get stuff done, but you have to telnet in to get it to reboot (i.e. command reboot).


    to be honest, with openwrt on my wnr854t, my wifi n is quite fast, but I’d rather prefer not to have my wifi on an access point.

    Anyways. I tried openwrt. I figured the first try it didn’t work after installing all the packages I thought it needed. Then I figured I’d install all the packages that were different from the x86 package (btw use physdiskwrite to install openwrt from the .img.gz file to hd, it doesn’t ask for anything other than the image, and it booted right away). It showed a wireless adapter, but I never saw a signal from it, and worse, it never gave me an encryption method different than WEP, which led me to believe it wasn’t working.

    Fuck. Why the hell is wifi n so hard on linux routers? I mean, it’s possible, why can’t i get it on an x86 environment?


    Just to answer on your last sentense…
    All the effort to make devices work in linux is rarely supported by the manufacturer. Usually it is users and hackers who make things work in linux and sometimes they don’t achieve it so well. If we set aside Atheros which has good support in linux, I don’t trust other vendors.


    It was the antenna’s

    Here’s a complete list of packages I used for openwrt

    I used the default packages that came with the x86-combined-ext2 set

    and the following

    had to add
    wireless-tools 29-4

    for wap

    and voila, wifi n on my desktop (but not with this usb adapter, I used an r5008 chipset).

    Hope that helps some zeroshell people who are frustrated with no wifi n! I tested wifi n with dslreports.

    Ping still fluctuated the same with my wnr854t vs the desktop (I was hoping the desktop with it’s 3ghz proc would help prevent ping fluctuations, so I guess it’s the wifi card that is getting overloaded).

    I couldn’t get a fair read off of dslreports java test because my la server is acting funky. But hoo fucking rah guys. Got wifi n with openwrt!

    Tested with dslreports. I think I’m getting lower speeds with the card in the desktop than when I had it in my openwrt wnr854t router. With dslreports java speed test I was getting around 25Mb/s, now I’m getting about 10-15.

    I even moved the computer to expose the antenna’s more, and still the same thing.

    update 2:
    I guess my speeds were limited by the time of day.
    I was able to get 23Mb down with wifi. Before I was able to get 25Mb down. However with lan I was able to get 29, and I got 28 today. So i figure there about the same right now (plus my antenna’s not as exposed as it was before).

Viewing 8 posts - 1 through 8 (of 8 total)
  • You must be logged in to reply to this topic.