Page 1 of 14 12311 ... LastLast
Results 1 to 10 of 137

Thread: Karmic RT2870 Driver Tutorial

  1. #1
    Join Date
    May 2007
    Location
    Ontario Canada
    Beans
    Hidden!
    Distro
    Ubuntu Development Release

    ABANDONED RALINK RT2870STA and RT3070STA USB WiFi Tutorial

    Update for October 2011: This guide was written in 2009, has not been supported in years, and is not a recommended way to deal with this problem.



    Ubuntu 11.10 "Oneiric Ocelot" no longer includes Ralink's out-of-kernel-tree drivers, instead it distributes drivers developed by the rt2x00 community project.



    For Those using Ubuntu 11.04 Natty and Lower: Luckily, someone has outlined how to pass new USB Dev IDs to a compiled kernel module using udev, and it is a MUCH better solution than what I've explained below (recompiling a kernel module).
    If you're having an issue with a driver not supporting your device due to a USB Dev ID issue, please see flash63's post here: http://ubuntuforums.org/showpost.php...48&postcount=6


    I no longer support this tutorial because I don't own any Ralink devices to test it on. It still has some useful info, so i'll leave it up. Good luck!




    This tutorial is for USB WiFi Adapters that use the RT2870 or RT3070 chipsets by Ralink.

    THE CURRENT STATE OF RALINK DRIVERS

    There are currently 2 groups developing drivers for Ralink chipsets: Ralink's own team and the community-run rt2x00 project. Rt2x00 drivers work very well, and are distributed with the Linux kernel. Ralink's drivers (such as rt2870sta and rt3070sta) have some ugly code, and at this time are distributed separately from the Linux kernel. These drivers have varying levels of support for different chipsets, and in some cases they would both support a given chip


    A Common Problem:
    USB devices report their USB Device IDs, which are used to determine whether a Linux kernel module (driver component) should control a device. Conflicts can occur when more than one module attempts to control a device with a given USB Dev ID. In Ubuntu 9.10, such conflicts exist between the community-written rt2x00 module, and Ralink's rt2870sta and rt3070sta modules. Furthermore, these modules do not detect many devices which they are able to control.

    The Scope of This Guide:
    This guide describes how to “blacklist” modules, to prevent conflicting modules from being concurrently loaded. Additionally, it describes how to modify and compile Ralink's rt2870sta and rt3070sta modules with support for new USB Dev Ids.

    Determining which module you should use:
    If a USB WiFi adapter is automatically detected by rt2870sta, rt3070sta or an rt2x00 module, it has likely been verified to function by that module's developers. While the rt2x00 driver has some support for rt2870 chipsets, it seems that rt2870 and rt3070 chipsets work best when controlled by Ralink's drivers. Only one of these modules should be loaded per network adapter.

    To determine which modules control your USB WiFi adapter, insert it and run the following command in terminal
    Code:
    lsmod |grep rt
    rt2870 devices are supported by Ralink's rt2870 driver (module rt2870sta) or by the rt2x00 project's driver (modules rt2800usb, rt2x00lib, rt2x00usb). rt3070 devices are supported by Ralink's rt3070 driver (module rt3070sta)

    Blacklisting Modules:

    To begin, unplug any Ralink USB WiFi adapters and restart your computer (or unload the modules).

    To use rt2870sta and blacklist rt2800usb, run the following commands in terminal:
    Code:
    gksudo gedit /etc/modprobe.d/blacklist.conf
    add these lines to the end of the file:
    Code:
    blacklist rt2x00usb
    blacklist rt2x00lib
    blacklist rt2800usb
    Save the file, then insert your USB WiFi device.

    To use rt2800usb and blacklist rt2870sta, run the following commands in terminal:
    Code:
    gksudo gedit /etc/modprobe.d/blacklist.conf
    add these lines to the end of the file:
    Code:
    blacklist rt2870sta
    Save the file, then insert your USB WiFii device.

    To use rt3070sta and blacklist all other modules (probably unnecessary, not recommended), run the following commands in terminal:
    Code:
    gksudo gedit /etc/modprobe.d/blacklist.conf
    add these lines to the end of the file:
    Code:
    blacklist rt2x00usb
    blacklist rt2x00lib
    blacklist rt2800usb
    blacklist rt2870sta
    Save the file, then insert your USB WiFi device.


    If this didn't work:

    Your device either doesn't function with the driver you chose, or your WiFi Adapter's USB Device ID is not detected by that driver. If you're certain of which chipset is in your WiFi Adapter, you can modify and compile a kernel module that will detect and attempt to control any adapter with its USB Dev ID.



    Determining Your Device's USB Device ID
    You can check your USB Device ID using
    Code:
    lsusb
    For example, lsusb states that a USB WiFi adapter has a device ID of 1234:7777
    Code:
     oo@oo:~$ lsusb
    Bus 001 Device 004: ID 1234:7777 Brand


    EDIT: PLEASE READ:
    Luckily, someone has outlined how to pass new USB Dev IDs to a compiled kernel module, and it is a MUCH better solution than what I've explained below (recompiling a kernel module).
    If you're having an issue with a driver not supporting your device due to a USB Dev ID issue, please see flash63's post here: http://ubuntuforums.org/showpost.php...48&postcount=6
    His Udev Rule is the best way to solve this problem. Good luck!



    Compiling a New Kernel Module (Driver)
    You'll need a compiler and Linux headers installed
    Code:
    sudo apt-get install build-essential linux-headers-generic

    Modifying and Compiling RT2870STA:

    Download a copy of Ralink's rt2870 USB driver from http://www.ralinktech.com/support.php?s=2
    Save it to your Ubuntu computer's desktop, then extract its contents using the following commands in terminal:
    Code:
    cd ~/Desktop
    tar -xvf ~/Desktop/RT2870_LinuxSTA*.tgz
    cd ~/Desktop/*2870*
    Now you'll make some modifications, to add your device's USB Device ID. The following is an EXAMPLE. Using the lsusb command, it has been determined that an adapter has has the USB Device ID 1234:7777. MODIFY THESE INSTRUCTIONS TO USE YOUR USB DEV ID! You can put whatever you want for comments between */ s, they are meant to document the code.

    Edit
    Code:
    gedit ~/Desktop/*2870*/common/rtusb_dev_id.c
    add to the group:
    Code:
    {USB_DEVICE(0x1234,0x7777)}, /* Example WiFi Device Name */
    Save.

    You'll now configure the source to be compiled with support for NetworkManager and wext. NetworkManager is Ubuntu's default graphical method for configuring networking. It provides the icon in the "notification area" aka "system tray".

    Edit
    Code:
    gedit ~/Desktop/*2870*/os/linux/config.mk
    Change
    Code:
    # Support Wpa_Supplicant
    HAS_WPA_SUPPLICANT=n
    # Support Native WpaSupplicant for Network Maganger
    HAS_NATIVE_WPA_SUPPLICANT_SUPPORT=n
    to
    Code:
    # Support Wpa_Supplicant
    HAS_WPA_SUPPLICANT=y
    # Support Native WpaSupplicant for Network Maganger
    HAS_NATIVE_WPA_SUPPLICANT_SUPPORT=y
    Save.


    In terminal:
    Code:
    cd ~/Desktop/*2870*
    (If you're trying to compile a second time, please note: Run "make clean" before running "make" to remove your previous attempt.)
    make
    sudo make install
    This installs the module rt2870sta.ko, but now you have 2 copies of it:
    one in /lib/modules/`uname -r`/kernel/drivers/net/wireless and another at /lib/modules/`uname -r`/kernel/drivers/staging/rt2870. The one in the staging directory is the one that came with Ubuntu, which obviously doesn't work for you.

    Before you move your old driver, run the following commands to see if your newly compiled driver actually functions with your USB device.
    Code:
    sudo modprobe -r rt2870sta
    sudo insmod /lib/modules/`uname -r`/kernel/drivers/net/wireless/rt2870sta.ko
    sudo /etc/init.d/networking restart
    sudo restart network-manager
    If NetworkManager now works, congratulations.

    Then delete the version of the rt2870sta module that came with Ubuntu (there are certainly better ways to do this [PLEASE ADVISE!], but this will allow the newly compiled one will load by default).
    Code:
    sudo mkdir ~/.rt2870.bak
    sudo mv /lib/modules/`uname -r`/kernel/drivers/staging/rt2870 ~/.rt2870.bak
    Otherwise, you will have to run the above commands whenever you want to use the new driver. You will need to recompile this module every time a new Linux kernel is installed.


    Modifying and Compiling RT3070STA:

    Download a copy of Ralink's rt3070 USB driver from http://www.ralinktech.com/support.php?s=2
    Save it to your Ubuntu computer's desktop, then extract its contents using the following commands in terminal:
    Code:
    cd ~/Desktop
    tar -xvf ~/Desktop/RT3070_LinuxSTA*.tgz
    cd ~/Desktop/*3070*
    Now you'll make some modifications, to add your device's USB Device ID. The following is an EXAMPLE. Using the lsusb command, it has been determined that an adapter has has the USB Device ID 1234:7777. MODIFY THESE INSTRUCTIONS TO USE YOUR USB DEV ID! You can put whatever you want for comments between */ s, they are meant to document the code.

    Edit
    Code:
    gedit ~/Desktop/*3070*/os/linux/usb_main_dev.c
    add your device to the group:
    Code:
    {USB_DEVICE(0x1234,0x7777)}, /* Example WiFi Device Name */
    Save.

    You'll now configure the source to be compiled with support for NetworkManager and wext. NetworkManager is Ubuntu's default graphical method for configuring networking. It provides the icon in the "notification area" aka "system tray".

    Edit
    Code:
    gedit ~/Desktop/*3070*/os/linux/config.mk
    Change
    Code:
    # Support Wpa_Supplicant
    HAS_WPA_SUPPLICANT=n
    # Support Native WpaSupplicant for Network Maganger
    HAS_NATIVE_WPA_SUPPLICANT_SUPPORT=n
    to
    Code:
    # Support Wpa_Supplicant
    HAS_WPA_SUPPLICANT=y
    # Support Native WpaSupplicant for Network Maganger
    HAS_NATIVE_WPA_SUPPLICANT_SUPPORT=y
    Save.


    In terminal:
    Code:
    cd ~/Desktop/*3070*
    (If you're trying to compile for the second time, please note: Run "make clean" before running "make" to remove your previous configuration files.)
    make
    sudo make install
    If you see any garbage about “/tftpboot”, disregard it. The developers made a mistake here and "make" tries to write to "/"
    The module rt3070sta.ko is now installed, but there are 2 copies of it:
    one in /lib/modules/`uname -r`/kernel/drivers/net/wireless and another at /lib/modules/`uname -r`/kernel/drivers/staging/rt3070. The one in the staging directory is the one that came with Ubuntu, which obviously doesn't work for you.

    Before you move your old driver, run the following commands to see if your newly compiled driver actually functions with your USB device.
    Code:
    sudo modprobe -r rt3070sta
    sudo insmod /lib/modules/`uname -r`/kernel/drivers/net/wireless/rt3070sta.ko
    sudo /etc/init.d/networking restart
    sudo restart network-manager
    If NetworkManager now works, congratulations.

    Then move the version of the rt3070sta module that came with Ubuntu (there are certainly better ways to do this [PLEASE ADVISE!], but this will allow the newly compiled one will load by default).
    Code:
    sudo mv /lib/modules/`uname -r`/kernel/drivers/staging/rt3070 ~/.rt3070.bak
    Otherwise, you will have to run the above commands whenever you want to use the new driver. You will need to recompile this module every time a new Linux kernel is installed.


    FAILURE AND DEBUGGING:

    If it failed, you should seriously reconsider whether your card has a different Ralink chipset such as the rt3070. Manufacturers often use various chipsets per model, even within a single revision. Many Ralink drivers are very similar, and seem to almost function with incompatible devices.


    This driver was configured to support NetworkManager. This is an layer that abstracts control over wifi devices, and is another point of failure. Linux network interfaces are normally controllled using a configuration file at /etc/network/interfaces . Normally, we could test this driver's functionality using iwlist scan, to make sure that any problems aren't being caused by NetworkManager while the driver functions properly. iwlist's performance is very unpredictable with this driver (this may only be when it is compiled to support NetworkManager) and it may not work at all, or only for a short time after the interface is brought up.

    First we need to know: Was your device detected by the version of rt2870sta included with Karmic, or did you add your USB Device ID to the module you compiled? You must do the blacklist steps even if you compiled a module.
    Does your device show up in the NetworkManager applet (networking icon in notification area aka "system tray)?
    What is the manufacturer and model number of your WiFi adapter?
    Have you tried to use ndiswrapper? If so, add "ndiswrapper" to /etc/modprobe.d/blacklist.conf . It will conflict with any native drivers.
    Are you running a new Karmic install or did you upgrade from Jaunty? This is important because if you've upgraded. some settings may not have gracefully migrated.

    For debugging purposes: Turn off your computer, unplug any Ralink-based USB wifi adapters. Turn it on, log in, let it finish booting. Open a terminal and run the command
    Code:
    tail -f /var/log/messages
    Open another terminal and run
    Code:
    tail -f /var/log/syslog
    Maximize the terminal windows (to fit outputs on 1 line) Then plug in your rt2870 device. Observe the outputs, and save them both to a txt file. The reason for turning off the computer is to ensure the device has to reload its firmware, and also to make the messages output easier to read. Post the output in this thread along with the output of the following commands, run with your WiFi adapter still connected:
    Code:
    ifconfig
    iwconfig
    If ra0 was not listed by ifconfig, run the following commands shortly after inserting the device and post the output:
    Code:
    sudo ifconfig ra0 up
    sudo iwlist ra0 scan

    Also post the output of the following commands.
    Code:
    cat /etc/network/interfaces | grep -v ^#
    lsusb
    lsmod
    modinfo /lib/modules/`uname -r`/kernel/drivers/net/wireless/rt2870sta.ko
    The purpose of these queries is to determine: Do you have conflicting drivers loaded? Does your newly compiled module have the correct device IDs? Is your WiFi card functioning without NetworkManager?

    When you run lsmod, you're looking to see which modules containing "rt" are loaded. If you have more than rt2870sta, you need to make some changes.


    I'm still looking for a better way to do this, I think there is
    a way to insert these IDs into a driver without compiling: using Udev.
    We should find a way to add dev ids to a binary module, and to blacklist them.
    There must be a mechanism to do this, please post if you learn how to use Udev or whatever it is Blacklisting a specific device from use by rt2x00 is a much better solution than blacklisting rt2x00. If someone has an rt73 device and an rt2870 device for example, the current solution does not work. rt73 will load rt2x00, and rt2870sta wont work.
    Last edited by peepingtom; October 15th, 2011 at 06:38 AM. Reason: Boooo!

  2. #2
    Join Date
    Apr 2007
    Beans
    22

    Re: Karmic RT2870 Driver Tutorial

    Hi,
    Does this depend on the Hardware Manufacturer? I mean, do we have to do something additional for each manufacturer?

    I will try today with My Siemens USB Gigaset 300 adapter (which I suppose has RT4870 chip).

    Thanks a lot !!!

  3. #3
    Join Date
    Nov 2009
    Beans
    8

    Re: Karmic RT2870 Driver Tutorial

    Thanks for the excellent and well written tutorial. However, I am still unable to get my Ralink 2870 adapter to work. I've played with this setup under Karmic far too long already, but tried once more using your links and suggestions, but still no go (this adapter worked great under Jaunty). As requested here is the lowdown of the settings.
    First lsusb:
    Bus 003 Device 001: ID 1d6b:0001 Linux Foundation 1.1 root hub
    Bus 001 Device 002: ID 0411:00e8 MelCo., Inc.
    Bus 001 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub
    Bus 002 Device 001: ID 1d6b:0001 Linux Foundation 1.1 root hub

    Then the modinfo:
    filename: rt2870sta.ko
    version: 2.2.0.0
    license: GPL
    description: RT2870 Wireless Lan Linux Driver
    author: Paul Lin <paul_lin@ralinktech.com>
    srcversion: C800221A9FC392167CBBF96
    alias: usb:v0DB0p6899d*dc*dsc*dp*ic*isc*ip*
    alias: usb:v100Dp9031d*dc*dsc*dp*ic*isc*ip*
    alias: usb:v050Dp815Cd*dc*dsc*dp*ic*isc*ip*
    alias: usb:v0411p00E8d*dc*dsc*dp*ic*isc*ip*
    alias: usb:v1737p0071d*dc*dsc*dp*ic*isc*ip*
    alias: usb:v1737p0078d*dc*dsc*dp*ic*isc*ip*
    alias: usb:v1737p0070d*dc*dsc*dp*ic*isc*ip*
    alias: usb:v7392p7717d*dc*dsc*dp*ic*isc*ip*
    alias: usb:v7392p7718d*dc*dsc*dp*ic*isc*ip*
    alias: usb:v5A57p0282d*dc*dsc*dp*ic*isc*ip*
    alias: usb:v5A57p0280d*dc*dsc*dp*ic*isc*ip*
    alias: usb:v1690p0740d*dc*dsc*dp*ic*isc*ip*
    alias: usb:v04E8p2018d*dc*dsc*dp*ic*isc*ip*
    alias: usb:v14B2p3C09d*dc*dsc*dp*ic*isc*ip*
    alias: usb:v1482p3C09d*dc*dsc*dp*ic*isc*ip*
    alias: usb:v050Dp815Cd*dc*dsc*dp*ic*isc*ip*
    alias: usb:v050Dp805Cd*dc*dsc*dp*ic*isc*ip*
    alias: usb:v157Ep300Ed*dc*dsc*dp*ic*isc*ip*
    alias: usb:v129Bp1828d*dc*dsc*dp*ic*isc*ip*
    alias: usb:v0E66p0003d*dc*dsc*dp*ic*isc*ip*
    alias: usb:v0E66p0001d*dc*dsc*dp*ic*isc*ip*
    alias: usb:v15C5p0008d*dc*dsc*dp*ic*isc*ip*
    alias: usb:v083Ap6618d*dc*dsc*dp*ic*isc*ip*
    alias: usb:v13D3p3247d*dc*dsc*dp*ic*isc*ip*
    alias: usb:v14B2p3C25d*dc*dsc*dp*ic*isc*ip*
    alias: usb:v0471p200Fd*dc*dsc*dp*ic*isc*ip*
    alias: usb:v1740p9702d*dc*dsc*dp*ic*isc*ip*
    alias: usb:v1740p9701d*dc*dsc*dp*ic*isc*ip*
    alias: usb:v0CDEp0025d*dc*dsc*dp*ic*isc*ip*
    alias: usb:v0586p3416d*dc*dsc*dp*ic*isc*ip*
    alias: usb:v0CDEp0022d*dc*dsc*dp*ic*isc*ip*
    alias: usb:v083Ap7522d*dc*dsc*dp*ic*isc*ip*
    alias: usb:v083Ap8522d*dc*dsc*dp*ic*isc*ip*
    alias: usb:v083ApA618d*dc*dsc*dp*ic*isc*ip*
    alias: usb:v083ApB522d*dc*dsc*dp*ic*isc*ip*
    alias: usb:v15A9p0006d*dc*dsc*dp*ic*isc*ip*
    alias: usb:v1044p800Bd*dc*dsc*dp*ic*isc*ip*
    alias: usb:v07AAp003Fd*dc*dsc*dp*ic*isc*ip*
    alias: usb:v07AAp003Cd*dc*dsc*dp*ic*isc*ip*
    alias: usb:v07AAp002Fd*dc*dsc*dp*ic*isc*ip*
    alias: usb:v14B2p3C27d*dc*dsc*dp*ic*isc*ip*
    alias: usb:v14B2p3C23d*dc*dsc*dp*ic*isc*ip*
    alias: usb:v050Dp8053d*dc*dsc*dp*ic*isc*ip*
    alias: usb:v14B2p3C07d*dc*dsc*dp*ic*isc*ip*
    alias: usb:v07D1p3C11d*dc*dsc*dp*ic*isc*ip*
    alias: usb:v07D1p3C09d*dc*dsc*dp*ic*isc*ip*
    alias: usb:v2019pED06d*dc*dsc*dp*ic*isc*ip*
    alias: usb:v14B2p3C28d*dc*dsc*dp*ic*isc*ip*
    alias: usb:v14B2p3C06d*dc*dsc*dp*ic*isc*ip*
    alias: usb:v0DF6p002Dd*dc*dsc*dp*ic*isc*ip*
    alias: usb:v0DF6p002Cd*dc*dsc*dp*ic*isc*ip*
    alias: usb:v0DF6p002Bd*dc*dsc*dp*ic*isc*ip*
    alias: usb:v0DF6p0017d*dc*dsc*dp*ic*isc*ip*
    alias: usb:v0B05p1742d*dc*dsc*dp*ic*isc*ip*
    alias: usb:v0B05p1732d*dc*dsc*dp*ic*isc*ip*
    alias: usb:v0B05p1731d*dc*dsc*dp*ic*isc*ip*
    alias: usb:v177Fp0302d*dc*dsc*dp*ic*isc*ip*
    alias: usb:v0789p0164d*dc*dsc*dp*ic*isc*ip*
    alias: usb:v0789p0163d*dc*dsc*dp*ic*isc*ip*
    alias: usb:v0789p0162d*dc*dsc*dp*ic*isc*ip*
    alias: usb:v083Ap7512d*dc*dsc*dp*ic*isc*ip*
    alias: usb:v0DF6p003Fd*dc*dsc*dp*ic*isc*ip*
    alias: usb:v0DF6p0039d*dc*dsc*dp*ic*isc*ip*
    alias: usb:v07B8p2770d*dc*dsc*dp*ic*isc*ip*
    alias: usb:v07B8p2870d*dc*dsc*dp*ic*isc*ip*
    alias: usb:v148Fp2870d*dc*dsc*dp*ic*isc*ip*
    alias: usb:v148Fp2770d*dc*dsc*dp*ic*isc*ip*
    depends:
    vermagic: 2.6.31-15-generic SMP mod_unload modversions 586
    parm: mac:rt28xx: wireless mac addr (charp)


    and the dmesg:
    [ 2536.189556] rtusb init --->
    [ 2536.190077]
    [ 2536.190079]
    [ 2536.190080] === pAd = f87d7000, size = 471912 ===
    [ 2536.190081]
    [ 2536.190084] <-- RTMPAllocAdapterBlock, Status=0
    [ 2536.191054] usbcore: registered new interface driver rt2870
    [ 2624.180846] wlan0: authenticate with AP 00:16:01:11:2b:8b
    [ 2624.190260] wlan0: authenticated
    [ 2624.190267] wlan0: associate with AP 00:16:01:11:2b:8b
    [ 2624.193715] wlan0: RX ReassocResp from 00:16:01:11:2b:8b (capab=0x411 status=0 aid=2)
    [ 2624.193721] wlan0: associated

    I've done all the preliminary including blacklisting the wayward drivers and changing the config files for supplicant support.

    I'm limping along using a Linksys 802.11(g) pci adapter rather than the Buffalo WLI-UC-G300N which uses the RT2870 drivers. Checking the status in Network Tools, it only shows the wlan0 connection using the MAC of the Linksys. Removing the PCI doesn't help. Other posts here have implied there may be an issue the the WPA2 encryption I use, but because other members of the household use the WPA2 encryption with the N protocol, I don't want to dumb down the encryption just for the linux computer. But I sure would be a happy camper if I could run this system using the Buffalo adapter. Any advice is welcome.

  4. #4
    Join Date
    May 2007
    Location
    Ontario Canada
    Beans
    Hidden!
    Distro
    Ubuntu Development Release

    Re: Karmic RT2870 Driver Tutorial

    calvinwels: It looks like the driver you compiled is detecting your USB device, this is good We'll have to figure out what else is wrong, whether it's a driver issue or something else Is this a new Ubuntu install or an upgrade? Does the USB device just not show up in NetworkManager, or is it "disabled"?

    I added a bit to the tutorial, more debugging steps and a little comment below the sudo rmmod rt2870sta
    sudo insmod ~/Desktop/2009_0820_RT2870_Linux_STA_V2.2.0.0/os/linux/rt2870sta.ko
    part (for now, just run those commands when you want to play with the rt2870 device, the old driver is still loading by default)

    neerajadsul: The modification is to make sure the driver identifies the USB Device ID of your device. The first 4 bits of the ID are a vendor ID, the second 4 are device specific. The stuff contained within "/* xxxxx*/" is just a comment to document the change you made. You can put whatever you want in there.


    I'm still looking for a better way to do this, I think there is a way to insert these IDs into a driver without compiling using udev or modules.alias or something. I'm pretty busy currently though, so I don't know if/when i'll have a solution along those lines.
    Last edited by peepingtom; December 3rd, 2009 at 04:55 AM.

  5. #5
    Join Date
    May 2007
    Location
    Ontario Canada
    Beans
    Hidden!
    Distro
    Ubuntu Development Release

    Re: Karmic RT2870 Driver Tutorial

    Calvinwels:

    The stuff you posted last, was that with both you USB and PCI adapter inserted? It's confusing, wlan0 is your linksys adapter, no?

    Don't boot your computer with the USB device inserted. Insert it into a fully booted computer. Then run:

    Code:
    sudo rmmod rt2870sta
    sudo insmod ~/Desktop/2009_0820_RT2870_Linux_STA_V2.2.0.0/os/linux/rt2870sta.ko
    and post the debug results.

  6. #6
    Join Date
    Nov 2009
    Beans
    8

    Re: Karmic RT2870 Driver Tutorial

    Thank you for your reply. As you suggested, I tried booting the computer without the Ralink adapter and also removed the older PCI adopter. After plugging in the Ralink adapter after booting and starting it up, Network Manager still did not recognize there was any wireless device attached even though the adapter's light was flashing. In running the debugs, the lsusb and modinfo appear unchanged from my earlier post.
    The ifconfig shows:
    ra0 Link encap:Ethernet HWaddr 00:1d:73:bc:d7:dc
    inet6 addr: fe80::21d:73ff:febc:d7dc/64 Scope:Link
    UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1
    RX packets:1297 errors:0 dropped:0 overruns:0 frame:0
    TX packets:1437 errors:0 dropped:0 overruns:0 carrier:0
    collisions:0 txqueuelen:1000
    RX bytes:159775 (159.7 KB) TX bytes:115280 (115.2 KB)

    iwconfig:
    ra0 Ralink STA ESSID:"lclntwk" Nickname:"RT2870STA"
    Mode:Auto Frequency=2.412 GHz Access Point: Not-Associated
    Bit Rate:1 Mb/s
    RTS thrff Fragment thrff
    Encryption keyff
    Link Quality=10/100 Signal level:0 dBm Noise level:-87 dBm
    Rx invalid nwid:0 Rx invalid crypt:0 Rx invalid frag:0
    Tx excessive retries:0 Invalid misc:0 Missed beacon:0



    dmesg:
    [ 551.549174] === pAd = f8858000, size = 471912 ===
    [ 551.549175]
    [ 551.549179] <-- RTMPAllocAdapterBlock, Status=0
    [ 551.550059] usbcore: registered new interface driver rt2870
    [ 561.404027] <-- RTMPAllocTxRxRingMemory, Status=0
    [ 561.405821] -->RTUSBVenderReset
    [ 561.405944] <--RTUSBVenderReset
    [ 561.682852] Key1Str is Invalid key length(0) or Type(0)
    [ 561.682879] Key2Str is Invalid key length(0) or Type(0)
    [ 561.682906] Key3Str is Invalid key length(0) or Type(0)
    [ 561.682932] Key4Str is Invalid key length(0) or Type(0)
    [ 561.683390] 1. Phy Mode = 5
    [ 561.683392] 2. Phy Mode = 5
    [ 561.715417] RTMPSetPhyMode: channel is out of range, use first channel=1
    [ 561.727412] 3. Phy Mode = 9
    [ 561.736037] MCS Set = ff ff 00 00 01
    [ 561.745031] <==== rt28xx_init, Status=0
    [ 561.746532] 0x1300 = 00064300
    [ 572.256007] ra0: no IPv6 routers present
    [ 576.916107] #
    [ 591.680088] #
    [ 617.176075] #
    [ 623.216075] #
    [ 631.268079] #
    [ 646.032083] #
    [ 656.096126] #
    [ 677.568148] #
    [ 699.040063] #
    [ 705.080065] #
    [ 712.464047] #




    and lsmod
    rt2870sta 541804 1
    snd_mpu401_uart 6940 3 snd_wavefront,snd_cs4236,snd_mpu401
    gameport 11368 2 ns558
    snd_rawmidi 22208 3 snd_wavefront,snd_mpu401_uart,snd_seq_midi
    snd 59204 21 snd_intel8x0,snd_ac97_codec,snd_pcm_oss,snd_mixer_ oss,snd_wavefront,snd_cs4236,snd_wss_lib,snd_opl3_ lib,snd_hwdep,snd_mpu401,snd_mpu401_uart,snd_pcm,s nd_seq_oss,snd_rawmidi,snd_seq,snd_timer,snd_seq_d evice
    parport 35340 2 ppdev,lp
    agpgart 34988 3 ttm,drm,amd64_agp



    At one point, Network Manager actually saw both the pci adapter as well as the usb adapter, but now refuses to see the usb at all even when the pci is removed. Even when it saw the usb adapter, however, it still did not connect. I initially upgraded from Jaunty, but in an attempt to get the usb adapter to work, I ended up doing a clean install as well. All without success. The usb adapter worked flawlessly under Jaunty, but I have video card problems re-installing Jaunty. Any thoughts for solving this would be appreciated.

  7. #7
    Join Date
    May 2007
    Location
    Ontario Canada
    Beans
    Hidden!
    Distro
    Ubuntu Development Release

    Re: Karmic RT2870 Driver Tutorial

    Is your card connecting to a network with the ESSID "lclntwk"? Because the default for this driver is "11n-AP", I don't know why yours says lclntwk Is this related to some change you made?. This doesn't really seem to be a fresh install, I mean there's more changed than just the new module you compiled. It seems like your driver works fine, this is some other issue?

    Only these 2 lines should be in /etc/network/interfaces:
    Code:
    auto lo
    iface lo inet loopback
    Did you edit /etc/Wireless/RT2870STA/RT2870STA.dat for some reason? If so, restore it to its former glory.
    Your wifi card doesn't show up in Networkmanager at all, or is it listed as "disabled" or "unmanaged"?


    To me, a clean install means you installed clean and followed my instructions exactly, it's hard to debug when I don't know what's changed on your system. If you followed my instructions and they didn't work, my instructions are bad or you made a mistake
    I am worried that my instructions suck, they worked for me like 5 times though :O
    Last edited by peepingtom; December 5th, 2009 at 09:37 AM.

  8. #8
    Join Date
    Dec 2009
    Beans
    59

    Re: Karmic RT2870 Driver Tutorial

    My PC isn't showing the USB, but otherwise I have everything fine until the
    sudo make
    sudo make install



    Then it says

    2009_0820_RT2870_Linux_STA_V2.2.0.0/os/linux/config.mk: No such file or directory

    and also
    Error 2
    Last edited by Love2MeetU; December 5th, 2009 at 10:43 AM.

  9. #9
    Join Date
    May 2007
    Location
    Ontario Canada
    Beans
    Hidden!
    Distro
    Ubuntu Development Release

    Re: Karmic RT2870 Driver Tutorial

    Quote Originally Posted by Love2MeetU View Post
    My PC isn't showing the USB, but otherwise I have everything fine until the
    Code:
    sudo make
    sudo make instal
    2009_0820_RT2870_Linux_STA_V2.2.0.0/os/linux/config.mk: No such file or directory
    You mean the not showing the USB device ID, or the device is not listed using lsusb?


    Are you sure you didn't make a typo?I posted more clear instructions about how to extract the .tar.bz file, it seems like you're missing something. Make sure linux-headers-generic is installed.
    Last edited by peepingtom; December 5th, 2009 at 08:49 PM.

  10. #10
    Join Date
    Dec 2009
    Beans
    59

    Re: Karmic RT2870 Driver Tutorial

    Quote Originally Posted by peepingtom View Post
    You mean the not showing the USB device ID, or the device is not listed using lsusb?


    Are you sure you didn't make a typo?I posted more clear instructions about how to extract the .tar.bz file, it seems like you're missing something. Make sure linux-headers-generic is installed.
    I used lsub and it wasn't listed.

    I didn't make any typos, double-checked that, and besides I copied & pasted your command lines. Then double-checked again.

    Is it possible the linux-headers-generic is damaged, and how would I check for that? I'm trying some other testing as well, just in case the problem is mechanical (damage to the USB plug, etc...)

    Quite willing to do a fresh install again if necessary. Doesn't take long anyway, besides everything is backed-up.

Page 1 of 14 12311 ... LastLast

Tags for this Thread

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •