So the kernel drivers seem awful, and there is a Realtek-supplied driver that works a lot better (at least for me). Latest version seems to be available from https://github.com/pvaret/rtl8192cu-fixes/blob/master/README.md

Setup is well documented elsewhere, but there were some minor variations to make it work on the OSBo image:

  1. Install DKMS support for compiled kernel modules
    # build-essential is already on OSBo image
    apt-get install dkms

  2. Download precompiled BB headers for OSBo kernel version
    wget http://rcn-ee.net/deb/wheezy-armhf/v3.8.13-bone28/linux-headers-3.8.13-bone28_1.0wheezy_armhf.deb
    dpkg --install linux-headers-3.8.13-bone28_1.0wheezy_armhf.deb

  3. Download and install patched driver

    git clone https://github.com/pvaret/rtl8192cu-fixes.git
    dkms add ./rtl8192cu-fixes
    dkms install install 8192cu/1.8
    # Watch your build fail due to missing timex.h dependency

  4. Edit /usr/src/linux-headers-3.8.13-bone28/arch/arm/include/asm/timex.h on line 18 to change



    This looks pointless, but allows the build to complete (run dkms install again)

  5. Blacklist the native kernel module so the newly compiled module will be used instead
    cp ./rtl8192cu-fixes/blacklist-native-rtl8192.conf /etc/modprobe.d/

  6. I’ve also disabled radio power saving as leaving it enabled fills the dmesg log with status messages and causes occasional disconnects from AP. Put the following in a new /etc/modprobe.d/8192cu.conf file
    options 8192cu rtw_power_mgnt=0 rtw_enusbss=0

Obviously these instructions and links/URLs will not age well– they work nicely as of 17 December 2013.

Now ping is not losing packets:

521 packets transmitted, 521 packets received, 0.0% packet loss
round-trip min/avg/max/stddev = 2.450/6.857/19.328/1.572 ms