How to enable MediaTek MT7921 USB WiFi dongle as an AP?

I have a Netgear R7450 MediaTek MT7621 ver:1 eco:3 with OpenWrt 23.05.4
I have added a Fenvi USB 3.0 WiFi dongle with a MediaTek MT7921 chipset (link below) and want to configure it as an AP.

Eventually, I plan to use the dongle on a Rock64 board in AP mode.

I have installed the relevant MT7921 packages (to my knowledge).
However, in LuCI>Network>Devices tab, I do not see 'wlan2'

I would appreciate guidance on how to get the USB WiFi dongle configured as an AP

Thanks

=============================================================

# opkg list-installed | egrep -i '7921'

kmod-mt7921-common - 5.15.162+2024-04-03-1e336a85-1
kmod-mt7921-firmware - 5.15.162+2024-04-03-1e336a85-1
kmod-mt7921e - 5.15.162+2024-04-03-1e336a85-1
kmod-mt7921s - 5.15.162+2024-04-03-1e336a85-1
kmod-mt7921u - 5.15.162+2024-04-03-1e336a85-1
mt7921bt-firmware - 20230804-1

# lsusb | egrep -i mediatek

Bus 002 Device 002: ID 0e8d:7961 MediaTek Inc. Wireless_Device

# ethtool --driver wlan2

driver: mt7921u
version: 5.15.162
firmware-version: ____010000-20231109190959
expansion-rom-version:
bus-info: 2-1:1.0
supports-statistics: yes
supports-test: no
supports-eeprom-access: no
supports-register-dump: no
supports-priv-flags: no

# lsmod | egrep 'mt7'

mac80211              581760  7 mt7921_common,mt792x_lib,mt7615e,mt7615_common,mt7603e,mt76_connac_lib,mt76
mt76                   52064  9 mt7921u,mt7921_common,mt792x_usb,mt792x_lib,mt7615e,mt7615_common,mt7603e,mt76_usb,mt76_connac_lib
mt76_connac_lib        38272  5 mt7921u,mt7921_common,mt792x_lib,mt7615e,mt7615_common
mt76_usb               11856  2 mt7921u,mt792x_usb
mt7603e                39296  0
mt7615_common          67520  1 mt7615e
mt7615e                 9856  0
mt7921_common          42096  1 mt7921u
mt7921u                 2336  0
mt792x_lib             20448  3 mt7921u,mt7921_common,mt792x_usb
mt792x_usb              3392  1 mt7921u

# uci show wireless

wireless.radio0=wifi-device
wireless.radio0.type='mac80211'
wireless.radio0.path='1e140000.pcie/pci0000:00/0000:00:00.0/0000:01:00.0'
wireless.radio0.channel='auto'
wireless.radio0.band='2g'
wireless.radio0.htmode='HT20'
wireless.radio0.cell_density='0'
wireless.radio0.txpower='19'
wireless.radio0.disabled='0'

wireless.radio1=wifi-device
wireless.radio1.type='mac80211'
wireless.radio1.path='1e140000.pcie/pci0000:00/0000:00:01.0/0000:02:00.0'
wireless.radio1.channel='auto'
wireless.radio1.band='5g'
wireless.radio1.htmode='VHT80'
wireless.radio1.cell_density='2'
wireless.radio1.disabled='0'

wireless.wifinet0=wifi-iface
wireless.wifinet0.device='radio1'
wireless.wifinet0.mode='sta'
wireless.wifinet0.network='wifiwan'
wireless.wifinet0.ssid=mask'
wireless.wifinet0.bssid='E4:BF:FA:30:10:40'
wireless.wifinet0.encryption='psk2'
wireless.wifinet0.key='mask'

wireless.wifinet1=wifi-iface
wireless.wifinet1.device='radio0'
wireless.wifinet1.mode='ap'
wireless.wifinet1.ssid='mask'
wireless.wifinet1.encryption='sae-mixed'
wireless.wifinet1.key='mask*'
wireless.wifinet1.wpa_disable_eapol_key_retries='1'
wireless.wifinet1.network='lan'

