The first thing to say is that I have explored and tried the solutions suggested in other similar questions but so far nothing has worked. I know the USB Wifi is not faulty as it just works fine in Windows 10 on the same machine. Incidentally it also doesn't work in Mac OS 10.13.6 (This is a 2011 MacBook Pro with a broken internal WiFi adapter).
lsusb
gives the following: Bus 002 Device 006: ID 148f:7601 Ralink Technology, Corp. MT7601U Wireless Adapter
dmesg
just after plugging the device in gives:
[ 2265.257271] usb 1-1.3: new high-speed USB device number 11 using ehci-pci
[ 2265.376911] usb 1-1.3: New USB device found, idVendor=148f, idProduct=7601
[ 2265.376915] usb 1-1.3: New USB device strings: Mfr=1, Product=2, SerialNumber=3
[ 2265.376917] usb 1-1.3: Product: 802.11 n WLAN
[ 2265.376919] usb 1-1.3: Manufacturer: MediaTek
[ 2265.376921] usb 1-1.3: SerialNumber: 1.0
If I try iwconfig:
$ iwconfig
lo no wireless extensions.
enp2s0f0 no wireless extensions.
I have downloaded the firmware from the Mediatek website and put it in the right folder and have also tried to compile or install various packages which either threw compilation errors or did nothing to get the WiFi working.
Does anyone have any advice or an up-to date solution for this?
I tried to follow the instructions given for @chili555's answer:
$ make
make -C tools
make[1]: Entering directory '/home/baldwin/mt7601usta/src/tools'
gcc -g bin2h.c -o bin2h
make[1]: Leaving directory '/home/baldwin/mt7601usta/src/tools'
/home/baldwin/mt7601usta/src/tools/bin2h
cp -f os/linux/Makefile.6 /home/baldwin/mt7601usta/src/os/linux /Makefile
make -C /lib/modules/4.15.0-39-generic/build SUBDIRS=/home/baldwin /mt7601usta/src/os/linux modules
make[1]: Entering directory '/usr/src/linux-headers-4.15.0-39-generic'
CC [M] /home/baldwin/mt7601usta/src/os/linux/../../os/linux /rt_profile.o
CC [M] /home/baldwin/mt7601usta/src/os/linux/../../sta/assoc.o
CC [M] /home/baldwin/mt7601usta/src/os/linux/../../sta/auth.o
CC [M] /home/baldwin/mt7601usta/src/os/linux/../../sta/auth_rsp.o
CC [M] /home/baldwin/mt7601usta/src/os/linux/../../sta/sync.o
CC [M] /home/baldwin/mt7601usta/src/os/linux/../../sta/sanity.o
CC [M] /home/baldwin/mt7601usta/src/os/linux/../../sta/rtmp_data.o
CC [M] /home/baldwin/mt7601usta/src/os/linux/../../sta/connect.o
CC [M] /home/baldwin/mt7601usta/src/os/linux/../../sta/wpa.o
CC [M] /home/baldwin/mt7601usta/src/os/linux/../../sta/sta_cfg.o
/home/baldwin/mt7601usta/src/os/linux/../../sta/sta_cfg.c: In function ‘Set_EncrypType_Proc’:
/home/baldwin/mt7601usta/src/os/linux/../../sta/sta_cfg.c:1104:5: warning: this ‘else’ clause does not guard... [-Wmisleading-indentation]
else
^~~~
/home/baldwin/mt7601usta/src/os/linux/../../sta/sta_cfg.c:1107:2: note: ...this statement, but the latter is misleadingly indented as if it were guarded by the ‘else’
if (pAd->StaCfg.BssType == BSS_ADHOC)
^~
/home/baldwin/mt7601usta/src/os/linux/../../sta/sta_cfg.c: In function ‘RtmpIoctl_rt_ioctl_siwfreq’:
/home/baldwin/mt7601usta/src/os/linux/../../sta/sta_cfg.c:6018:5: warning: this ‘else’ clause does not guard... [-Wmisleading-indentation]
else
^~~~
/home/baldwin/mt7601usta/src/os/linux/../../sta/sta_cfg.c:6021:2: note: ...this statement, but the latter is misleadingly indented as if it were guarded by the ‘else’
return NDIS_STATUS_SUCCESS;
^~~~~~
/home/baldwin/mt7601usta/src/os/linux/../../sta/sta_cfg.c: In function ‘RtmpIoctl_rt_ioctl_giwrate’:
/home/baldwin/mt7601usta/src/os/linux/../../sta/sta_cfg.c:7928:5: warning: this ‘if’ clause does not guard... [-Wmisleading-indentation]
if (rate_index >= rate_count)
^~
/home/baldwin/mt7601usta/src/os/linux/../../sta/sta_cfg.c:7931:2: note: ...this statement, but the latter is misleadingly indented as if it were guarded by the ‘if’
*(ULONG *)pData = ralinkrate[rate_index] * 500000;
^
CC [M] /home/baldwin/mt7601usta/src/os/linux/../../common /crypt_md5.o
CC [M] /home/baldwin/mt7601usta/src/os/linux/../../common/crypt_sha2.o
CC [M] /home/baldwin/mt7601usta/src/os/linux/../../common/crypt_hmac.o
CC [M] /home/baldwin/mt7601usta/src/os/linux/../../common/crypt_aes.o
CC [M] /home/baldwin/mt7601usta/src/os/linux/../../common /crypt_arc4.o
CC [M] /home/baldwin/mt7601usta/src/os/linux/../../common/mlme.o
CC [M] /home/baldwin/mt7601usta/src/os/linux/../../common/cmm_wep.o
CC [M] /home/baldwin/mt7601usta/src/os/linux/../../common/action.o
CC [M] /home/baldwin/mt7601usta/src/os/linux/../../common/cmm_data.o
CC [M] /home/baldwin/mt7601usta/src/os/linux/../../common/rtmp_init.o
/home/baldwin/mt7601usta/src/os/linux/../../common/rtmp_init.c: In function ‘NICInitializeAsic’:
/home/baldwin/mt7601usta/src/os/linux/../../common/rtmp_init.c:1656:1: warning: the frame size of 1048 bytes is larger than 1024 bytes [-Wframe- larger-than=]
}
^
CC [M] /home/baldwin/mt7601usta/src/os/linux/../../common /rtmp_init_inf.o
CC [M] /home/baldwin/mt7601usta/src/os/linux/../../common/cmm_tkip.o
CC [M] /home/baldwin/mt7601usta/src/os/linux/../../common/cmm_aes.o
CC [M] /home/baldwin/mt7601usta/src/os/linux/../../common/cmm_sync.o
CC [M] /home/baldwin/mt7601usta/src/os/linux/../../common/eeprom.o
CC [M] /home/baldwin/mt7601usta/src/os/linux/../../common/cmm_sanity.o
CC [M] /home/baldwin/mt7601usta/src/os/linux/../../common /cmm_info.o
/home/baldwin/mt7601usta/src/os/linux/../../common/cmm_info.c: In function ‘GetEncryptType’:
/home/baldwin/mt7601usta/src/os/linux/../../common/cmm_info.c:1752:5: warning: this ‘if’ clause does not guard... [-Wmisleading-indentation]
if(enc == Ndis802_11Encryption3Enabled)
^~
/home/baldwin/mt7601usta/src/os/linux/../../common/cmm_info.c:1754:2: note: ...this statement, but the latter is misleadingly indented as if it were guarded by the ‘if’
if(enc == Ndis802_11Encryption4Enabled)
^~
/home/baldwin/mt7601usta/src/os/linux/../../common/cmm_info.c: In function ‘GetAuthMode’:
/home/baldwin/mt7601usta/src/os/linux/../../common/cmm_info.c:1764:5: warning: this ‘if’ clause does not guard... [-Wmisleading-indentation]
if(auth == Ndis802_11AuthModeShared)
^~
/home/baldwin/mt7601usta/src/os/linux/../../common/cmm_info.c:1766:2: note: ...this statement, but the latter is misleadingly indented as if it were guarded by the ‘if’
if(auth == Ndis802_11AuthModeAutoSwitch)
^~
/home/baldwin/mt7601usta/src/os/linux/../../common/cmm_info.c:1776:5: warning: this ‘if’ clause does not guard... [-Wmisleading-indentation]
if(auth == Ndis802_11AuthModeWPA2PSK)
^~
/home/baldwin/mt7601usta/src/os/linux/../../common/cmm_info.c:1778:2: note: ...this statement, but the latter is misleadingly indented as if it were guarded by the ‘if’
if(auth == Ndis802_11AuthModeWPA1WPA2)
^~
/home/baldwin/mt7601usta/src/os/linux/../../common/cmm_info.c: In function ‘Show_PMK_Proc’:
/home/baldwin/mt7601usta/src/os/linux/../../common/cmm_info.c:4198:5: warning: this ‘for’ clause does not guard... [-Wmisleading-indentation]
for (idx = 0; idx < 32; idx++)
^~~
/home/baldwin/mt7601usta/src/os/linux/../../common/cmm_info.c:4201:2: note: ...this statement, but the latter is misleadingly indented as if it were guarded by the ‘for’
return 0;
^~~~~~
CC [M] /home/baldwin/mt7601usta/src/os/linux/../../common/cmm_cfg.o
CC [M] /home/baldwin/mt7601usta/src/os/linux/../../common/cmm_wpa.o
/home/baldwin/mt7601usta/src/os/linux/../../common/cmm_wpa.c: In function ‘WPAStart2WayGroupHS’:
/home/baldwin/mt7601usta/src/os/linux/../../common/cmm_wpa.c:1257:5: warning: this ‘if’ clause does not guard... [-Wmisleading-indentation]
if ((!pEntry) || !IS_ENTRY_CLIENT(pEntry))
^~
/home/baldwin/mt7601usta/src/os/linux/../../common/cmm_wpa.c:1262:2: note: ...this statement, but the latter is misleadingly indented as if it were guarded by the ‘if’
os_alloc_mem(NULL, (PUCHAR *)&mpool, TX_EAPOL_BUFFER);
^~~~~~~~~~~~
CC [M] /home/baldwin/mt7601usta/src/os/linux/../../common/cmm_radar.o
CC [M] /home/baldwin/mt7601usta/src/os/linux/../../common/spectrum.o
CC [M] /home/baldwin/mt7601usta/src/os/linux/../../common/rtmp_timer.o
CC [M] /home/baldwin/mt7601usta/src/os/linux/../../common/rt_channel.o
CC [M] /home/baldwin/mt7601usta/src/os/linux/../../common/cmm_profile.o
CC [M] /home/baldwin/mt7601usta/src/os/linux/../../common/cmm_asic.o
CC [M] /home/baldwin/mt7601usta/src/os/linux/../../common/scan.o
CC [M] /home/baldwin/mt7601usta/src/os/linux/../../common/cmm_cmd.o
CC [M] /home/baldwin/mt7601usta/src/os/linux/../../common/uapsd.o
CC [M] /home/baldwin/mt7601usta/src/os/linux/../../common/ps.o
CC [M] /home/baldwin/mt7601usta/src/os/linux/../../rate_ctrl/ra_ctrl.o
CC [M] /home/baldwin/mt7601usta/src/os/linux/../../rate_ctrl/alg_legacy.o
CC [M] /home/baldwin/mt7601usta/src/os/linux/../../rate_ctrl/alg_ags.o
CC [M] /home/baldwin/mt7601usta/src/os/linux/../../chips/rtmp_chip.o
CC [M] /home/baldwin/mt7601usta/src/os/linux/../../common/txpower.o
CC [M] /home/baldwin/mt7601usta/src/os/linux/../../mac/rtmp_mac.o
CC [M] /home/baldwin/mt7601usta/src/os/linux/../../mgmt/mgmt_hw.o
CC [M] /home/baldwin/mt7601usta/src/os/linux/../.. /mgmt/mgmt_entrytb.o
/home/baldwin/mt7601usta/src/os/linux/../../mgmt/mgmt_entrytb.c: In function ‘MacTableInsertEntry’:
/home/baldwin/mt7601usta/src/os/linux/../../mgmt/mgmt_entrytb.c:103:2: warning: this ‘if’ clause does not guard... [-Wmisleading-indentation]
if (pAd->MacTab.Size >= MAX_LEN_OF_MAC_TABLE)
^~
/home/baldwin/mt7601usta/src/os/linux/../../mgmt/mgmt_entrytb.c:106:3: note: ...this statement, but the latter is misleadingly indented as if it were guarded by the ‘if’
FirstWcid = 1;
^~~~~~~~~
CC [M] /home/baldwin/mt7601usta/src/os/linux/../../phy/rtmp_phy.o
CC [M] /home/baldwin/mt7601usta/src/os/linux/../../phy/rlt_phy.o
CC [M] /home/baldwin/mt7601usta/src/os/linux/../../phy/rlt_rf.o
CC [M] /home/baldwin/mt7601usta/src/os/linux/../../common/ba_action.o
CC [M] /home/baldwin/mt7601usta/src/os/linux/../../mgmt/mgmt_ht.o
CC [M] /home/baldwin/mt7601usta/src/os/linux/../../common/rt_os_util.o
CC [M] /home/baldwin/mt7601usta/src/os/linux/../../os/linux/sta_ioctl.o
CC [M] /home/baldwin/mt7601usta/src/os/linux/../../os/linux /rt_linux.o
/home/baldwin/mt7601usta/src/os/linux/../../os/linux/rt_linux.c: In function ‘__RTMP_OS_Init_Timer’:
/home/baldwin/mt7601usta/src/os/linux/../../os/linux/rt_linux.c:120:3: error: implicit declaration of function ‘init_timer’; did you mean ‘init_timers’? [-Werror=implicit-function-declaration]
init_timer(pTimer);
^~~~~~~~~~
init_timers
/home/baldwin/mt7601usta/src/os/linux/../../os/linux/rt_linux.c:121:9: error: ‘OS_NDIS_MINIPORT_TIMER {aka struct timer_list}’ has no member named ‘data’
pTimer->data = (unsigned long)data;
^~
/home/baldwin/mt7601usta/src/os/linux/../../os/linux /rt_linux.c:122:20: error: assignment from incompatible pointer type [-Werror=incompatible-pointer-types]
pTimer->function = function;
^
cc1: some warnings being treated as errors
scripts/Makefile.build:332: recipe for target '/home/baldwin/mt7601usta/src/os/linux/../../os/linux/rt_linux.o' failed
make[2]: *** [/home/baldwin/mt7601usta/src/os/linux/../../os/linux/rt_linux.o] Error 1
Makefile:1551: recipe for target '_module_/home/baldwin/mt7601usta /src/os/linux' failed
make[1]: *** [_module_/home/baldwin/mt7601usta/src/os/linux] Error 2
make[1]: Leaving directory '/usr/src/linux-headers-4.15.0-39- generic'
Makefile:418: recipe for target 'LINUX' failed
make: *** [LINUX] Error 2
Then, just in case it had somehow worked anyway:
$ sudo modprobe mt7601Usta
modprobe: FATAL: Module mt7601Usta not found in directory /lib/modules /4.15.0-39-generic
Information from latest comment: $ sudo updatedb && locate mt7601u.ko
/lib/modules/4.15.0-38-generic/kernel/drivers/net/wireless/mediatek /mt7601u/mt7601u.ko
/lib/modules/4.15.0-39-generic/kernel/drivers/net/wireless/mediatek/mt7601u/mt7601u.ko
$ sudo modprobe mt7601u && dmesg | grep mt76
[ 1102.391048] mt7601u 1-1.3:1.0: ASIC revision: 76010001 MAC revision: 76010500
[ 1102.432663] mt7601u 1-1.3:1.0: EEPROM ver:0c fae:00
[ 1102.610548] mt7601u 1-1.3:1.0: Error: RX urb failed:-71
[ 1102.610690] mt7601u 1-1.3:1.0: Error: MCU resp urb failed:-71
[ 1102.610703] mt7601u 1-1.3:1.0: Error: MCU resp evt:0 seq:5-4!
[ 1102.614793] mt7601u 1-1.3:1.0: Error: RX urb failed:-71
[ 1102.615055] mt7601u 1-1.3:1.0: Error: MCU resp urb failed:-71
[ 1102.615063] mt7601u 1-1.3:1.0: Error: MCU resp evt:0 seq:5-4!
[ 1102.619034] mt7601u 1-1.3:1.0: Error: RX urb failed:-71
[ 1102.619356] mt7601u 1-1.3:1.0: Error: MCU resp urb failed:-71
[ 1102.619375] mt7601u 1-1.3:1.0: Error: MCU resp evt:0 seq:5-4!
[ 1102.623360] mt7601u 1-1.3:1.0: Error: RX urb failed:-71
[ 1102.623598] mt7601u 1-1.3:1.0: Error: MCU resp urb failed:-71
[ 1102.623619] mt7601u 1-1.3:1.0: Error: MCU resp evt:0 seq:5-4!
[ 1102.627523] mt7601u 1-1.3:1.0: Error: RX urb failed:-71
[ 1102.627782] mt7601u 1-1.3:1.0: Error: MCU resp urb failed:-71
[ 1102.627785] mt7601u 1-1.3:1.0: Error: MCU resp evt:0 seq:5-4!
[ 1102.627787] mt7601u 1-1.3:1.0: Error: mt7601u_mcu_wait_resp timed out
[ 1102.795071] mt7601u: probe of 1-1.3:1.0 failed with error -110
[ 1102.795178] usbcore: registered new interface driver mt7601u
Now I tried:
$ md5sum /lib/firmware/mt7610u.bin
696cedb8e76ecc0cda9f9b0d3972c64d /lib/firmware/mt7610u.bin
Then:
$ sudo dpkg -s linux-firmware | grep Version
Version: 1.173.2
Having followed advice below and installing latest version of firmware:
$ dmesg | grep ath
$ md5sum /lib/firmware/mt7610u.bin
696cedb8e76ecc0cda9f9b0d3972c64d /lib/firmware/mt7610u.bin
This is still the same as before.
sudo updatedb && locate mt7601u.ko
If you find it, load it and look for errors in the log:sudo modprobe mt7601u && dmesg | grep mt76
Is it missing firmware? – chili555 Nov 28 '18 at 15:26md5sum /lib/firmware/mt7610u.bin
On my system, it returns 9a047587617c9c8732b9c546fb4a0152. – chili555 Nov 28 '18 at 16:10sudo dpkg -s linux-firmware | grep Version
– chili555 Nov 28 '18 at 16:15