brunamulinari
Posts: 14
Joined: Thu Aug 24, 2017 12:12 pm

Problem with Wireless Network Adapter Ralink MT7601U

Fri Sep 01, 2017 2:56 pm

Hello,

I have a ralink 5370 wireless network adapter, just like the photo below
Image

When I plug in the usb of raspberry pi 2 and using the "lsusb" layer I get:
Image

I tried searching for drivers to install from the MT7601 chip, but I found ways to install only for kernels up to 4.2 and my kernel is 4.9

Would anyone help me?

MrEngman
Posts: 3859
Joined: Fri Feb 03, 2012 2:17 pm
Location: Southampton, UK

Re: Problem with Wireless Network Adapter Ralink MT7601U

Fri Sep 01, 2017 3:37 pm

There is a driver for the mt7601u included with Raspbian kernel 4.9.

You may need to update/install the wifi driver firmware

Code: Select all

sudo apt-get update
sudo apt-get install firmware-ralink
Simplicity is a prerequisite for reliability. Edsger W. Dijkstra

Please post ALL technical questions on the forum. Please Do Not send private messages.

User avatar
DougieLawson
Posts: 36340
Joined: Sun Jun 16, 2013 11:19 pm
Location: Basingstoke, UK
Contact: Website Twitter

Re: Problem with Wireless Network Adapter Ralink MT7601U

Fri Sep 01, 2017 3:44 pm

The 5370 driver is built as a loadable module in Raspbian. Plug it in, it should "just work".
Note: Having anything humorous in your signature is completely banned on this forum. Wear a tin-foil hat and you'll get a ban.

Any DMs sent on Twitter will be answered next month.

This is a doctor free zone.

brunamulinari
Posts: 14
Joined: Thu Aug 24, 2017 12:12 pm

Re: Problem with Wireless Network Adapter Ralink MT7601U

Fri Sep 01, 2017 5:00 pm

DougieLawson wrote: The 5370 driver is built as a loadable module in Raspbian. Plug it in, it should "just work".

But when I install "iw" and I give "iw list" nothing appears. Should the modes supported by the usb appear?

fruitoftheloom
Posts: 20948
Joined: Tue Mar 25, 2014 12:40 pm
Location: Delightful Dorset

Re: Problem with Wireless Network Adapter Ralink MT7601U

Fri Sep 01, 2017 6:51 pm

brunamulinari wrote:
Fri Sep 01, 2017 2:56 pm
Hello,

I have a ralink 5370 wireless network adapter, just like the photo below
Image

When I plug in the usb of raspberry pi 2 and using the "lsusb" layer I get:
Image

I tried searching for drivers to install from the MT7601 chip, but I found ways to install only for kernels up to 4.2 and my kernel is 4.9

Would anyone help me?
Ralink 5370 is different Chipset to Ralink Mediatek MT7601, according to lsusb you have the later, so follow Mr Engman's advice..
Retired disgracefully.....

brunamulinari
Posts: 14
Joined: Thu Aug 24, 2017 12:12 pm

Re: Problem with Wireless Network Adapter Ralink MT7601U

Mon Sep 04, 2017 11:25 am

fruitoftheloom wrote: Ralink 5370 is different Chipset to Ralink Mediatek MT7601, according to lsusb you have the later, so follow Mr Engman's advice..

I tried to do what he said and it did not work.

User avatar
JoanTheSpark
Posts: 33
Joined: Sun Feb 21, 2016 5:36 am

Re: Problem with Wireless Network Adapter Ralink MT7601U

Sat Nov 11, 2017 4:58 am

if you want to see anything you have to use

Code: Select all

sudo iw list
What does show up when you plug it in and do

Code: Select all

sudo ifconfig

lazycoder17
Posts: 1
Joined: Sat Dec 02, 2017 4:21 pm

Re: Problem with Wireless Network Adapter Ralink MT7601U

Sat Dec 02, 2017 4:36 pm

MrEngman wrote:
Fri Sep 01, 2017 3:37 pm
There is a driver for the mt7601u included with Raspbian kernel 4.9.

You may need to update/install the wifi driver firmware

Code: Select all

sudo apt-get update
sudo apt-get install firmware-ralink
Thanks @MrEngman , this pointed me to my interfaces file which was messed up, and once I put up eth0 there, it started working :)

rodizio
Posts: 43
Joined: Sat May 07, 2016 2:40 am

Re: Problem with Wireless Network Adapter Ralink MT7601U

Wed Jan 10, 2018 4:24 pm

has anything changed inside the kernel regarding MT7601 dongles from 4.4 to 4.9?