wireless.radio2=wifi-device
wireless.radio2.type='mac80211'
wireless.radio2.path='platform/1e1c0000.xhci/usb1/1-1/1-1:1.0'
wireless.radio2.channel='36'
wireless.radio2.band='5g'
wireless.radio2.htmode='NOHT'
wireless.radio2.disabled='1'
wireless.default_radio2=wifi-iface
wireless.default_radio2.device='radio2'
wireless.default_radio2.network='lan'
wireless.default_radio2.mode='ap'
wireless.default_radio2.ssid='OpenWrt'
wireless.default_radio2.encryption='none'

wireless.radio3=wifi-device
wireless.radio3.type='mac80211'
wireless.radio3.path='platform/1e1c0000.xhci/usb2/2-1/2-1:1.0'
wireless.radio3.channel='36'
wireless.radio3.band='5g'
wireless.radio3.htmode='HE80'
wireless.radio3.disabled='1'
wireless.default_radio3=wifi-iface
wireless.default_radio3.device='radio3'
wireless.default_radio3.network='lan'
wireless.default_radio3.mode='ap'
wireless.default_radio3.ssid='OpenWrt'
wireless.default_radio3.encryption='none'

=============================================================

mt7921u - Fenvi AX1800 USB 3.0 wifi dongle.

Might want to try using the RC5 pre-release.

1 Like

I see these 2 lines

wireless.radio2.disabled='1'
wireless.radio3.disabled='1'

They belong to some USB WiFi devices, probably this is the cause.

3 Likes

Good eye :eyes:
Indeed that was the cause, didn't catch it -- result of looking at it for too long :face_with_spiral_eyes:

I enabled both radios in /etc/config/wireless and rebooted.

After the reboot
LuCI Network>Interfaces>Devices -- I can see the USB WiFi as phy2-ap0
LuCI Wireless -- I can see radio3 (second radio) as "MediaTek MT7921AU 802.11ac/ax/b/g/" And I am able to configure it as a WiFi AP. Tested with a tablet, it can connect to the WiFi AP and get full internet access.

However, I'm not having much luck with the first radio 'radio2' It shows up as " Generic unknown" It remains in a "Device not active" state. Restarting the radio2 does not help.

And the 2nd radio is.... what ?

Radio2 was the 7921 when plugged into a different USB port. USB radios have to stay plugged into the same physical port on the host router or they will enumerate as a new radio.

You can delete the existing radio2 block then change the name of radio3 to radio2 or radiousb or whatever makes sense for you.

4 Likes

When you unplug and plug again it will make it "Generic Unknown", you just need to manually remove it from config file.

BTW you can resolve the question if it's being answered.

1 Like

like fakemanhk says whenever you plug the dongle into different ports it will get added into /etc/config/wireless

If you don't want to see them you need to edit the file to take them out

Thanks for the replies. Indeed, 'radio2' and 'radio3' are associated with the USB WiFi dongle.

wireless.radio2.path='platform/1e1c0000.xhci/usb1/1-1/1-1:1.0'
wireless.radio3.path='platform/1e1c0000.xhci/usb2/2-1/2-1:1.0'

The Netgear R7450 has only one USB port. I have not removed the dongle ever since I plugged it into the router. So the issue of unplugging/plugging is not applicable in my case.

Deleting radio2 and reboot did not help. After reboot only 3 radios (2 from the embedded chipset of the R7450 and one from the WiFi dongle).
For now I'll mark it Solved.

I'll do some research with the dongle on another spare router (with 24.10-rc5) and open a new thread if I find something new.

In future, similar case should probably be opened in "Installing and Using OpenWrt" category instead of here since it's not really about hardware.

They can always be moved :slight_smile:

2 Likes

This topic was automatically closed 10 days after the last reply. New replies are no longer allowed.