Users of my EZ-Wifibroadcast distribution report that their MT7601 adapters stopped working after I upgraded the image from kernel 4.4 to kernel 4.9.35.

The card is detected by the kernel:

dmesg:

Code: Select all

[    1.681561] usb 1-1.5: New USB device found, idVendor=148f, idProduct=7601
[    1.681570] usb 1-1.5: New USB device strings: Mfr=1, Product=2, SerialNumber=3
[    1.681575] usb 1-1.5: Product: 802.11 n WLAN
[    1.681580] usb 1-1.5: Manufacturer: MediaTek
[    1.681585] usb 1-1.5: SerialNumber: 1.0


lsusb:

Code: Select all

Bus 001 Device 004: ID 148f:7601 Ralink Technology, Corp. 
Device Descriptor:
  bLength                18
  bDescriptorType         1
  bcdUSB               2.01
  bDeviceClass            0 (Defined at Interface level)
  bDeviceSubClass         0 
  bDeviceProtocol         0 
  bMaxPacketSize0        64
  idVendor           0x148f Ralink Technology, Corp.
  idProduct          0x7601 
  bcdDevice            0.00
  iManufacturer           1 MediaTek
  iProduct                2 802.11 n WLAN
  iSerial                 3 1.0

however, the rt2800usb driver module doesn't seem to get loaded and thus the card doesn't appear as network interface.

feldkiste
Posts: 1
Joined: Mon Jan 22, 2018 5:30 pm

Re: Problem with Wireless Network Adapter Ralink MT7601U

Mon Jan 22, 2018 5:32 pm

Same problem here w/ kernel 4.9
Dmesg shows the device but it won't work.
Any tips?

Thx

EDIT
cannot install firnware-ralink package. Need help. Error Log:

Code: Select all

Reading package lists...
Building dependency tree...
Reading state information...
Suggested packages:
  initramfs-tools
The following NEW packages will be installed:
  firmware-misc-nonfree
0 upgraded, 1 newly installed, 0 to remove and 9 not upgraded.
Need to get 0 B/2321 kB of archives.
After this operation, 8154 kB of additional disk space will be used.
(Reading database ... 73399 files and directories currently installed.)
Preparing to unpack .../firmware-misc-nonfree_20161130-3_all.deb ...
Unpacking firmware-misc-nonfree (20161130-3) ...
dpkg: error processing archive /var/cache/apt/archives/firmware-misc-nonfree_20161130-3_all.deb (--unpack):
 trying to overwrite '/lib/firmware/mt7601u.bin', which is also in package wireless-firmware-osmc 1.1.4
dpkg-deb: error: subprocess paste was killed by signal (Broken pipe)
Errors were encountered while processing:
 /var/cache/apt/archives/firmware-misc-nonfree_20161130-3_all.deb


ulno
Posts: 8
Joined: Thu Feb 08, 2018 3:44 am

Re: Problem with Wireless Network Adapter Ralink MT7601U

Fri Feb 09, 2018 2:41 pm

Confirming that this specific ralink-based adapter also doesn't work for me (I can install the firmware package though without problems). I would like to mention this thread here, as I think this problem occurred at the same time when the ralink mt7601u driver stopped working: viewtopic.php?f=66&t=191844

So does it really mean, we are locked to kernel 4.4. if we want to do anything more advanced with wireless on the Pi (and use more wireless options than the internal wireless chip)?

MrEngman
Posts: 3859
Joined: Fri Feb 03, 2012 2:17 pm
Location: Southampton, UK

Re: Problem with Wireless Network Adapter Ralink MT7601U

Fri Feb 09, 2018 9:40 pm

If you have a wifi module with USB ID 148F:7601 then there should be no problem getting it to work. Provide your wifi configuration is OK of course.

You may need to update the driver firmware using

Code: Select all

sudo apt-get update
sudo apt-get install firmware-ralink
My mt7601 wifi works fine with kernel 4.9 and the new 4.14 kernel.
Simplicity is a prerequisite for reliability. Edsger W. Dijkstra

Please post ALL technical questions on the forum. Please Do Not send private messages.

ulno
Posts: 8
Joined: Thu Feb 08, 2018 3:44 am

Re: Problem with Wireless Network Adapter Ralink MT7601U

Fri Feb 09, 2018 10:36 pm

Thanks for the positive news.

It is indeed the same id, I have it too. I will try now an apt update; apt dist-upgrade and will go to kernel 4.14 with rpi-update and try again. If this doesn't work, my raspbian lite must be totally messed up or I have a conflict with using hostapd on the internal wifi interface blocking or messing with wpa_supplicant. I tried downgrading the kernel to 4.4.50, but have the same problems.

This usb stick is from tenda, bought at microcenter (I actually got 20 of them, so the problem is a little bit of an embarrassment for me).
Some of my other ralink usb chips (sourced cheaply from China) though work fine - need to check their ids.

Will follow-up soon.

MrEngman
Posts: 3859
Joined: Fri Feb 03, 2012 2:17 pm
Location: Southampton, UK

Re: Problem with Wireless Network Adapter Ralink MT7601U

Fri Feb 09, 2018 10:59 pm

ulno wrote:
Fri Feb 09, 2018 10:36 pm
Thanks for the positive news.

It is indeed the same id, I have it too. I will try now an apt update; apt dist-upgrade and will go to kernel 4.14 with rpi-update and try again. If this doesn't work, my raspbian lite must be totally messed up or I have a conflict with using hostapd on the internal wifi interface blocking or messing with wpa_supplicant. I tried downgrading the kernel to 4.4.50, but have the same problems.

This usb stick is from tenda, bought at microcenter (I actually got 20 of them, so the problem is a little bit of an embarrassment for me).
Some of my other ralink usb chips (sourced cheaply from China) though work fine - need to check their ids.

Will follow-up soon.
As you say you are using hostapd I assume you are trying to use you wifi as a wifi access point or hotspot. That is a totally different situation to using the wifi in normal client mode and whether the mt7601 driver will work in host mode I'm not sure.
Simplicity is a prerequisite for reliability. Edsger W. Dijkstra

Please post ALL technical questions on the forum. Please Do Not send private messages.

ulno
Posts: 8
Joined: Thu Feb 08, 2018 3:44 am

Re: Problem with Wireless Network Adapter Ralink MT7601U

Sat Feb 10, 2018 3:06 pm

No, no, I don't want to use the external ralink usb stick in AP mode (maybe later on other single board computers), only the internal wifi of the pi 3 and zero W. So I, am basically building repeaters for class room settings where only wifi is available, but students need their own personal wifi networks for building networked systems: I am trying to take in wifi on an external wifi stick like the ralink and then hosting it as a new AP on the internal (I think broadcom based) wifi - the hostapd part on that internal chip always works very well.

Turned out that the my other "ralink"-based sticks were actually realtek based. However, I also didi have some ralink-based cheap chinese usb sticks, which have the same id - and they also didn't work.

After updating, upgrading, dist-upgrading, and kernel upgrade, it still didn't work, so I looked at the firmware and saw 4 potential package versions, the installed one was something with rpi5 in the version number. I purged it and re-installed to the 2017 based version, and now my cheap ra-link chips work. The tenda-chip which has the same id, did initially still not work.

I then put it that tenda chip my desktop, which runs Ubuntu with a 4.13 kernel and there it worked.

Putting it back into the pi made the tenda stick work also there. So I think I solved the issue. Thanks a lot!

Can I asked one more question, MrEngman?

Which exact firmware version do you have installed?

I have now 20170823, but it suggests to upgrade to 1:20161130-3+rpt1 ( I think suggesting that downgrade as an upgrade is due to the fact that I have pinned testing in /etc/apt/preferences on -1).

Code: Select all

$ apt list --upgradable -a
Listing... Done
firmware-misc-nonfree/stable 1:20161130-3+rpt1 all [upgradable from: 20170823-1]
firmware-misc-nonfree/testing,now 20170823-1 all [installed,upgradable to: 1:20161130-3+rpt1]
firmware-misc-nonfree/stable 20161130-3 all

MrEngman
Posts: 3859
Joined: Fri Feb 03, 2012 2:17 pm
Location: Southampton, UK

Re: Problem with Wireless Network Adapter Ralink MT7601U

Sat Feb 10, 2018 7:52 pm

I think regardless of the kernel version you use or the package used to install the mt7601 firmware the firmware files for the different kernel versions all appear to be the same.

I have looked directly at the firmware files on several different SD cards, using Raspbian Stretch, Jessie and Wheezy and the mt7601u.bin firmware file is the same on all of them and they all appear to have a date code 20130205.

So it doesn't appear to make any difference if you install package firmware-ralink or the newer firmware-misc-nonfree package as the firmware version is the same.
Simplicity is a prerequisite for reliability. Edsger W. Dijkstra

Please post ALL technical questions on the forum. Please Do Not send private messages.

Snerler
Posts: 9
Joined: Wed Feb 10, 2016 2:20 pm

Re: Problem with Wireless Network Adapter Ralink MT7601U

Tue Mar 13, 2018 7:01 pm

My MT7601U didn't work with Raspbian Stretch 4.9 kernel. The kernel files were pre-installed in /lib/firmware/. This is the solution for me:

See mrgromov's post in: https://github.com/kuba-moo/mt7601u/issues/64
My nonane black-red 148f:7601 mt7601u mini stick is working now!
Tested on Ubuntu 14.04 (kernel 4.4) and Ubuntu 17.10 (kernel 4.13).
Thanks to aleksander and Nidroide!
Just want to clarify instruction:

Download corresponding kernel source from kernel.org. For example: if you have 4.4.0-104-generic download version 4.4.
From archive unpack just folder drivers/net/wireless/mediatek/mt7601u
Edit phy.c. Find function mt7601u_init_cal and comment out call mt7601u_mcu_calibrate(dev, MCU_CAL_RXIQ, 0); like so:
// ret = mt7601u_mcu_calibrate(dev, MCU_CAL_RXIQ, 0);
// if (ret)
// return ret;
// ret = mt7601u_mcu_calibrate(dev, MCU_CAL_DPD, dev->dpd_temp);
// if (ret)
// return ret;
Find function mt7601u_phy_recalibrate_after_assoc and comment out call mt7601u_mcu_calibrate(dev, MCU_CAL_DPD, dev->curr_temp); like so:

void mt7601u_phy_recalibrate_after_assoc(struct mt7601u_dev *dev)
{
// mt7601u_mcu_calibrate(dev, MCU_CAL_DPD, dev->curr_temp);

mt7601u_rxdc_cal(dev);
}
Build module: make -C /lib/modules/$(uname -r)/build M=$(pwd) modules
Remove device
sudo rmmod mt7601u
sudo insmod ./mt7601u.ko
Insert device
Check there are no errors in dmesg and interface appeared in ip link, check connection stability.
To make change persistent till next kernel upgrade: backup original module and replace with compiled. To find out where is original module run modinfo mt7601u (view string filename: /lib/modules/_KERNEL_VERSION_/kernel/drivers/net/wireless/mediatek/mt7601u/mt7601u.ko).

czioriri
Posts: 35
Joined: Tue Jun 03, 2014 9:50 am

Re: Problem with Wireless Network Adapter Ralink MT7601U

Tue Jul 31, 2018 5:18 pm

Hello

I try to adapt the driver my dongle wifi Bus 001 Device 004: 148f ID: 7601 Ralink Technology, Corp. MT7601U Wireless Adapter

I tried https://github.com/kuba-moo/mt7601u/issues/64
My nonane black-red 148f:7601 mt7601u mini stick is working now!
Tested on Ubuntu 14.04 (kernel 4.4) and Ubuntu 17.10 (kernel 4.13).
Thanks to aleksander and Nidroide!
Just want to clarify instruction:

Download corresponding kernel source from kernel.org. For example: if you have 4.4.0-104-generic download version 4.4.
From archive unpack just folder drivers/net/wireless/mediatek/mt7601u
Edit phy.c. Find function mt7601u_init_cal and comment out call mt7601u_mcu_calibrate(dev, MCU_CAL_RXIQ, 0); like so:
// ret = mt7601u_mcu_calibrate(dev, MCU_CAL_RXIQ, 0);
// if (ret)
// return ret;
// ret = mt7601u_mcu_calibrate(dev, MCU_CAL_DPD, dev->dpd_temp);
// if (ret)
// return ret;
Find function mt7601u_phy_recalibrate_after_assoc and comment out call mt7601u_mcu_calibrate(dev, MCU_CAL_DPD, dev->curr_temp); like so:

void mt7601u_phy_recalibrate_after_assoc(struct mt7601u_dev *dev)
{
// mt7601u_mcu_calibrate(dev, MCU_CAL_DPD, dev->curr_temp);

mt7601u_rxdc_cal(dev);
}
Build module: make -C /lib/modules/$(uname -r)/build M=$(pwd) modules
Remove device
sudo rmmod mt7601u
sudo insmod ./mt7601u.ko
Insert device
Check there are no errors in dmesg and interface appeared in ip link, check connection stability.
To make change persistent till next kernel upgrade: backup original module and replace with compiled. To find out where is original module run modinfo mt7601u (view string filename: /lib/modules/_KERNEL_VERSION_/kernel/drivers/net/wireless/mediatek/mt7601u/mt7601u.ko).
I'm blocking the line
Build module: make -C /lib/modules/$(uname -r)/build M=$(pwd) modules
Where to execute the "make" command

thank you very much
j'ai eu un AVC ! je ne écris pas bien :oops: !!

had a stroke! I do not write well: :oops: : !!

Return to “General discussion”